summary refs log tree commit diff
path: root/Functions/Completion/_dd
diff options
context:
space:
mode:
Diffstat (limited to 'Functions/Completion/_dd')
-rw-r--r--Functions/Completion/_dd13
1 files changed, 13 insertions, 0 deletions
diff --git a/Functions/Completion/_dd b/Functions/Completion/_dd
new file mode 100644
index 000000000..2458541ea
--- /dev/null
+++ b/Functions/Completion/_dd
@@ -0,0 +1,13 @@
+#defcomp dd
+
+if [[ -iprefix conv= ]]; then
+  # If there's a comma present, ignore up to the last one.  The
+  # test alone will have that effect.
+  [[ -string , ]]
+  complist -S, -q \
+  -k '(ascii ebcdic ibm block unblock lcase ucase swab noerror sync)'
+elif [[ -iprefix 'if=' || -iprefix 'of=' ]]; then
+  _files
+else
+  complist -S '=' -k '(if of ibs obs bs cbs skip files seek count conv)'
+fi