zsh-workers
 help / color / mirror / code / Atom feed
* [PATCH] modprobe module parameters completion
@ 2014-01-17  1:51 sergio
  0 siblings, 0 replies; only message in thread
From: sergio @ 2014-01-17  1:51 UTC (permalink / raw)
  To: Zsh Hackers' List

modinfo is not in the default user $path, so
% sudo modprobe module <tab>
doesn't complete anything.

diff -Naur zsh-orig/Completion/Linux/Command/_modutils
zsh/Completion/Linux/Command/_modutils
--- zsh-orig/Completion/Linux/Command/_modutils 2014-01-17
05:45:30.521883787 +0400
+++ zsh/Completion/Linux/Command/_modutils      2014-01-17
05:47:03.161614562 +0400
@@ -127,7 +127,7 @@
                _message -e value 'parameter value'
            else
                local params
-               params=( ${${(M)${(f)"$(_call_program module_parameter
modinfo "$words[2]" 2>/dev/null)"}:#parm:*}##parm:[[:space:]]##} )
+               params=( ${${(M)${(f)"$(_call_program module_parameter
/sbin/modinfo "$words[2]" 2>/dev/null)"}:#parm:*}##parm:[[:space:]]##} )
                if [[ $#params -eq 0 ]]; then
                    _message -e parameter "This modules doesn't have
parameters"
                else


-- 
sergio.


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

only message in thread, other threads:[~2014-01-17  2:11 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-01-17  1:51 [PATCH] modprobe module parameters completion sergio

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).