]> git.ipfire.org Git - thirdparty/util-linux.git/blobdiff - bash-completion/unshare
bash-completion: Don't offer any more completions after help or version.
[thirdparty/util-linux.git] / bash-completion / unshare
index 295d02f90ce123c6984ca2fe3113674cfcf49d9e..5342961f6028c238414aa23303b2e3949bcea28d 100644 (file)
@@ -1,8 +1,14 @@
 _unshare_module()
 {
-       local cur OPTS
+       local cur prev OPTS
        COMPREPLY=()
        cur="${COMP_WORDS[COMP_CWORD]}"
+       prev="${COMP_WORDS[COMP_CWORD-1]}"
+       case $prev in
+               '-h'|'--help'|'-V'|'--version')
+                       return 0
+                       ;;
+       esac
        case $cur in
                -*)
                        OPTS="-m --mount