summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--branchesBox.go26
-rw-r--r--modifyBox.go26
2 files changed, 25 insertions, 27 deletions
diff --git a/branchesBox.go b/branchesBox.go
index f692d2e..9aa78b9 100644
--- a/branchesBox.go
+++ b/branchesBox.go
@@ -38,30 +38,4 @@ func (rs *RepoStatus) makeBranchesBox() {
log.Log(WARN, "Branches are not perfect")
}
})
- newgrid.NextRow()
-
- newgrid.NewButton("show .git/config", func() {
- if rs.gitConfig == nil {
- log.Log(WARN, "Nonexistant or damaged .git/config", rs.String())
- return
- }
- log.Log(WARN, ".git/config:", rs.realPath.String())
-
- // The info:
- for name, remote := range rs.gitConfig.remotes {
- log.Log(WARN, " ", name, "url:", remote.url)
- }
- for name, branch := range rs.gitConfig.branches {
- log.Log(WARN, " ", name, "remote:", branch.remote, "merge", branch.merge)
- }
- })
- newgrid.NextRow()
-
- newgrid.NewButton("CheckDirty()", func() {
- if rs.CheckDirty() {
- log.Log(WARN, "is dirty")
- } else {
- log.Log(WARN, "is not dirty")
- }
- })
}
diff --git a/modifyBox.go b/modifyBox.go
index 098dbe0..cb9ccd5 100644
--- a/modifyBox.go
+++ b/modifyBox.go
@@ -13,7 +13,15 @@ func (rs *RepoStatus) drawGitCommands() {
rs.Update()
})
- newgrid.NewButton("Show tags", func() {
+ newgrid.NewButton("CheckDirty()", func() {
+ if rs.CheckDirty() {
+ log.Log(WARN, "is dirty")
+ } else {
+ log.Log(WARN, "is not dirty")
+ }
+ })
+
+ newgrid.NewButton("git tags window", func() {
if rs.TagsW == nil {
log.Warn("error: found rs.TagsW == nil")
rs.TagsW = rs.TagWindow()
@@ -25,6 +33,22 @@ func (rs *RepoStatus) drawGitCommands() {
rs.TagsW.Show()
}
})
+
+ newgrid.NewButton("show .git/config", func() {
+ if rs.gitConfig == nil {
+ log.Log(WARN, "Nonexistant or damaged .git/config", rs.String())
+ return
+ }
+ log.Log(WARN, ".git/config:", rs.realPath.String())
+
+ // The info:
+ for name, remote := range rs.gitConfig.remotes {
+ log.Log(WARN, " ", name, "url:", remote.url)
+ }
+ for name, branch := range rs.gitConfig.branches {
+ log.Log(WARN, " ", name, "remote:", branch.remote, "merge", branch.merge)
+ }
+ })
newgrid.NextRow()
newgrid.NewButton("git pull", func() {