We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent ee99cf6 commit faae819Copy full SHA for faae819
modules/git/ref.go
@@ -53,6 +53,11 @@ func (ref *Reference) Commit() (*Commit, error) {
53
return ref.repo.getCommit(ref.Object)
54
}
55
56
+// ShortName returns the short name of the reference
57
+func (ref *Reference) ShortName() string {
58
+ return RefName(ref.Name).ShortName()
59
+}
60
+
61
// RefGroup returns the group type of the reference
62
func (ref *Reference) RefGroup() string {
63
return RefName(ref.Name).RefGroup()
0 commit comments