even better bash
This commit is contained in:
parent
5434ab498b
commit
cd7d256a80
36
Makefile
36
Makefile
|
@ -6,12 +6,8 @@ info: install
|
||||||
@echo "make restart # remove the repos.pb file"
|
@echo "make restart # remove the repos.pb file"
|
||||||
@echo "make private # only the private ones"
|
@echo "make private # only the private ones"
|
||||||
@echo "make mine # just show my repos"
|
@echo "make mine # just show my repos"
|
||||||
@echo "make all # show all repos"
|
|
||||||
@echo "make pull # run git pull on every repo"
|
@echo "make pull # run git pull on every repo"
|
||||||
@echo "make dirty # CheckDirty()"
|
@echo "make dirty # CheckDirty()"
|
||||||
@echo "make user # git checkout user"
|
|
||||||
@echo "make master # git checkout master"
|
|
||||||
# forge
|
|
||||||
|
|
||||||
vet:
|
vet:
|
||||||
@GO111MODULE=off go vet
|
@GO111MODULE=off go vet
|
||||||
|
@ -37,33 +33,12 @@ gocui: install
|
||||||
private: install
|
private: install
|
||||||
forge list --private
|
forge list --private
|
||||||
|
|
||||||
fix: install
|
pull-mine: install
|
||||||
forge --fix list --all
|
|
||||||
|
|
||||||
list-all: install
|
|
||||||
forge list --all
|
|
||||||
|
|
||||||
git-reset: install
|
|
||||||
forge --do-git-reset list --all
|
|
||||||
|
|
||||||
readonly: install
|
|
||||||
forge --list list --readonly
|
|
||||||
|
|
||||||
config: install
|
|
||||||
forge config
|
|
||||||
|
|
||||||
scan: install
|
|
||||||
forge do --scan
|
|
||||||
|
|
||||||
pull: install
|
|
||||||
forge pull --mine
|
forge pull --mine
|
||||||
|
|
||||||
mine: install
|
mine: install
|
||||||
forge list --mine
|
forge list --mine
|
||||||
|
|
||||||
all: install
|
|
||||||
forge list --all
|
|
||||||
|
|
||||||
patches-make: install
|
patches-make: install
|
||||||
forge --patchset "from makefile 2"
|
forge --patchset "from makefile 2"
|
||||||
|
|
||||||
|
@ -83,12 +58,3 @@ restart:
|
||||||
reset
|
reset
|
||||||
-rm ~/go/src/repos.pb
|
-rm ~/go/src/repos.pb
|
||||||
make private
|
make private
|
||||||
|
|
||||||
user: install
|
|
||||||
forge user
|
|
||||||
|
|
||||||
devel: install
|
|
||||||
forge devel --all
|
|
||||||
|
|
||||||
master: install
|
|
||||||
forge master --all
|
|
||||||
|
|
6
argv.go
6
argv.go
|
@ -15,8 +15,8 @@ type EmptyCmd struct {
|
||||||
}
|
}
|
||||||
|
|
||||||
type PatchCmd struct {
|
type PatchCmd struct {
|
||||||
List bool `arg:"--list" help:"list available patches"`
|
List *EmptyCmd `arg:"subcommand:list" help:"list available patches"`
|
||||||
Show string `arg:"--show" help:"show a specific patch"`
|
Show *EmptyCmd `arg:"subcommand:show" help:"show a specific patch"`
|
||||||
}
|
}
|
||||||
|
|
||||||
type ConfigCmd struct {
|
type ConfigCmd struct {
|
||||||
|
@ -46,7 +46,7 @@ type args struct {
|
||||||
Checkout *CheckoutCmd `arg:"subcommand:checkout" help:"switch git branches"`
|
Checkout *CheckoutCmd `arg:"subcommand:checkout" help:"switch git branches"`
|
||||||
Config *ConfigCmd `arg:"subcommand:config" help:"show your .config/forge/ settings"`
|
Config *ConfigCmd `arg:"subcommand:config" help:"show your .config/forge/ settings"`
|
||||||
Dirty *EmptyCmd `arg:"subcommand:dirty" help:"check if your git repos are dirty"`
|
Dirty *EmptyCmd `arg:"subcommand:dirty" help:"check if your git repos are dirty"`
|
||||||
GitReset *EmptyCmd `arg:"subcommand:hard-reset" help:"hard reset your user git branch"`
|
GitReset *EmptyCmd `arg:"subcommand:hard-reset" help:"hard reset your user git branches"`
|
||||||
List *FindCmd `arg:"subcommand:list" help:"just show a table of the current state"`
|
List *FindCmd `arg:"subcommand:list" help:"just show a table of the current state"`
|
||||||
Patch *PatchCmd `arg:"subcommand:patch" help:"examine and make patch sets"`
|
Patch *PatchCmd `arg:"subcommand:patch" help:"examine and make patch sets"`
|
||||||
GitPull *FindCmd `arg:"subcommand:pull" help:"run 'git pull'"`
|
GitPull *FindCmd `arg:"subcommand:pull" help:"run 'git pull'"`
|
||||||
|
|
6
main.go
6
main.go
|
@ -141,13 +141,13 @@ func main() {
|
||||||
okExit("patches")
|
okExit("patches")
|
||||||
}
|
}
|
||||||
if argv.Patch != nil {
|
if argv.Patch != nil {
|
||||||
if argv.Patch.Show != "" {
|
if argv.Patch.Show != nil {
|
||||||
sendDevelDiff(argv.Patch.Show)
|
sendDevelDiff("fixme")
|
||||||
// sendMasterDiff()
|
// sendMasterDiff()
|
||||||
okExit("patches")
|
okExit("patches")
|
||||||
}
|
}
|
||||||
|
|
||||||
if argv.Patch.List {
|
if argv.Patch.List != nil {
|
||||||
listPatches()
|
listPatches()
|
||||||
okExit("patches")
|
okExit("patches")
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue