diff options
author | kitsunyan | 2018-06-03 00:58:08 +0000 |
---|---|---|
committer | kitsunyan | 2018-06-03 00:58:08 +0000 |
commit | c5a91071172e206b5d02bed66e893469bde17629 (patch) | |
tree | e3dc0ce19a52aefce1c1b54e5166eaaa74a0d049 /completion | |
parent | 935031e8f559f06d5d9880707dfa96168a145e7d (diff) |
Update shell completions
Diffstat (limited to 'completion')
l---------[-rw-r--r--] | completion/zsh-git.patch | 51 | ||||
-rw-r--r-- | completion/zsh.patch | 4 |
2 files changed, 3 insertions, 52 deletions
diff --git a/completion/zsh-git.patch b/completion/zsh-git.patch index adf7edd..6d8b002 100644..120000 --- a/completion/zsh-git.patch +++ b/completion/zsh-git.patch @@ -1,50 +1 @@ ---- a/zsh -+++ b/zsh -@@ -1,1 +1,1 @@ --#compdef pacman pacman.static=pacman pacman-key makepkg -+#compdef pakku -@@ -139,2 +139,6 @@ - '--print-format[Specify how the targets should be printed]' -+ {-n,--build}'[Build targets from source]' -+ '--keyserver[Keyserver to receive keys from]' -+ '--noaur[Disable all AUR operations]' -+ {-z,--source}'[Retrieve PKGBUILD source]' - ) -@@ -310,1 +314,6 @@ -- packages=( $(_call_program packages $cmd[@] -Sql ${words[CURRENT]%/*}) ) -+ if [[ ${words[CURRENT]%/*} == 'aur' ]]; then -+ packages=( $(_call_program packages $cmd[@] -Ss ${words[CURRENT]#*/} | -+ grep -Po '(?<=^aur/)[^ ]+') ) -+ else -+ packages=( $(_call_program packages $cmd[@] -Sql ${words[CURRENT]%/*}) ) -+ fi -@@ -314,1 +323,1 @@ -- packages=( $(_call_program packages $cmd[@] -Sql) ) -+ packages=( $(_call_program packages $cmd[@] -Ssq ${words[CURRENT]}) ) -@@ -318,1 +327,1 @@ -- repositories=($(pacman-conf --repo-list)) -+ repositories=($(pacman-conf --repo-list) aur) -@@ -361,1 +370,1 @@ -- cmd=( "pacman" "2>/dev/null") -+ cmd=("pakku" "2>/dev/null") -@@ -371,1 +380,1 @@ --_pakku_zsh_comp() { -+_pakku_comp() { -@@ -501,17 +510,0 @@ -- --_pakku_comp() { -- case "$service" in -- makepkg) -- _makepkg "$@" -- ;; -- pacman-key) -- _pakku_key "$@" -- ;; -- pacman) -- _pakku_zsh_comp "$@" -- ;; -- *) -- _message "Error" -- ;; -- esac --} +zsh.patch
\ No newline at end of file diff --git a/completion/zsh.patch b/completion/zsh.patch index c3eb8c9..adf7edd 100644 --- a/completion/zsh.patch +++ b/completion/zsh.patch @@ -22,8 +22,8 @@ - packages=( $(_call_program packages $cmd[@] -Sql) ) + packages=( $(_call_program packages $cmd[@] -Ssq ${words[CURRENT]}) ) @@ -318,1 +327,1 @@ -- repositories=(${(o)${${${(M)${(f)"$(</etc/pacman.conf)"}:#\[*}/\[/}/\]/}:#options}) -+ repositories=(${(o)${${${(M)${(f)"$(</etc/pacman.conf)"}:#\[*}/\[/}/\]/}:#options} aur) +- repositories=($(pacman-conf --repo-list)) ++ repositories=($(pacman-conf --repo-list) aur) @@ -361,1 +370,1 @@ - cmd=( "pacman" "2>/dev/null") + cmd=("pakku" "2>/dev/null") |