Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!uunet!convex!newsadm From: tchrist@convex.COM (Tom Christiansen) Newsgroups: comp.lang.perl Subject: Re: ptags - perl tags in perl Message-ID: <1991Apr11.212214.27164@convex.com> Date: 11 Apr 91 21:22:14 GMT References: <543@appserv.Eng.Sun.COM> <128366@uunet.UU.NET> Sender: newsadm@convex.com (news access account) Reply-To: tchrist@convex.COM (Tom Christiansen) Organization: CONVEX Software Development, Richardson, TX Lines: 23 Nntp-Posting-Host: pixel.convex.com From the keyboard of rbj@uunet.UU.NET (Root Boy Jim): :In article <543@appserv.Eng.Sun.COM> lm@sun.UUCP (Larry McVoy) writes: :>In the hack-of-the-hour catagory, a tags file generator for perl. : :Why don't you hack this into etags/ctags in the emacs distribution? Who cares about emacs? :-) I've always used this. Don't recall whom I got it from... --tom #!/usr/local/bin/perl open(OUTPUT, "| sort > tags"); while (<>) { if (/\bsub\s+(\w+')?(\S+)/) { $func = $2; chop; s,[\\\[\]/.*],\\$&,g; print OUTPUT "$func\t", $ARGV, "\t/^$_\$/\n"; } }