minor fixes
This commit is contained in:
parent
1d89d38bc3
commit
1dd4a2d979
1
argv.go
1
argv.go
|
@ -106,7 +106,6 @@ type DirtyCmd struct {
|
||||||
}
|
}
|
||||||
|
|
||||||
type FindCmd struct {
|
type FindCmd struct {
|
||||||
Pub *EmptyCmd `arg:"subcommand:pub" help:"fix .config/forge/ and/or repos.pb protobuf file"`
|
|
||||||
All bool `arg:"--all" help:"select every repo (the default)"`
|
All bool `arg:"--all" help:"select every repo (the default)"`
|
||||||
Mine bool `arg:"--mine" help:"your repos as defined in the forge config"`
|
Mine bool `arg:"--mine" help:"your repos as defined in the forge config"`
|
||||||
Favorites bool `arg:"--favorites" help:"your repos configured as favorites"`
|
Favorites bool `arg:"--favorites" help:"your repos configured as favorites"`
|
||||||
|
|
|
@ -42,7 +42,7 @@ func (args) doBashAuto() {
|
||||||
case "examine":
|
case "examine":
|
||||||
fmt.Println("fix")
|
fmt.Println("fix")
|
||||||
case "list":
|
case "list":
|
||||||
fmt.Println("--all --mine --favorites --private pub")
|
fmt.Println("--all --mine --favorites --private")
|
||||||
case "pull":
|
case "pull":
|
||||||
fmt.Println("--verbose")
|
fmt.Println("--verbose")
|
||||||
case "patch":
|
case "patch":
|
||||||
|
|
14
find.go
14
find.go
|
@ -20,11 +20,6 @@ func (f *FindCmd) findRepos() {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
if f.Pub != nil {
|
|
||||||
findPublishable()
|
|
||||||
return
|
|
||||||
}
|
|
||||||
|
|
||||||
if f.All {
|
if f.All {
|
||||||
findAll()
|
findAll()
|
||||||
return
|
return
|
||||||
|
@ -137,13 +132,20 @@ func findReposWithPatches() {
|
||||||
all := me.forge.Repos.SortByFullPath()
|
all := me.forge.Repos.SortByFullPath()
|
||||||
for all.Scan() {
|
for all.Scan() {
|
||||||
repo := all.Next()
|
repo := all.Next()
|
||||||
if repo.GetUserVersion() == "" || repo.GetUserVersion() == "uerr" {
|
if repo.GetTargetVersion() != "" {
|
||||||
|
// add everything that has a target version set
|
||||||
|
me.found.AppendByGoPath(repo)
|
||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
if repo.IsDirty() {
|
if repo.IsDirty() {
|
||||||
|
// always add dirty branches
|
||||||
me.found.AppendByGoPath(repo)
|
me.found.AppendByGoPath(repo)
|
||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
|
if repo.GetUserVersion() == "" || repo.GetUserVersion() == "uerr" {
|
||||||
|
// skip anything without a user branch
|
||||||
|
continue
|
||||||
|
}
|
||||||
if repo.GetUserVersion() != repo.GetDevelVersion() {
|
if repo.GetUserVersion() != repo.GetDevelVersion() {
|
||||||
me.found.AppendByGoPath(repo)
|
me.found.AppendByGoPath(repo)
|
||||||
continue
|
continue
|
||||||
|
|
|
@ -169,6 +169,7 @@ func (r *patchesWindow) addPatchsetNew(pset *forgepb.Patchset) {
|
||||||
r.psetgrid.NewLabel(pset.Name)
|
r.psetgrid.NewLabel(pset.Name)
|
||||||
r.psetgrid.NewLabel(pset.Comment)
|
r.psetgrid.NewLabel(pset.Comment)
|
||||||
r.psetgrid.NewLabel(pset.GitAuthorName)
|
r.psetgrid.NewLabel(pset.GitAuthorName)
|
||||||
|
r.psetgrid.NewLabel(pset.Uuid)
|
||||||
|
|
||||||
ctime := pset.Ctime.AsTime()
|
ctime := pset.Ctime.AsTime()
|
||||||
stime := ctime.UTC().Format("2006-01-02_15:04:05_UTC")
|
stime := ctime.UTC().Format("2006-01-02_15:04:05_UTC")
|
||||||
|
|
Loading…
Reference in New Issue