1234567891011121314151617181920212223242526272829303132333435363738 |
- #!/bin/bash
-
- __SATURNIN_COMPLETE_CMDNAME=__MKIT_PROJ_PKGNAME__
-
- #shellcheck disable=SC2016
- __SATURNIN_COMPLETE_CODETMPL='
- __%s() {
- local cur opts sopts
- COMPREPLY=()
- cur="${COMP_WORDS[COMP_CWORD]}"
- sopts="-d -h -v"
- opts="--help --verbose --debug --version --version-semver"
- case "$cur" in
- -*)
- COMPREPLY=(
- $(compgen -W "$sopts $opts" -- "${cur}")
- )
- ;;
- --*)
- COMPREPLY=(
- $(compgen -W "$opts" -- "${cur}")
- )
- ;;
- *)
- COMPREPLY=(
- $(compgen -W "$(%s _ls_sc)" "${cur}")
- )
- esac
- }'
-
- eval "$(
- #shellcheck disable=SC2059
- printf "$__SATURNIN_COMPLETE_CODETMPL" \
- $__SATURNIN_COMPLETE_CMDNAME \
- $__SATURNIN_COMPLETE_CMDNAME
- )"
-
- complete -F "__$__SATURNIN_COMPLETE_CMDNAME" "$__SATURNIN_COMPLETE_CMDNAME"
|