diff options
| author | Jeff Carr <[email protected]> | 2025-01-07 18:18:38 -0600 |
|---|---|---|
| committer | Jeff Carr <[email protected]> | 2025-01-07 18:18:38 -0600 |
| commit | 07e0fdc43724433e18f2fb469b829a7b0b125800 (patch) | |
| tree | 05f372b1a5ebce3e4894ef7ece76ddbe386ecd0c /git.go | |
| parent | 669c4e082cb6aebc053bfbfa60d5239c633a80dd (diff) | |
rm old code
Diffstat (limited to 'git.go')
| -rw-r--r-- | git.go | 9 |
1 files changed, 4 insertions, 5 deletions
@@ -44,6 +44,7 @@ func (rs *RepoStatus) Path() string { return rs.realPath.String() } +/* func (rs *RepoStatus) checkoutBranch(level string, branch string) { if rs.CheckDirty() { log.Log(REPO, "checkoutBranch() checkDirty() == true for repo", rs.realPath.String(), "looking for branch:", branch) @@ -66,6 +67,7 @@ func (rs *RepoStatus) checkoutBranch(level string, branch string) { default: } } +*/ func (rs *RepoStatus) GitState() string { return rs.gitState.String() @@ -126,7 +128,7 @@ func (rs *RepoStatus) displayCurrentBranchName() string { // stores the current branch name func (rs *RepoStatus) checkCurrentBranchName() string { currentname := rs.currentBranch.String() - out := run(rs.realPath.String(), "git", "branch --show-current") + out := rs.pb.GetCurrentBranchName() if currentname == out { // nothing changed return currentname @@ -189,10 +191,7 @@ func (rs *RepoStatus) checkCurrentBranchVersion() string { // this should get the most recent tag func (rs *RepoStatus) setLastTagVersion() { - hash := run(rs.realPath.String(), "git", "rev-list --tags --max-count=1") - log.Log(REPO, "getLastTagVersion()", hash) - - name, _ := rs.gitDescribeByHash(hash) + name := rs.pb.GetLastTagVersion() rs.lasttag.SetText(name) return } |
