From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 6437 invoked from network); 15 May 2001 02:26:17 -0000 Received: from sunsite.dk (130.225.51.30) by ns1.primenet.com.au with SMTP; 15 May 2001 02:26:17 -0000 Received: (qmail 5491 invoked by alias); 15 May 2001 02:26:07 -0000 Mailing-List: contact zsh-workers-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 14341 Received: (qmail 5460 invoked from network); 15 May 2001 02:26:03 -0000 Date: Mon, 14 May 2001 22:26:01 -0400 From: Clint Adams To: zsh-workers@sunsite.dk Subject: PATCH: rmmod/modprobe -r completion Message-ID: <20010514222601.A18298@dman.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i This lacks all the other options to modprobe, and ignores insmod, but it seemed silly to just do rmmod and not have it work for modprobe -r. Index: Completion/Unix/Command/.distfiles =================================================================== RCS file: /cvsroot/zsh/zsh/Completion/Unix/Command/.distfiles,v retrieving revision 1.4 diff -u -r1.4 .distfiles --- Completion/Unix/Command/.distfiles 2001/05/03 13:05:49 1.4 +++ Completion/Unix/Command/.distfiles 2001/05/15 02:17:10 @@ -14,5 +14,5 @@ _dd _gprof _lynx _perldoc _telnet _pine _dict _grep _lzop _prcs _tiff _elm _diff _gs _make _psutils _tin _apm _mail -_loadkeys +_loadkeys _modutils ' Index: Completion/Unix/Command/_modutils =================================================================== RCS file: _modutils diff -N _modutils --- /dev/null Mon Dec 11 17:26:27 2000 +++ _modutils Mon May 14 19:17:10 2001 @@ -0,0 +1,44 @@ +#compdef modprobe rmmod + +local loaded + +_modutils_loaded_modules() { + +if [[ -f /proc/modules ]]; then + loaded=(${${(f)"$(