zsh-workers
 help / color / mirror / code / Atom feed
* PATCH: simple objdump completion plus tweak to _nm
@ 2015-10-15 10:07 Peter Stephenson
  0 siblings, 0 replies; only message in thread
From: Peter Stephenson @ 2015-10-15 10:07 UTC (permalink / raw)
  To: Zsh Hackers' List

diff --git a/Completion/Unix/Command/_nm b/Completion/Unix/Command/_nm
index 8013632..d171ef5 100644
--- a/Completion/Unix/Command/_nm
+++ b/Completion/Unix/Command/_nm
@@ -6,7 +6,7 @@ _nm_object_file() {
   [[ -x $REPLY || $REPLY = *.([ao]|so|elf) ]]
 }
 
-files="*:object file:_files -g '*(-.e:_nm_object_file:)'"
+files="*:object file:_files -g '*(-.e,_nm_object_file,)'"
 args=(
   '(-A -o --print-file-name)'{-A,-o,--print-file-name}'[print name of input file on each line]'
   '(--demangle)-C[decode symbol names]'
diff --git a/Completion/Unix/Command/_objdump b/Completion/Unix/Command/_objdump
new file mode 100644
index 0000000..607719a
--- /dev/null
+++ b/Completion/Unix/Command/_objdump
@@ -0,0 +1,8 @@
+#compdef objdump
+
+# borrowed from _nm_object_file
+_objdump_object_file() {
+  [[ -x $REPLY || $REPLY = *.([ao]|so|elf) ]]
+}
+
+_arguments -- '*:object file:_files -g "*(-.e,_objdump_object_file,)"'


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2015-10-15 10:17 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-10-15 10:07 PATCH: simple objdump completion plus tweak to _nm Peter Stephenson

Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).