]> git.ipfire.org Git - thirdparty/util-linux.git/blobdiff - bash-completion/hwclock
su: use lib/pty-session.c code for --pty
[thirdparty/util-linux.git] / bash-completion / hwclock
index 855e8857561b047e370cc6e8644a526189e429b8..faf29afe9af4d59a94cff6be1b82faf8a100fb07 100644 (file)
@@ -6,44 +6,49 @@ _hwclock_module()
        prev="${COMP_WORDS[COMP_CWORD-1]}"
        case $prev in
                '-f'|'--rtc'|'--adjfile')
+                       local IFS=$'\n'
                        compopt -o filenames
                        COMPREPLY=( $(compgen -f -- $cur) )
                        return 0
                        ;;
-               '--date')
-                       COMPREPLY=( $(compgen -W "date" -- $cur) )
+               '--date'|'--delay')
+                       COMPREPLY=( $(compgen -W "time" -- $cur) )
                        return 0
                        ;;
                '--epoch')
                        COMPREPLY=( $(compgen -W "year" -- $cur) )
                        return 0
                        ;;
+               '-h'|'-?'|'--help'|'-v'|'-V'|'--version')
+                       return 0
+                       ;;
        esac
        case $cur in
                -*)
-                       OPTS="-h --help
-                               -r --show
-                                  --set
-                               -s --hctosys
-                               -w --systohc
-                                  --systz
-                                  --adjust
-                               -c --compare
-                                  --getepoch
-                                  --setepoch
-                                  --predict
-                               -V --version
-                               -u --utc
-                                  --localtime
-                               -f --rtc
-                                  --directisa
-                                  --badyear
-                                  --date
-                                  --epoch
-                                  --noadjfile
-                                  --adjfile
-                                  --test
-                               -D --debug"
+                       OPTS="--help
+                               --show
+                               --get
+                               --set
+                               --hctosys
+                               --systohc
+                               --systz
+                               --adjust
+                               --getepoch
+                               --setepoch
+                               --predict
+                               --version
+                               --utc
+                               --localtime
+                               --rtc
+                               --directisa
+                               --date
+                               --delay
+                               --epoch
+                               --update-drift
+                               --noadjfile
+                               --adjfile
+                               --test
+                               --debug"
                        COMPREPLY=( $(compgen -W "${OPTS[*]}" -- $cur) )
                        return 0
                        ;;