local cmds="build clean env fix fmt get
install list run test tool version vet"
- local addhelp="gopath importpath remote
- testflag testfunc"
+ local addhelp="c gopath importpath packages testflag testfunc"
local other="help"
if [ "$COMP_CWORD" == 1 ]; then
'dist') # TODO: Implement something.
#_go_tool_dist
;;
- 'ebnflint') # TODO: Implement something.
- #_go_tool_ebnflint
- ;;
'fix') # TODO: Implement something.
#_go_tool_fix
;;
- 'gotype') # TODO: Implement something.
- #_go_tool_gotype
- ;;
'nm') # TODO: Implement something.
#_go_tool_nm
;;
'pprof') # TODO: Implement something.
#_go_tool_pprof
;;
- 'prof') # TODO: Implement something.
- #_go_tool_prof
- ;;
'vet') # TODO: Implement something.
#_go_tool_vet
;;
commands+=(
'build[compile packages and dependencies]'
'clean[remove object files]'
- 'doc[run godoc on package sources]'
'env[print Go environment information]'
'fix[run go tool fix on packages]'
'fmt[run gofmt on package sources]'
"-short[use short mode]" \
"-parallel[number of parallel tests]:number" \
"-cpu[values of GOMAXPROCS to use]:number list" \
+ "-cover[enable coverage analysis]" \
"-run[run tests and examples matching regexp]:regexp" \
"-bench[run benchmarks matching regexp]:regexp" \
"-benchmem[print memory allocation stats]" \
;;
help)
_values "${commands[@]}" \
+ 'c[how to call C code]' \
+ 'importpath[description of import path]' \
'gopath[GOPATH environment variable]' \
'packages[description of package lists]' \
- 'remote[remote import path syntax]' \
'testflag[description of testing flags]' \
'testfunc[description of testing functions]'
;;