Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
[PATCH 2/3] Replace obsolate modprobe -l by file search
- X-seq: zsh-workers 26451
- From: JÃrg Sommer <joerg@xxxxxxxxxxxx>
- To: zsh-workers@xxxxxxxxxx
- Subject: [PATCH 2/3] Replace obsolate modprobe -l by file search
- Date: Mon, 26 Jan 2009 22:10:47 +0100
- Cc: JÃrg Sommer <joerg@xxxxxxxxxxxx>
- Dkim-signature: v=1; a=rsa-sha256; c=simple/simple; d=gnuu.de; s=banki; t=1233004622; i=@xxxxxxxxxxxx; bh=FQrV5XloKJCqwJkDz7UTz2ENAP2s+I3rg /BWBogDGfY=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To: References:MIME-Version:Content-Type:Content-Transfer-Encoding; b=iZo/lVmUySlFLWteyK/Q4Tw1DtN7Rnt3px017vkScmd7VsQkd21kvNWqr2XU7Tu4M XDZC71abkOOWTNSH0/dtEFFlmoyOVpP8h0cN65ZPNCqSUyvp1+7fgkYshHJMtXCYACR fbIQ1FKsW1gxhEhXC+6CfbBuIqMVmPnBd7Oczfw=
- In-reply-to: <1233004248-24000-1-git-send-email-joerg@xxxxxxxxxxxx>
- Mailing-list: contact zsh-workers-help@xxxxxxxxxx; run by ezmlm
- References: <1233004248-24000-1-git-send-email-joerg@xxxxxxxxxxxx>
In the manual page of the current modprobe (version 3.4) the option -l is
marked as obsolate; âThis option is provided for backwards
compatibility.â So use Zsh tools to get the name of the modules. The base
directory is takes from the manual page that says: âmodprobe looks in
the module directory /lib/modules/âuname -râ for all the modules [â].â
---
Completion/Linux/Command/_modutils | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/Completion/Linux/Command/_modutils b/Completion/Linux/Command/_modutils
index db419ac..fe1b58e 100644
--- a/Completion/Linux/Command/_modutils
+++ b/Completion/Linux/Command/_modutils
@@ -77,7 +77,7 @@ case "$state" in
;&
all_modules)
- modules=( ${${${${(f)"$(_call_program modules ${(M)words[1]##*/}modprobe -l 2>/dev/null)"}:#}##*/}%%.*} )
+ modules=( /lib/modules/$(uname -r)/(*~source)/**/*(.:t:r) )
if [[ $state = loadable_modules ]]; then
modules=( ${modules:#(${(j:|:)~${=loaded_modules//_/-}})} )
--
1.6.0.6
Messages sorted by:
Reverse Date,
Date,
Thread,
Author