diff options
Diffstat (limited to 'scripts/get.sh')
| -rwxr-xr-x | scripts/get.sh | 25 |
1 files changed, 1 insertions, 24 deletions
diff --git a/scripts/get.sh b/scripts/get.sh index fa8cc3005..607a4cbc2 100755 --- a/scripts/get.sh +++ b/scripts/get.sh @@ -175,30 +175,7 @@ install_profile() { if [ ! -d ~/.xmake ]; then mkdir ~/.xmake; fi echo "export PATH=$prefix/bin:\$PATH" > ~/.xmake/profile - echo ' -if [[ "$SHELL" = */zsh ]]; then - # zsh parameter completion for xmake - _xmake_zsh_complete() - { - local completions=("$(XMAKE_SKIP_HISTORY=1 xmake lua --root private.utils.complete 0 nospace "$words")") - reply=( "${(ps:\n:)completions}" ) - } - compctl -f -S "" -K _xmake_zsh_complete xmake -elif [[ "$SHELL" = */bash ]]; then - # bash parameter completion for xmake - _xmake_bash_complete() - { - local word=${COMP_WORDS[COMP_CWORD]} - local completions - completions="$(XMAKE_SKIP_HISTORY=1 xmake lua --root private.utils.complete "${COMP_POINT}" "conf" "${COMP_LINE}" 2>/dev/null)" - if [ $? -ne 0 ]; then - completions="" - fi - COMPREPLY=( $(compgen -W "$completions" -- "$word") ) - } - complete -o default -o nospace -F _xmake_bash_complete xmake -fi -' >> ~/.xmake/profile + remote_get_content "https://github.com/$mirror/xmake/raw/master/scripts/register-completions.sh" >> ~/.xmake/profile if [[ "$SHELL" = */zsh ]]; then write_profile ~/.zshrc |
