diff options
author | Christian Hesse | 2022-10-24 09:13:43 +0200 |
---|---|---|
committer | Christian Hesse | 2022-10-24 09:13:43 +0200 |
commit | 5c4101c618f2873466f621d0fa1e8b5a792a0e8c (patch) | |
tree | 939b058faaa625df25ac3b35bea6c5d85cf61993 /bash_completion | |
parent | b4e640fa77ec6ab904be3e0777e3423755a7dd5e (diff) | |
download | aur-claws-mail-git.tar.gz |
commit claws-mail-git 4.1.1.r1.g1e3b95e1d-1
Diffstat (limited to 'bash_completion')
-rw-r--r-- | bash_completion | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/bash_completion b/bash_completion new file mode 100644 index 000000000000..dcbcc8920759 --- /dev/null +++ b/bash_completion @@ -0,0 +1,30 @@ +# claws-mail(1) completion +_claws-mail() +{ + local cur prev words cword + _init_completion || return + + case $prev in + --help|-h|--version|-v|--version-full|-V) + return + ;; + --alternate-config-dir) + COMPREPLY=( $( find . -maxdepth 2 -name clawsrc | sed 's,/clawsrc,,' ) ) + return + ;; + --select|--status|--status-full) + _filedir -d + return + ;; + --compose-from-file|--attach) + _filedir + return + ;; + esac + + if [[ $cur == -* ]]; then + COMPREPLY=( $( compgen -W '$( _parse_help "$1" )' -- "$cur" ) ) + return + fi +} && +complete -F _claws-mail claws-mail |