zsh-workers
 help / color / mirror / code / Atom feed
From: sergio <mailbox@sergio.spb.ru>
To: Zsh Hackers' List <zsh-workers@zsh.org>
Subject: [PATCH] modprobe module parameters completion
Date: Fri, 17 Jan 2014 05:51:20 +0400	[thread overview]
Message-ID: <52D88C98.9080509@sergio.spb.ru> (raw)

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.


                 reply	other threads:[~2014-01-17  2:11 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=52D88C98.9080509@sergio.spb.ru \
    --to=mailbox@sergio.spb.ru \
    --cc=zsh-workers@zsh.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).