summaryrefslogtreecommitdiffstats
path: root/bash-completion/hexdump
diff options
context:
space:
mode:
authorSami Kerola2013-04-13 21:54:36 +0200
committerKarel Zak2013-04-26 13:26:00 +0200
commitcdeb4292e9e1c1f1e8ec64097d40307f682311f1 (patch)
tree65db705876f37ed01270dd860fa28b5720a23732 /bash-completion/hexdump
parentsetpriv: allow login and group name option arguments (diff)
downloadkernel-qcow2-util-linux-cdeb4292e9e1c1f1e8ec64097d40307f682311f1.tar.gz
kernel-qcow2-util-linux-cdeb4292e9e1c1f1e8ec64097d40307f682311f1.tar.xz
kernel-qcow2-util-linux-cdeb4292e9e1c1f1e8ec64097d40307f682311f1.zip
hexdump: add long options to the command
Includes update to bash completion, and manual as well. Signed-off-by: Sami Kerola <kerolasa@iki.fi>
Diffstat (limited to 'bash-completion/hexdump')
-rw-r--r--bash-completion/hexdump22
1 files changed, 17 insertions, 5 deletions
diff --git a/bash-completion/hexdump b/bash-completion/hexdump
index 0c91187f1..aa6f8cefd 100644
--- a/bash-completion/hexdump
+++ b/bash-completion/hexdump
@@ -5,25 +5,37 @@ _hexdump_module()
cur="${COMP_WORDS[COMP_CWORD]}"
prev="${COMP_WORDS[COMP_CWORD-1]}"
case $prev in
- '-e')
+ '-e'|'--format')
COMPREPLY=( $(compgen -W "format" -- $cur) )
return 0
;;
- '-n')
+ '-n'|'--length')
COMPREPLY=( $(compgen -W "length" -- $cur) )
return 0
;;
- '-s')
+ '-s'|'--skip')
COMPREPLY=( $(compgen -W "offset" -- $cur) )
return 0
;;
- '-V')
+ '-V'|'--version'|'-h'|'--help')
return 0
;;
esac
case $cur in
-*)
- OPTS="-b -c -C -d -o -x -e -f -n -s -v -V"
+ OPTS=" --one-byte-octal
+ --one-byte-char
+ --canonical
+ --two-bytes-decimal
+ --two-bytes-octal
+ --two-bytes-hex
+ --format
+ --format-file
+ --length
+ --skip
+ --no-squeezing
+ --version
+ --help"
COMPREPLY=( $(compgen -W "${OPTS[*]}" -- $cur) )
return 0
;;