diff options
| author | Jeff Carr <[email protected]> | 2024-11-08 06:43:33 -0600 |
|---|---|---|
| committer | Jeff Carr <[email protected]> | 2024-11-08 06:43:33 -0600 |
| commit | 55acea0bd769132db7bf420fef3b94fa21ca5f83 (patch) | |
| tree | d43fb2b485cf0b1439a48037cf129a76e1d53ad0 /update.go | |
| parent | 29545d3f048ccb148429725d76d0894336985c2b (diff) | |
use go-cmd/cmdv0.22.12
Diffstat (limited to 'update.go')
| -rw-r--r-- | update.go | 13 |
1 files changed, 3 insertions, 10 deletions
@@ -3,28 +3,21 @@ package repostatus import ( "errors" "fmt" - "strings" "time" "go.wit.com/log" ) func (rs *RepoStatus) gitBranchAll() { - err, out := rs.RunCmd([]string{"git", "branch", "--all"}) - log.Log(WARN, "git branch failed string =", rs.String()) - log.Log(WARN, "git branch failed realpath =", rs.realPath.String()) - if err != nil { + r := rs.Run([]string{"git", "branch", "--all"}) + if r.Error != nil { log.Log(WARN, "git branch failed string =", rs.String()) log.Log(WARN, "git branch failed realpath =", rs.realPath.String()) return } - all := strings.Split(out, "\n") - for _, s := range all { - // log.Log(WARN, "found branch", i, s) + for _, s := range r.Stdout { rs.targetBranch.AddText(s) } - // i := len(all) - // log.Log(WARN, "branch count =", i) } func (rs *RepoStatus) updateNew() { |
