zsh-workers
 help / color / mirror / code / Atom feed
From: Adam Spiers <adam@thelonious.new.ox.ac.uk>
To: zsh workers mailing list <zsh-workers@sunsite.auc.dk>
Subject: PATCH: _perl* cleanups
Date: Wed, 29 Sep 1999 19:54:44 +0100	[thread overview]
Message-ID: <19990929195444.A15831@thelonious.new.ox.ac.uk> (raw)

One bugfix and whitespace cleanups (2 space indents in Completion/
seem to be the convention, which ties in nicely with my personal
tastes).

Index: Completion/User/_perl_modules
===================================================================
RCS file: /usr/local/cvsroot/zsh/Completion/User/_perl_modules,v
retrieving revision 1.1.1.2
diff -u -r1.1.1.2 _perl_modules
--- Completion/User/_perl_modules	1999/09/21 12:17:48	1.1.1.2
+++ Completion/User/_perl_modules	1999/09/29 00:18:20
@@ -21,22 +21,22 @@
   else
     local inc libdir new_pms
     inc=( $( perl -e 'print "@INC"' ) )
-    typeset -agU _perl_modules	# _perl_modules is global, no duplicates
+    typeset -agU _perl_modules  # _perl_modules is global, no duplicates
     _perl_modules=( )
 
     for libdir in $inc; do
-        # Ignore cwd - could be too expensive e.g. if we're near /
-        if [[ $libdir == '.' ]]; then break; fi
+      # Ignore cwd - could be too expensive e.g. if we're near /
+      if [[ $libdir == '.' ]]; then break; fi
 
-	# Find all modules
-	cd $libdir
-        new_pms=( {[A-Z]*/**/,}*.pm(N) )
-	cd $OLDPWD
+      # Find all modules
+      cd $libdir
+      new_pms=( {[A-Z]*/**/,}*.pm(N) )
+      cd $OLDPWD
 
-	# Convert to Perl nomenclature
-	new_pms=( ${new_pms:r:fs#/#::#} )
+      # Convert to Perl nomenclature
+      new_pms=( ${new_pms:r:fs#/#::#} )
 
-        _perl_modules=( $new_pms $_perl_modules )
+      _perl_modules=( $new_pms $_perl_modules )
     done
   fi
 fi
Index: Completion/User/_perldoc
===================================================================
RCS file: /usr/local/cvsroot/zsh/Completion/User/_perldoc,v
retrieving revision 1.1.1.2
diff -u -r1.1.1.2 _perldoc
--- Completion/User/_perldoc	1999/09/21 12:17:48	1.1.1.2
+++ Completion/User/_perldoc	1999/09/29 00:18:59
@@ -6,21 +6,24 @@
 #
 
 _perldoc () {
-    _arguments -s \
-        '-h:help:' \
-        '(-q)-f:Perl built-in function:_perl_builtin_funcs:*:' \
-        '(-f)-q:Perl FAQ keyword:' \
-        '*:Perl pod pages:_perl_pods'
+  _arguments -s \
+    '-h:help:' \
+    '(-q)-f:Perl built-in function:_perl_builtin_funcs:*:' \
+    '(-f)-q:Perl FAQ keyword:' \
+    '*:Perl pod pages:_perl_pods'
 }
 
 _perl_pods () {
-    local nm="$compstate[nmatches]"
+  local nm="$compstate[nmatches]"
+  local expl
+  
+  _perl_modules
+  _perl_basepods
 
-   _perl_modules
-   _perl_basepods
-   _path_files -J 'Perl modules and .pods' -/ -g '*.(pod|pm)'
+  _description expl 'Perl modules and .pods'
+  _path_files "$expl[@]"  -/ -g '*.(pod|pm)'
 
-    [[ nm -ne "$compstate[nmatches]" ]]
+  [[ nm -ne "$compstate[nmatches]" ]]
 }
 
 _perldoc "$@"


                 reply	other threads:[~1999-09-29 18:54 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=19990929195444.A15831@thelonious.new.ox.ac.uk \
    --to=adam@thelonious.new.ox.ac.uk \
    --cc=adam@spiers.net \
    --cc=zsh-workers@sunsite.auc.dk \
    /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).