summaryrefslogtreecommitdiffstats
path: root/completions/chromium-browser
diff options
context:
space:
mode:
Diffstat (limited to 'completions/chromium-browser')
-rw-r--r--completions/chromium-browser26
1 files changed, 13 insertions, 13 deletions
diff --git a/completions/chromium-browser b/completions/chromium-browser
index 9ee9896..2126ac6 100644
--- a/completions/chromium-browser
+++ b/completions/chromium-browser
@@ -1,50 +1,50 @@
# chromium-browser completion -*- shell-script -*-
-_chromium_browser()
+_comp_cmd_chromium_browser()
{
- local cur prev words cword split
- _init_completion -s -n : || return
+ local cur prev words cword was_split comp_args
+ _comp_initialize -s -n : -- "$@" || return
case $prev in
--help | --app | --proxy-pac-url | -h)
return
;;
--user-data-dir)
- _filedir -d
+ _comp_compgen_filedir -d
return
;;
--proxy-server)
case $cur in
*://*)
local prefix="${cur%%://*}://"
- _known_hosts_real -- "${cur#*://}"
- COMPREPLY=("${COMPREPLY[@]/#/$prefix}")
- __ltrim_colon_completions "$cur"
+ _comp_compgen_known_hosts -- "${cur#*://}" &&
+ _comp_compgen -Rv COMPREPLY -- -P "$prefix" -W '"${COMPREPLY[@]}"'
+ _comp_ltrim_colon_completions "$cur"
;;
*)
compopt -o nospace
- COMPREPLY=($(compgen -S :// -W 'http socks socks4 socks5' -- "$cur"))
+ _comp_compgen -- -S :// -W 'http socks socks4 socks5'
;;
esac
return
;;
--password-store)
- COMPREPLY=($(compgen -W 'basic gnome kwallet' -- "$cur"))
+ _comp_compgen -- -W 'basic gnome kwallet'
return
;;
esac
- $split && return
+ [[ $was_split ]] && return
if [[ $cur == -* ]]; then
- COMPREPLY=($(compgen -W '$(_parse_help "$1")' -- "$cur"))
+ _comp_compgen_help
[[ ${COMPREPLY-} == *= ]] && compopt -o nospace
return
fi
- _filedir "@(?([mxs])htm?(l)|pdf|txt)"
+ _comp_compgen_filedir "@(?([mxs])htm?(l)|pdf|txt)"
} &&
- complete -F _chromium_browser chromium-browser google-chrome \
+ complete -F _comp_cmd_chromium_browser chromium-browser google-chrome \
google-chrome-stable chromium chrome
# ex: filetype=sh