Make some go compiler commands available

This commit is contained in:
斟酌 鵬兄 2022-09-12 18:41:23 +08:00
parent 100162f4b0
commit 248dc44eec

View File

@ -29,19 +29,25 @@ function _begin_sel() {
}
function go() {
local i
local i _GO
ARG1=$1; ARG2=$2; ARG3=$3;
if [[ -z "$ARG1" ]]; then
__func_head "[MODE] SITE TARGET_DIR [..SLICE]"
__func_help "up [MODE] TARGET_DIR"
__func_help "down [MODE] TARGET_DIR [..SLICE]"
__func_help "compiler commands use \"go help\""
echo
return 1
fi
NAV=false
case "$ARG1" in
bug|build|clean|doc|env|fix|fmt|generate|get|install|list|mod|work|run|test|tool|version|vet|help)
_GO=$( which go )
$_GO $@
return $?
;;
p)
shift
CC='pushd' ;;