gitpb code is changing
This commit is contained in:
parent
fa5c6572ff
commit
3ab156a9c4
|
@ -81,45 +81,47 @@ func MakeRepoBranchesWindow(repo *gitpb.Repo) *repoBranchesWindow {
|
||||||
grid.NewGroup("Hash")
|
grid.NewGroup("Hash")
|
||||||
grid.NextRow()
|
grid.NextRow()
|
||||||
|
|
||||||
for _, b := range repo.GetLocalBranches() {
|
/*
|
||||||
hash := repo.GetBranchHash(b)
|
for _, b := range repo.GetLocalBranches() {
|
||||||
grid.NewLabel(b)
|
hash := repo.GetBranchHash(b)
|
||||||
grid.NewLabel(repo.GetBranchVersion(b))
|
grid.NewLabel(b)
|
||||||
if s, err := repo.GetHashName(hash); err == nil {
|
grid.NewLabel(repo.GetBranchVersion(b))
|
||||||
grid.NewLabel(s)
|
if s, err := repo.GetHashName(hash); err == nil {
|
||||||
} else {
|
grid.NewLabel(s)
|
||||||
grid.NewLabel("err")
|
} else {
|
||||||
}
|
grid.NewLabel("err")
|
||||||
grid.NewLabel("local")
|
}
|
||||||
|
grid.NewLabel("local")
|
||||||
|
|
||||||
grid.NewLabel(hash)
|
grid.NewLabel(hash)
|
||||||
grid.NewButton("Delete", func() {
|
grid.NewButton("Delete", func() {
|
||||||
repo.RunVerbose([]string{"git", "branch", "-D", b})
|
repo.RunVerbose([]string{"git", "branch", "-D", b})
|
||||||
})
|
|
||||||
grid.NextRow()
|
|
||||||
}
|
|
||||||
|
|
||||||
for _, b := range repo.GetRemoteBranches() {
|
|
||||||
hash := repo.GetBranchHash(b)
|
|
||||||
grid.NewLabel(b)
|
|
||||||
forgeuse := repo.GetBranchVersion(b)
|
|
||||||
grid.NewLabel(forgeuse)
|
|
||||||
if s, err := repo.GetHashName(hash); err == nil {
|
|
||||||
grid.NewLabel(s)
|
|
||||||
} else {
|
|
||||||
grid.NewLabel("")
|
|
||||||
}
|
|
||||||
grid.NewLabel("remote")
|
|
||||||
|
|
||||||
grid.NewLabel(hash)
|
|
||||||
if b == "origin/HEAD" || forgeuse == "remote master" {
|
|
||||||
// can't delete these
|
|
||||||
} else {
|
|
||||||
grid.NewButton("Delete Remote", func() {
|
|
||||||
})
|
})
|
||||||
|
grid.NextRow()
|
||||||
}
|
}
|
||||||
grid.NextRow()
|
|
||||||
}
|
for _, b := range repo.GetRemoteBranches() {
|
||||||
|
hash := repo.GetBranchHash(b)
|
||||||
|
grid.NewLabel(b)
|
||||||
|
forgeuse := repo.GetBranchVersion(b)
|
||||||
|
grid.NewLabel(forgeuse)
|
||||||
|
if s, err := repo.GetHashName(hash); err == nil {
|
||||||
|
grid.NewLabel(s)
|
||||||
|
} else {
|
||||||
|
grid.NewLabel("")
|
||||||
|
}
|
||||||
|
grid.NewLabel("remote")
|
||||||
|
|
||||||
|
grid.NewLabel(hash)
|
||||||
|
if b == "origin/HEAD" || forgeuse == "remote master" {
|
||||||
|
// can't delete these
|
||||||
|
} else {
|
||||||
|
grid.NewButton("Delete Remote", func() {
|
||||||
|
})
|
||||||
|
}
|
||||||
|
grid.NextRow()
|
||||||
|
}
|
||||||
|
*/
|
||||||
|
|
||||||
return pw
|
return pw
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue