home *** CD-ROM | disk | FTP | other *** search
open in:
MacOS 8.1
|
Win98
|
DOS
browse contents |
view JSON data
|
view as text
This file was processed as: SHell self-extracting ARchive
(archive/shar).
Confidence | Program | Detection | Match Type | Support
|
---|
100%
| dexvert
| SHell self-extracting ARchive (archive/shar)
| magic
| Supported |
100%
| dexvert
| Newsgroup Content (archive/news)
| magic
| Supported |
100%
| dexvert
| Internet Message Format (text/imf)
| magic
| Supported |
1%
| dexvert
| Text File (text/txt)
| fallback
| Supported |
100%
| file
| news, ASCII text
| default
| |
100%
| checkBytes
| Printable ASCII
| default
| |
100%
| dexmagic
| PrintFox/Pagefox WEAK
| default
| |
100%
| perlTextCheck
| Likely Text (Perl)
| default
| |
100%
| siegfried
| fmt/329 Shell Archive Format
| default
| |
100%
| detectItEasy
| Format: Plain text[LF]
| default
| |
100%
| xdgMime
| message/news
| default
|
|
hex view+--------+-------------------------+-------------------------+--------+--------+
|00000000| 50 61 74 68 3a 20 74 75 | 74 2e 63 69 73 2e 6f 68 |Path: tu|t.cis.oh|
|00000010| 69 6f 2d 73 74 61 74 65 | 2e 65 64 75 21 73 75 6e |io-state|.edu!sun|
|00000020| 63 2e 6f 73 63 2e 65 64 | 75 21 6d 61 6c 67 75 64 |c.osc.ed|u!malgud|
|00000030| 69 21 63 61 65 6e 21 73 | 64 64 2e 68 70 2e 63 6f |i!caen!s|dd.hp.co|
|00000040| 6d 21 75 73 63 21 75 63 | 6c 61 2d 63 73 21 6e 6f |m!usc!uc|la-cs!no|
|00000050| 74 74 69 6e 67 68 61 6d | 21 6a 6f 68 6e 68 0a 46 |ttingham|!johnh.F|
|00000060| 72 6f 6d 3a 20 6a 6f 68 | 6e 68 40 6e 6f 74 74 69 |rom: joh|nh@notti|
|00000070| 6e 67 68 61 6d 2e 63 73 | 2e 75 63 6c 61 2e 65 64 |ngham.cs|.ucla.ed|
|00000080| 75 20 28 4a 6f 68 6e 20 | 48 65 69 64 65 6d 61 6e |u (John |Heideman|
|00000090| 6e 29 0a 4e 65 77 73 67 | 72 6f 75 70 73 3a 20 63 |n).Newsg|roups: c|
|000000a0| 6f 6d 70 2e 6c 61 6e 67 | 2e 70 65 72 6c 2c 63 6f |omp.lang|.perl,co|
|000000b0| 6d 70 2e 74 65 78 74 2e | 74 65 78 0a 53 75 62 6a |mp.text.|tex.Subj|
|000000c0| 65 63 74 3a 20 6c 6f 6f | 6b 62 69 62 74 65 78 2c |ect: loo|kbibtex,|
|000000d0| 20 76 65 72 73 69 6f 6e | 20 31 2e 31 0a 4d 65 73 | version| 1.1.Mes|
|000000e0| 73 61 67 65 2d 49 44 3a | 20 3c 31 39 39 30 4e 6f |sage-ID:| <1990No|
|000000f0| 76 32 39 2e 30 31 35 33 | 33 36 2e 37 39 30 35 40 |v29.0153|36.7905@|
|00000100| 63 73 2e 75 63 6c 61 2e | 65 64 75 3e 0a 44 61 74 |cs.ucla.|edu>.Dat|
|00000110| 65 3a 20 32 39 20 4e 6f | 76 20 39 30 20 30 31 3a |e: 29 No|v 90 01:|
|00000120| 35 33 3a 33 36 20 47 4d | 54 0a 53 65 6e 64 65 72 |53:36 GM|T.Sender|
|00000130| 3a 20 6e 65 77 73 40 63 | 73 2e 75 63 6c 61 2e 65 |: news@c|s.ucla.e|
|00000140| 64 75 20 28 4d 72 2e 20 | 4e 65 77 73 29 0a 4f 72 |du (Mr. |News).Or|
|00000150| 67 61 6e 69 7a 61 74 69 | 6f 6e 3a 20 55 43 4c 41 |ganizati|on: UCLA|
|00000160| 2c 20 43 6f 6d 70 75 74 | 65 72 20 53 63 69 65 6e |, Comput|er Scien|
|00000170| 63 65 20 44 65 70 61 72 | 74 6d 65 6e 74 0a 4c 69 |ce Depar|tment.Li|
|00000180| 6e 65 73 3a 20 33 32 33 | 0a 58 72 65 66 3a 20 74 |nes: 323|.Xref: t|
|00000190| 75 74 2e 63 69 73 2e 6f | 68 69 6f 2d 73 74 61 74 |ut.cis.o|hio-stat|
|000001a0| 65 2e 65 64 75 20 63 6f | 6d 70 2e 6c 61 6e 67 2e |e.edu co|mp.lang.|
|000001b0| 70 65 72 6c 3a 33 31 36 | 36 20 63 6f 6d 70 2e 74 |perl:316|6 comp.t|
|000001c0| 65 78 74 2e 74 65 78 3a | 34 31 34 38 0a 4e 6e 74 |ext.tex:|4148.Nnt|
|000001d0| 70 2d 50 6f 73 74 69 6e | 67 2d 48 6f 73 74 3a 20 |p-Postin|g-Host: |
|000001e0| 6e 6f 74 74 69 6e 67 68 | 61 6d 2e 63 73 2e 75 63 |nottingh|am.cs.uc|
|000001f0| 6c 61 2e 65 64 75 0a 0a | 0a 46 6f 6c 6c 6f 77 69 |la.edu..|.Followi|
|00000200| 6e 67 20 69 73 20 76 65 | 72 73 69 6f 6e 20 31 2e |ng is ve|rsion 1.|
|00000210| 31 20 6f 66 20 6c 6f 6f | 6b 62 69 62 74 65 78 2c |1 of loo|kbibtex,|
|00000220| 0a 61 20 50 65 72 6c 20 | 73 63 72 69 70 74 20 77 |.a Perl |script w|
|00000230| 68 69 63 68 20 61 6c 6c | 6f 77 73 20 6b 65 79 77 |hich all|ows keyw|
|00000240| 6f 72 64 20 73 65 61 72 | 63 68 65 73 0a 6f 66 20 |ord sear|ches.of |
|00000250| 62 69 62 74 65 78 20 64 | 61 74 61 62 61 73 65 73 |bibtex d|atabases|
|00000260| 2c 20 73 68 6f 77 69 6e | 67 20 74 68 65 20 65 6e |, showin|g the en|
|00000270| 74 69 72 65 20 64 61 74 | 61 62 61 73 65 20 65 6e |tire dat|abase en|
|00000280| 74 72 79 0a 77 68 65 6e | 20 61 20 6d 61 74 63 68 |try.when| a match|
|00000290| 20 69 73 20 66 6f 75 6e | 64 2e 0a 0a 54 68 69 73 | is foun|d...This|
|000002a0| 20 76 65 72 73 69 6f 6e | 20 63 6f 72 72 65 63 74 | version| correct|
|000002b0| 73 20 61 20 66 65 77 20 | 62 75 67 73 20 69 6e 20 |s a few |bugs in |
|000002c0| 74 68 65 20 6f 72 69 67 | 69 6e 61 6c 0a 76 65 72 |the orig|inal.ver|
|000002d0| 73 69 6f 6e 2e 20 20 4d | 75 6c 74 69 2d 6c 69 6e |sion. M|ulti-lin|
|000002e0| 65 20 66 69 65 6c 64 73 | 20 77 69 74 68 20 63 75 |e fields| with cu|
|000002f0| 72 6c 65 79 20 62 72 61 | 63 65 73 0a 61 72 65 20 |rley bra|ces.are |
|00000300| 6e 6f 77 20 73 75 70 70 | 6f 72 74 65 64 2c 20 61 |now supp|orted, a|
|00000310| 6e 64 20 75 6d 6c 61 75 | 74 73 20 61 72 65 20 63 |nd umlau|ts are c|
|00000320| 6f 72 72 65 63 74 6c 79 | 20 68 61 6e 64 6c 65 64 |orrectly| handled|
|00000330| 2e 0a 0a 20 20 20 2d 20 | 4a 6f 68 6e 20 48 65 69 |... - |John Hei|
|00000340| 64 65 6d 61 6e 6e 0a 0a | 0a 2d 2d 2d 2d 2d 2d 2d |demann..|.-------|
|00000350| 2d 2d 2d 2d 2d 2d 2d 2d | 2b 2d 2d 2d 2d 2d 2d 2d |--------|+-------|
|00000360| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00000370| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00000380| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00000390| 2d 2d 2d 2d 2d 2d 2d 0a | 4a 6f 68 6e 20 48 65 69 |-------.|John Hei|
|000003a0| 64 65 6d 61 6e 6e 20 7c | 20 46 6f 72 74 75 6e 65 |demann || Fortune|
|000003b0| 20 6f 66 20 74 68 65 20 | 77 65 65 6b 3a 20 20 41 | of the |week: A|
|000003c0| 6e 79 20 73 75 66 66 69 | 63 69 65 6e 74 6c 79 20 |ny suffi|ciently |
|000003d0| 61 64 76 61 6e 63 65 64 | 20 74 65 63 68 6e 6f 6c |advanced| technol|
|000003e0| 6f 67 79 0a 55 43 4c 41 | 20 43 53 44 20 20 20 20 |ogy.UCLA| CSD |
|000003f0| 20 20 20 7c 20 20 20 20 | 69 73 20 69 6e 64 69 73 | | |is indis|
|00000400| 74 69 6e 67 75 69 73 68 | 61 62 6c 65 20 66 72 6f |tinguish|able fro|
|00000410| 6d 20 61 20 72 69 67 67 | 65 64 20 64 65 6d 6f 2e |m a rigg|ed demo.|
|00000420| 0a 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |.-------|--------|
|00000430| 2b 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |+-------|--------|
|00000440| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00000450| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00000460| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 0a |--------|-------.|
|00000470| 0a 23 21 20 2f 62 69 6e | 2f 73 68 0a 23 20 54 68 |.#! /bin|/sh.# Th|
|00000480| 69 73 20 69 73 20 61 20 | 73 68 65 6c 6c 20 61 72 |is is a |shell ar|
|00000490| 63 68 69 76 65 2c 20 6d | 65 61 6e 69 6e 67 3a 0a |chive, m|eaning:.|
|000004a0| 23 20 31 2e 20 52 65 6d | 6f 76 65 20 65 76 65 72 |# 1. Rem|ove ever|
|000004b0| 79 74 68 69 6e 67 20 61 | 62 6f 76 65 20 74 68 65 |ything a|bove the|
|000004c0| 20 23 21 20 2f 62 69 6e | 2f 73 68 20 6c 69 6e 65 | #! /bin|/sh line|
|000004d0| 2e 0a 23 20 32 2e 20 53 | 61 76 65 20 74 68 65 20 |..# 2. S|ave the |
|000004e0| 72 65 73 75 6c 74 69 6e | 67 20 74 65 78 74 20 69 |resultin|g text i|
|000004f0| 6e 20 61 20 66 69 6c 65 | 2e 0a 23 20 33 2e 20 45 |n a file|..# 3. E|
|00000500| 78 65 63 75 74 65 20 74 | 68 65 20 66 69 6c 65 20 |xecute t|he file |
|00000510| 77 69 74 68 20 2f 62 69 | 6e 2f 73 68 20 28 6e 6f |with /bi|n/sh (no|
|00000520| 74 20 63 73 68 29 20 74 | 6f 20 63 72 65 61 74 65 |t csh) t|o create|
|00000530| 20 74 68 65 20 66 69 6c | 65 73 3a 0a 23 09 52 45 | the fil|es:.#.RE|
|00000540| 41 44 4d 45 0a 23 09 6c | 6f 6f 6b 62 69 62 74 65 |ADME.#.l|ookbibte|
|00000550| 78 2e 31 0a 23 09 6c 6f | 6f 6b 62 69 62 74 65 78 |x.1.#.lo|okbibtex|
|00000560| 0a 23 20 54 68 69 73 20 | 61 72 63 68 69 76 65 20 |.# This |archive |
|00000570| 63 72 65 61 74 65 64 3a | 20 57 65 64 20 4e 6f 76 |created:| Wed Nov|
|00000580| 20 32 38 20 31 37 3a 34 | 34 3a 30 34 20 31 39 39 | 28 17:4|4:04 199|
|00000590| 30 0a 65 78 70 6f 72 74 | 20 50 41 54 48 3b 20 50 |0.export| PATH; P|
|000005a0| 41 54 48 3d 2f 62 69 6e | 3a 24 50 41 54 48 0a 69 |ATH=/bin|:$PATH.i|
|000005b0| 66 20 74 65 73 74 20 2d | 66 20 27 52 45 41 44 4d |f test -|f 'READM|
|000005c0| 45 27 0a 74 68 65 6e 0a | 09 65 63 68 6f 20 73 68 |E'.then.|.echo sh|
|000005d0| 61 72 3a 20 77 69 6c 6c | 20 6e 6f 74 20 6f 76 65 |ar: will| not ove|
|000005e0| 72 2d 77 72 69 74 65 20 | 65 78 69 73 74 69 6e 67 |r-write |existing|
|000005f0| 20 66 69 6c 65 20 22 27 | 52 45 41 44 4d 45 27 22 | file "'|README'"|
|00000600| 0a 65 6c 73 65 0a 63 61 | 74 20 3c 3c 20 5c 53 48 |.else.ca|t << \SH|
|00000610| 41 52 5f 45 4f 46 20 3e | 20 27 52 45 41 44 4d 45 |AR_EOF >| 'README|
|00000620| 27 0a 6c 6f 6f 6b 62 69 | 62 74 65 78 20 31 2e 31 |'.lookbi|btex 1.1|
|00000630| 0a 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 0a |.-------|-------.|
|00000640| 0a 54 6f 20 69 6e 73 74 | 61 6c 6c 20 6c 6f 6f 6b |.To inst|all look|
|00000650| 62 69 62 74 65 78 2c 20 | 63 68 61 6e 67 65 20 74 |bibtex, |change t|
|00000660| 68 65 20 23 21 20 6c 69 | 6e 65 20 6f 66 20 6c 6f |he #! li|ne of lo|
|00000670| 6f 6b 62 69 62 74 65 78 | 20 74 6f 20 0a 74 68 65 |okbibtex| to .the|
|00000680| 20 70 61 74 68 20 66 6f | 72 20 50 65 72 6c 2e 20 | path fo|r Perl. |
|00000690| 20 59 6f 75 20 6d 61 79 | 20 61 6c 73 6f 20 77 69 | You may| also wi|
|000006a0| 73 68 20 74 6f 20 63 68 | 61 6e 67 65 0a 74 68 65 |sh to ch|ange.the|
|000006b0| 20 64 65 66 61 75 6c 74 | 20 64 61 74 61 62 61 73 | default| databas|
|000006c0| 65 3b 20 69 66 20 73 6f | 20 65 64 69 74 20 74 68 |e; if so| edit th|
|000006d0| 65 20 24 64 65 66 61 75 | 6c 74 66 69 6c 65 20 76 |e $defau|ltfile v|
|000006e0| 61 72 69 61 62 6c 65 2e | 0a 0a 4c 6f 6f 6b 62 69 |ariable.|..Lookbi|
|000006f0| 62 74 65 78 20 69 73 20 | 72 65 6c 65 61 73 65 64 |btex is |released|
|00000700| 20 75 6e 64 65 72 20 74 | 68 65 20 47 4e 55 20 50 | under t|he GNU P|
|00000710| 75 62 6c 69 63 20 4c 69 | 63 65 6e 73 65 2c 20 56 |ublic Li|cense, V|
|00000720| 65 72 73 69 6f 6e 20 31 | 20 28 46 65 62 20 38 39 |ersion 1| (Feb 89|
|00000730| 29 2e 0a 41 20 63 6f 70 | 79 20 6f 66 20 74 68 65 |)..A cop|y of the|
|00000740| 20 47 50 4c 20 73 68 6f | 75 6c 64 20 62 65 20 69 | GPL sho|uld be i|
|00000750| 6e 63 6c 75 64 65 64 20 | 77 69 74 68 20 79 6f 75 |ncluded |with you|
|00000760| 72 20 50 65 72 6c 20 64 | 69 73 74 72 69 62 75 74 |r Perl d|istribut|
|00000770| 69 6f 6e 2e 0a 0a 54 68 | 69 73 20 69 73 20 76 65 |ion...Th|is is ve|
|00000780| 72 73 69 6f 6e 20 31 2e | 31 2c 20 69 74 20 66 69 |rsion 1.|1, it fi|
|00000790| 78 65 73 20 74 68 72 65 | 65 20 70 72 6f 62 6c 65 |xes thre|e proble|
|000007a0| 6d 73 20 6f 66 20 72 65 | 6c 65 61 73 65 20 31 2e |ms of re|lease 1.|
|000007b0| 30 2e 20 20 45 6e 64 0a | 72 69 67 68 74 20 63 75 |0. End.|right cu|
|000007c0| 72 6c 65 79 20 62 72 61 | 63 6b 65 74 73 20 6e 6f |rley bra|ckets no|
|000007d0| 74 20 69 6e 20 74 68 65 | 20 66 69 72 73 74 20 63 |t in the| first c|
|000007e0| 6f 6c 75 6d 6e 20 77 65 | 72 65 20 6d 69 73 73 65 |olumn we|re misse|
|000007f0| 64 20 69 6e 20 31 2e 30 | 2e 0a 55 6d 6c 61 75 74 |d in 1.0|..Umlaut|
|00000800| 73 20 61 6e 64 20 6d 75 | 6c 74 69 2d 6c 69 6e 65 |s and mu|lti-line|
|00000810| 20 66 69 65 6c 64 73 20 | 77 69 74 68 20 63 75 72 | fields |with cur|
|00000820| 6c 65 79 20 62 72 61 63 | 6b 65 74 73 20 61 72 65 |ley brac|kets are|
|00000830| 20 6e 6f 77 20 68 61 6e | 64 6c 65 64 0a 63 6f 72 | now han|dled.cor|
|00000840| 72 65 63 74 6c 79 2e 0a | 0a 50 65 72 6c 20 69 73 |rectly..|.Perl is|
|00000850| 20 76 65 72 79 20 70 72 | 61 74 69 63 61 6c 20 6c | very pr|atical l|
|00000860| 61 6e 67 75 61 67 65 20 | 66 72 6f 6d 20 4c 61 72 |anguage |from Lar|
|00000870| 72 79 20 57 61 6c 6c 2e | 20 20 49 74 20 6d 61 79 |ry Wall.| It may|
|00000880| 20 62 65 20 6f 62 74 61 | 69 6e 65 64 20 62 79 0a | be obta|ined by.|
|00000890| 61 6e 6f 6e 79 6d 6f 75 | 73 20 66 74 70 20 66 72 |anonymou|s ftp fr|
|000008a0| 6f 6d 20 6a 70 6c 2d 64 | 65 76 76 61 78 2e 6a 70 |om jpl-d|evvax.jp|
|000008b0| 6c 2e 6e 61 73 61 2e 67 | 6f 76 20 69 6e 20 70 75 |l.nasa.g|ov in pu|
|000008c0| 62 2f 70 65 72 6c 2e 33 | 2e 30 2c 20 6f 72 20 62 |b/perl.3|.0, or b|
|000008d0| 79 0a 65 2d 6d 61 69 6c | 20 74 6f 20 4c 61 72 72 |y.e-mail| to Larr|
|000008e0| 79 20 57 61 6c 6c 20 3c | 6c 77 61 6c 6c 40 6a 70 |y Wall <|lwall@jp|
|000008f0| 6c 2d 64 65 76 76 61 78 | 2e 6a 70 6c 2e 6e 61 73 |l-devvax|.jpl.nas|
|00000900| 61 2e 67 6f 76 3e 2e 0a | 0a 41 6e 79 20 63 6f 6d |a.gov>..|.Any com|
|00000910| 6d 65 6e 74 73 20 61 72 | 65 20 77 65 6c 63 6f 6d |ments ar|e welcom|
|00000920| 65 2e 0a 0a 20 20 20 2d | 4a 6f 68 6e 20 48 65 69 |e... -|John Hei|
|00000930| 64 65 6d 61 6e 6e 0a 20 | 20 20 20 3c 6a 6f 68 6e |demann. | <john|
|00000940| 68 40 63 73 2e 75 63 6c | 61 2e 65 64 75 3e 0a 20 |h@cs.ucl|a.edu>. |
|00000950| 20 20 20 32 38 20 4e 6f | 76 65 6d 62 65 72 20 31 | 28 No|vember 1|
|00000960| 39 39 30 0a 0a 0a 0a 0a | 20 0a 53 48 41 52 5f 45 |990.....| .SHAR_E|
|00000970| 4f 46 0a 66 69 20 23 20 | 65 6e 64 20 6f 66 20 6f |OF.fi # |end of o|
|00000980| 76 65 72 77 72 69 74 69 | 6e 67 20 63 68 65 63 6b |verwriti|ng check|
|00000990| 0a 69 66 20 74 65 73 74 | 20 2d 66 20 27 6c 6f 6f |.if test| -f 'loo|
|000009a0| 6b 62 69 62 74 65 78 2e | 31 27 0a 74 68 65 6e 0a |kbibtex.|1'.then.|
|000009b0| 09 65 63 68 6f 20 73 68 | 61 72 3a 20 77 69 6c 6c |.echo sh|ar: will|
|000009c0| 20 6e 6f 74 20 6f 76 65 | 72 2d 77 72 69 74 65 20 | not ove|r-write |
|000009d0| 65 78 69 73 74 69 6e 67 | 20 66 69 6c 65 20 22 27 |existing| file "'|
|000009e0| 6c 6f 6f 6b 62 69 62 74 | 65 78 2e 31 27 22 0a 65 |lookbibt|ex.1'".e|
|000009f0| 6c 73 65 0a 63 61 74 20 | 3c 3c 20 5c 53 48 41 52 |lse.cat |<< \SHAR|
|00000a00| 5f 45 4f 46 20 3e 20 27 | 6c 6f 6f 6b 62 69 62 74 |_EOF > '|lookbibt|
|00000a10| 65 78 2e 31 27 0a 2e 5c | 22 20 6c 6f 6f 6b 62 69 |ex.1'..\|" lookbi|
|00000a20| 62 74 65 78 2e 31 0a 2e | 54 48 20 4c 4f 4f 4b 42 |btex.1..|TH LOOKB|
|00000a30| 49 42 54 45 58 20 31 20 | 22 31 39 20 4e 6f 76 65 |IBTEX 1 |"19 Nove|
|00000a40| 6d 62 65 72 20 31 39 39 | 30 22 0a 0a 2e 53 48 20 |mber 199|0"...SH |
|00000a50| 4e 41 4d 45 0a 6c 6f 6f | 6b 62 69 62 74 65 78 20 |NAME.loo|kbibtex |
|00000a60| 5c 2d 20 66 69 6e 64 20 | 72 65 66 65 72 65 6e 63 |\- find |referenc|
|00000a70| 65 73 20 69 6e 20 61 20 | 62 69 62 74 65 78 20 64 |es in a |bibtex d|
|00000a80| 61 74 61 62 61 73 65 0a | 0a 2e 53 48 20 53 59 4e |atabase.|..SH SYN|
|00000a90| 4f 50 53 49 53 0a 2e 42 | 20 6c 6f 6f 6b 62 69 62 |OPSIS..B| lookbib|
|00000aa0| 74 65 78 0a 5b 20 2d 6b | 0a 2e 49 20 6b 65 79 77 |tex.[ -k|..I keyw|
|00000ab0| 6f 72 64 0a 5d 0a 5b 0a | 2e 49 20 62 69 62 66 69 |ord.].[.|.I bibfi|
|00000ac0| 6c 65 2e 62 69 62 0a 5d | 0a 2e 49 20 72 65 67 65 |le.bib.]|..I rege|
|00000ad0| 78 70 0a 0a 2e 53 48 20 | 44 45 53 43 52 49 50 54 |xp...SH |DESCRIPT|
|00000ae0| 49 4f 4e 0a 6c 6f 6f 6b | 62 69 62 74 65 78 20 73 |ION.look|bibtex s|
|00000af0| 65 61 72 63 68 65 73 20 | 74 68 72 6f 75 67 68 20 |earches |through |
|00000b00| 61 20 62 69 62 74 65 78 | 20 0a 2e 49 20 62 69 62 |a bibtex| ..I bib|
|00000b10| 66 69 6c 65 2e 62 69 62 | 0a 64 61 74 61 62 61 73 |file.bib|.databas|
|00000b20| 65 2c 20 70 72 69 6e 74 | 69 6e 67 20 65 6e 74 72 |e, print|ing entr|
|00000b30| 69 65 73 20 74 68 61 74 | 20 6d 61 74 63 68 0a 2e |ies that| match..|
|00000b40| 49 20 72 65 67 65 78 70 | 2e 0a 53 65 65 20 0a 2e |I regexp|..See ..|
|00000b50| 42 52 20 62 69 62 74 65 | 78 20 28 31 29 0a 66 6f |BR bibte|x (1).fo|
|00000b60| 72 20 61 20 64 65 73 63 | 72 69 70 74 69 6f 6e 20 |r a desc|ription |
|00000b70| 6f 66 20 74 68 65 20 62 | 69 62 74 65 78 20 64 61 |of the b|ibtex da|
|00000b80| 74 61 62 61 73 65 2e 0a | 2e 49 20 52 65 67 65 78 |tabase..|.I Regex|
|00000b90| 70 0a 69 73 20 61 20 50 | 65 72 6c 20 72 65 67 75 |p.is a P|erl regu|
|00000ba0| 6c 61 72 20 65 78 70 72 | 65 73 73 69 6f 6e 2e 0a |lar expr|ession..|
|00000bb0| 53 65 65 0a 2e 42 52 20 | 70 65 72 6c 20 28 31 29 |See..BR |perl (1)|
|00000bc0| 0a 66 6f 72 20 61 6e 20 | 65 78 70 6c 61 6e 61 74 |.for an |explanat|
|00000bd0| 69 6f 6e 20 6f 66 20 64 | 69 66 66 65 72 65 6e 63 |ion of d|ifferenc|
|00000be0| 65 73 20 62 65 74 77 65 | 65 6e 20 70 65 72 6c 20 |es betwe|en perl |
|00000bf0| 61 6e 64 20 73 74 61 6e | 64 61 72 64 20 72 65 67 |and stan|dard reg|
|00000c00| 75 6c 61 72 0a 65 78 70 | 72 65 73 73 69 6f 6e 73 |ular.exp|ressions|
|00000c10| 2e 0a 0a 53 65 61 72 63 | 68 65 73 20 63 61 6e 20 |...Searc|hes can |
|00000c20| 62 65 20 6c 69 6d 69 74 | 65 64 20 74 6f 20 70 61 |be limit|ed to pa|
|00000c30| 72 74 69 63 75 6c 61 72 | 20 62 69 62 74 65 78 20 |rticular| bibtex |
|00000c40| 66 69 65 6c 64 73 0a 77 | 69 74 68 20 74 68 65 20 |fields.w|ith the |
|00000c50| 2d 6b 20 6f 70 74 69 6f | 6e 2e 0a 0a 54 6f 20 64 |-k optio|n...To d|
|00000c60| 6f 20 22 61 6e 64 22 20 | 73 65 61 72 63 68 65 73 |o "and" |searches|
|00000c70| 20 6f 6e 20 74 77 6f 20 | 66 69 65 6c 64 73 20 75 | on two |fields u|
|00000c80| 73 65 20 73 68 65 6c 6c | 20 70 69 70 65 73 2c 20 |se shell| pipes, |
|00000c90| 72 65 61 64 69 6e 67 0a | 74 68 65 20 6f 75 74 70 |reading.|the outp|
|00000ca0| 75 74 20 6f 66 20 6f 6e | 65 20 73 65 61 72 63 68 |ut of on|e search|
|00000cb0| 20 61 73 20 74 68 65 20 | 62 69 62 6c 69 6f 67 72 | as the |bibliogr|
|00000cc0| 61 70 68 79 20 6f 66 20 | 74 68 65 20 73 65 63 6f |aphy of |the seco|
|00000cd0| 6e 64 2e 0a 46 6f 72 20 | 65 78 61 6d 70 6c 65 2c |nd..For |example,|
|00000ce0| 20 74 6f 20 66 69 6e 64 | 20 77 68 61 74 20 73 6f | to find| what so|
|00000cf0| 6d 65 6f 6e 65 20 6e 61 | 6d 65 64 20 4b 61 66 6b |meone na|med Kafk|
|00000d00| 61 20 77 72 6f 74 65 0a | 61 62 6f 75 74 20 65 6d |a wrote.|about em|
|00000d10| 61 63 73 20 6b 65 79 62 | 6f 61 72 64 20 6c 61 79 |acs keyb|oard lay|
|00000d20| 6f 75 74 2c 20 64 6f 3a | 0a 2e 49 50 0a 2e 42 0a |out, do:|..IP..B.|
|00000d30| 6c 6f 6f 6b 62 69 62 74 | 65 78 20 2d 6b 20 61 75 |lookbibt|ex -k au|
|00000d40| 74 68 6f 72 20 6b 61 66 | 6b 61 20 7c 20 6c 6f 6f |thor kaf|ka | loo|
|00000d50| 6b 74 65 78 62 69 62 20 | 2d 6b 20 74 69 74 6c 65 |ktexbib |-k title|
|00000d60| 20 2d 20 6d 65 74 61 0a | 2e 4c 50 0a 0a 54 6f 20 | - meta.|.LP..To |
|00000d70| 64 6f 20 22 6f 72 22 20 | 73 65 61 72 63 68 65 73 |do "or" |searches|
|00000d80| 2c 20 75 73 65 20 72 65 | 67 75 6c 61 72 20 65 78 |, use re|gular ex|
|00000d90| 70 72 65 73 73 69 6f 6e | 73 2e 0a 46 6f 72 20 65 |pression|s..For e|
|00000da0| 78 61 6d 70 6c 65 2c 20 | 79 6f 75 20 63 6f 75 6c |xample, |you coul|
|00000db0| 64 20 62 65 20 63 6f 6e | 63 65 72 6e 65 64 20 77 |d be con|cerned w|
|00000dc0| 69 74 68 20 0a 6f 6e 6c | 79 20 63 61 72 65 66 75 |ith .onl|y carefu|
|00000dd0| 6c 20 61 75 74 68 6f 72 | 73 2c 20 6c 69 6b 65 20 |l author|s, like |
|00000de0| 4b 75 6e 74 68 20 61 6e | 64 20 4b 61 66 6b 61 3a |Kunth an|d Kafka:|
|00000df0| 0a 2e 49 50 0a 2e 42 0a | 6c 6f 6f 6b 62 69 62 74 |..IP..B.|lookbibt|
|00000e00| 65 78 20 2d 6b 20 61 75 | 74 68 6f 72 20 27 6b 75 |ex -k au|thor 'ku|
|00000e10| 6e 74 68 7c 6b 61 66 6b | 61 27 0a 2e 4c 50 0a 0a |nth|kafk|a'..LP..|
|00000e20| 4d 6f 72 65 20 73 6f 70 | 68 69 73 74 69 63 61 74 |More sop|histicat|
|00000e30| 65 64 20 73 65 61 72 63 | 68 65 73 20 63 61 6e 20 |ed searc|hes can |
|00000e40| 62 65 20 61 63 68 69 65 | 76 65 64 20 62 79 20 63 |be achie|ved by c|
|00000e50| 6f 6d 62 69 6e 69 6e 67 | 0a 74 68 65 73 65 20 74 |ombining|.these t|
|00000e60| 65 63 68 6e 69 71 75 65 | 73 2e 0a 0a 2e 53 48 20 |echnique|s....SH |
|00000e70| 41 55 54 48 4f 52 0a 4a | 6f 68 6e 20 48 65 69 64 |AUTHOR.J|ohn Heid|
|00000e80| 65 6d 61 6e 6e 20 3c 6a | 6f 68 6e 68 40 63 73 2e |emann <j|ohnh@cs.|
|00000e90| 75 63 6c 61 2e 65 64 75 | 3e 0a 0a 2e 53 48 20 53 |ucla.edu|>...SH S|
|00000ea0| 45 45 20 41 4c 53 4f 0a | 2e 42 52 20 62 69 62 74 |EE ALSO.|.BR bibt|
|00000eb0| 65 78 20 28 31 29 2c 0a | 2e 42 52 20 70 65 72 6c |ex (1),.|.BR perl|
|00000ec0| 20 28 31 29 0a 0a 2e 53 | 48 20 42 55 47 53 0a 6c | (1)...S|H BUGS.l|
|00000ed0| 6f 6f 6b 62 69 62 74 65 | 78 20 69 73 20 77 72 69 |ookbibte|x is wri|
|00000ee0| 74 74 65 6e 20 69 6e 20 | 50 65 72 6c 2c 20 73 6f |tten in |Perl, so|
|00000ef0| 20 69 74 20 77 69 6c 6c | 20 6e 6f 74 20 72 75 6e | it will| not run|
|00000f00| 20 6f 6e 20 6d 61 63 68 | 69 6e 65 73 0a 77 68 69 | on mach|ines.whi|
|00000f10| 63 68 20 64 6f 20 6e 6f | 74 20 68 61 76 65 20 70 |ch do no|t have p|
|00000f20| 65 72 6c 20 69 6e 73 74 | 61 6c 6c 65 64 20 28 61 |erl inst|alled (a|
|00000f30| 6c 74 68 6f 75 67 68 20 | 74 68 69 73 20 61 72 67 |lthough |this arg|
|00000f40| 75 61 62 6c 79 0a 61 20 | 62 75 67 20 6f 66 20 74 |uably.a |bug of t|
|00000f50| 68 65 20 70 65 72 73 6f | 6e 20 74 6f 6f 20 6c 61 |he perso|n too la|
|00000f60| 7a 79 20 74 6f 20 69 6e | 73 74 61 6c 6c 20 73 75 |zy to in|stall su|
|00000f70| 63 68 20 61 20 75 73 65 | 66 75 6c 20 74 6f 6f 6c |ch a use|ful tool|
|00000f80| 29 2e 0a 0a 4d 75 6c 74 | 69 70 6c 65 20 6b 65 79 |)...Mult|iple key|
|00000f90| 77 6f 72 64 73 20 6f 6e | 20 6f 6e 65 20 6c 69 6e |words on| one lin|
|00000fa0| 65 20 77 69 6c 6c 20 62 | 65 20 6d 69 73 73 65 64 |e will b|e missed|
|00000fb0| 2e 0a 0a 54 68 69 73 20 | 70 72 6f 67 72 61 6d 20 |...This |program |
|00000fc0| 64 6f 65 73 20 6e 6f 74 | 20 69 6d 70 6c 65 6d 65 |does not| impleme|
|00000fd0| 6e 74 20 61 20 66 75 6c | 6c 20 62 69 62 74 65 78 |nt a ful|l bibtex|
|00000fe0| 20 70 61 72 73 65 72 2c | 0a 6a 75 73 74 20 61 20 | parser,|.just a |
|00000ff0| 67 6f 6f 64 20 61 70 70 | 72 6f 78 69 6d 61 74 69 |good app|roximati|
|00001000| 6f 6e 2e 20 20 42 65 63 | 61 75 73 65 20 6f 66 20 |on. Bec|ause of |
|00001010| 74 68 69 73 2c 20 69 74 | 20 6d 61 79 0a 66 61 69 |this, it| may.fai|
|00001020| 6c 20 6f 6e 20 75 6e 75 | 73 75 61 6c 20 62 69 62 |l on unu|sual bib|
|00001030| 74 65 78 20 66 69 6c 65 | 73 2e 20 20 49 6e 20 70 |tex file|s. In p|
|00001040| 61 72 74 69 63 75 6c 61 | 72 2c 0a 74 68 65 20 40 |articula|r,.the @|
|00001050| 20 74 68 61 74 20 62 65 | 67 69 6e 73 20 61 20 62 | that be|gins a b|
|00001060| 69 62 74 65 78 20 65 6e | 74 72 79 2c 20 61 6e 64 |ibtex en|try, and|
|00001070| 20 74 68 65 20 7d 20 77 | 68 69 63 68 20 65 6e 64 | the } w|hich end|
|00001080| 20 69 74 0a 6d 75 73 74 | 20 62 65 20 74 68 65 20 | it.must| be the |
|00001090| 66 69 72 73 74 20 6e 6f | 6e 2d 77 68 69 74 65 73 |first no|n-whites|
|000010a0| 70 61 63 65 20 63 68 61 | 72 61 63 74 65 72 20 6f |pace cha|racter o|
|000010b0| 6e 20 74 68 65 69 72 20 | 6c 69 6e 65 2c 20 6f 72 |n their |line, or|
|000010c0| 20 74 68 65 79 0a 77 69 | 6c 6c 20 62 65 20 6d 69 | they.wi|ll be mi|
|000010d0| 73 73 65 64 2e 0a 41 6c | 73 6f 2c 20 6d 75 6c 74 |ssed..Al|so, mult|
|000010e0| 69 2d 6c 69 6e 65 20 66 | 69 65 6c 64 73 20 73 75 |i-line f|ields su|
|000010f0| 72 72 6f 75 6e 64 65 64 | 20 77 69 74 68 20 64 6f |rrounded| with do|
|00001100| 75 62 6c 65 20 71 75 6f | 74 65 73 20 6f 72 0a 63 |uble quo|tes or.c|
|00001110| 75 72 6c 65 79 20 62 72 | 61 63 6b 65 74 73 0a 61 |urley br|ackets.a|
|00001120| 72 65 20 68 61 6e 64 6c | 65 64 20 63 6f 72 72 65 |re handl|ed corre|
|00001130| 63 74 6c 79 2c 0a 62 75 | 74 20 75 67 6c 79 20 63 |ctly,.bu|t ugly c|
|00001140| 6f 6d 62 69 6e 61 74 69 | 6f 6e 73 20 6f 66 20 71 |ombinati|ons of q|
|00001150| 75 6f 74 65 73 20 61 6e | 64 20 62 72 61 63 6b 65 |uotes an|d bracke|
|00001160| 74 73 20 61 6e 64 20 62 | 61 63 6b 73 6c 61 73 68 |ts and b|ackslash|
|00001170| 65 64 0a 76 65 72 73 69 | 6f 6e 73 20 6f 66 20 74 |ed.versi|ons of t|
|00001180| 68 65 20 73 61 6d 65 20 | 6d 61 69 6c 20 66 61 69 |he same |mail fai|
|00001190| 6c 2e 0a 55 6d 6c 61 75 | 74 20 61 63 63 65 6e 74 |l..Umlau|t accent|
|000011a0| 73 20 61 72 65 20 72 65 | 6d 6f 76 65 64 20 66 72 |s are re|moved fr|
|000011b0| 6f 6d 20 74 68 65 20 73 | 65 61 72 63 68 0a 73 74 |om the s|earch.st|
|000011c0| 72 69 6e 67 2e 0a 0a 49 | 20 6d 61 6b 65 20 6e 6f |ring...I| make no|
|000011d0| 20 70 72 65 64 69 63 74 | 69 6f 6e 73 20 61 73 20 | predict|ions as |
|000011e0| 74 6f 20 68 6f 77 20 74 | 68 69 73 20 70 72 6f 67 |to how t|his prog|
|000011f0| 72 61 6d 20 77 69 6c 6c | 20 72 65 61 63 74 20 0a |ram will| react .|
|00001200| 74 6f 20 62 69 62 74 65 | 78 20 66 69 6c 65 73 20 |to bibte|x files |
|00001210| 77 69 74 68 20 73 79 6e | 74 61 78 20 65 72 72 6f |with syn|tax erro|
|00001220| 72 73 2e 0a 0a 0a 53 48 | 41 52 5f 45 4f 46 0a 66 |rs....SH|AR_EOF.f|
|00001230| 69 20 23 20 65 6e 64 20 | 6f 66 20 6f 76 65 72 77 |i # end |of overw|
|00001240| 72 69 74 69 6e 67 20 63 | 68 65 63 6b 0a 69 66 20 |riting c|heck.if |
|00001250| 74 65 73 74 20 2d 66 20 | 27 6c 6f 6f 6b 62 69 62 |test -f |'lookbib|
|00001260| 74 65 78 27 0a 74 68 65 | 6e 0a 09 65 63 68 6f 20 |tex'.the|n..echo |
|00001270| 73 68 61 72 3a 20 77 69 | 6c 6c 20 6e 6f 74 20 6f |shar: wi|ll not o|
|00001280| 76 65 72 2d 77 72 69 74 | 65 20 65 78 69 73 74 69 |ver-writ|e existi|
|00001290| 6e 67 20 66 69 6c 65 20 | 22 27 6c 6f 6f 6b 62 69 |ng file |"'lookbi|
|000012a0| 62 74 65 78 27 22 0a 65 | 6c 73 65 0a 63 61 74 20 |btex'".e|lse.cat |
|000012b0| 3c 3c 20 5c 53 48 41 52 | 5f 45 4f 46 20 3e 20 27 |<< \SHAR|_EOF > '|
|000012c0| 6c 6f 6f 6b 62 69 62 74 | 65 78 27 0a 23 21 2f 75 |lookbibt|ex'.#!/u|
|000012d0| 73 72 2f 6c 6f 63 61 6c | 2f 62 69 6e 2f 70 65 72 |sr/local|/bin/per|
|000012e0| 6c 0a 0a 23 0a 23 20 6c | 6f 6f 6b 62 69 62 74 65 |l..#.# l|ookbibte|
|000012f0| 78 20 31 2e 31 0a 23 20 | 4c 6f 6f 6b 20 69 6e 20 |x 1.1.# |Look in |
|00001300| 74 6f 20 61 20 62 69 62 | 20 66 69 6c 65 2e 0a 23 |to a bib| file..#|
|00001310| 0a 23 20 43 6f 70 79 72 | 69 67 68 74 20 28 43 29 |.# Copyr|ight (C)|
|00001320| 20 31 39 39 30 20 62 79 | 20 4a 6f 68 6e 20 48 65 | 1990 by| John He|
|00001330| 69 64 65 6d 61 6e 6e 0a | 23 20 54 68 69 73 20 69 |idemann.|# This i|
|00001340| 73 20 64 69 73 74 72 69 | 62 75 74 65 64 20 75 6e |s distri|buted un|
|00001350| 64 65 72 20 74 68 65 20 | 47 4e 55 20 50 75 62 6c |der the |GNU Publ|
|00001360| 69 63 20 4c 69 63 65 6e | 63 65 2c 20 56 65 72 73 |ic Licen|ce, Vers|
|00001370| 69 6f 6e 20 31 20 28 46 | 65 62 20 38 39 29 2e 0a |ion 1 (F|eb 89)..|
|00001380| 23 20 53 65 65 20 74 68 | 65 20 50 65 72 6c 20 64 |# See th|e Perl d|
|00001390| 6f 63 75 6d 65 6e 74 61 | 74 69 6f 6e 20 66 6f 72 |ocumenta|tion for|
|000013a0| 20 61 20 63 6f 70 79 20 | 6f 66 20 74 68 61 74 20 | a copy |of that |
|000013b0| 6c 69 63 65 6e 73 65 2e | 0a 23 0a 23 20 20 34 2d |license.|.#.# 4-|
|000013c0| 4f 63 74 2d 39 30 20 69 | 74 20 69 73 20 68 61 63 |Oct-90 i|t is hac|
|000013d0| 6b 65 64 20 74 6f 67 65 | 74 68 65 72 2e 0a 23 20 |ked toge|ther..# |
|000013e0| 31 39 2d 4e 6f 76 2d 39 | 30 20 4e 6f 77 20 69 74 |19-Nov-9|0 Now it|
|000013f0| 20 72 65 6d 65 6d 62 65 | 72 73 20 22 27 73 20 61 | remembe|rs "'s a|
|00001400| 6e 64 20 6a 6f 69 6e 20 | 73 75 63 68 20 6c 69 6e |nd join |such lin|
|00001410| 65 73 2e 0a 23 09 49 74 | 20 61 6c 73 6f 20 72 65 |es..#.It| also re|
|00001420| 6d 6f 76 65 73 20 6e 61 | 73 74 79 20 63 68 61 72 |moves na|sty char|
|00001430| 61 63 74 65 72 73 20 6c | 69 6b 65 20 7b 7d 20 66 |acters l|ike {} f|
|00001440| 72 6f 6d 20 74 68 65 20 | 73 65 61 72 63 68 20 73 |rom the |search s|
|00001450| 74 72 69 6e 67 2e 0a 23 | 20 32 30 2d 4e 6f 76 2d |tring..#| 20-Nov-|
|00001460| 39 30 20 55 6d 6c 61 75 | 74 20 61 63 63 65 6e 74 |90 Umlau|t accent|
|00001470| 73 20 68 61 6e 64 6c 65 | 64 20 63 6f 72 72 65 63 |s handle|d correc|
|00001480| 74 6c 79 2e 0a 23 20 32 | 38 2d 4e 6f 76 2d 39 30 |tly..# 2|8-Nov-90|
|00001490| 20 41 20 73 69 6d 70 6c | 65 20 68 65 75 72 69 73 | A simpl|e heuris|
|000014a0| 74 69 63 20 74 6f 20 68 | 61 6e 64 6c 65 20 6d 75 |tic to h|andle mu|
|000014b0| 6c 74 69 2d 6c 69 6e 65 | 20 66 69 65 6c 64 73 20 |lti-line| fields |
|000014c0| 77 69 74 68 20 7b 7d 27 | 73 20 69 73 20 61 64 64 |with {}'|s is add|
|000014d0| 65 64 2e 0a 23 20 20 20 | 20 20 20 20 49 6e 20 61 |ed..# | In a|
|000014e0| 64 64 69 74 69 6f 6e 2c | 20 77 65 20 63 6f 6d 70 |ddition,| we comp|
|000014f0| 72 65 73 73 20 61 6c 6c | 20 77 68 69 74 65 73 70 |ress all| whitesp|
|00001500| 61 63 65 20 74 6f 20 73 | 69 6e 67 6c 65 20 73 70 |ace to s|ingle sp|
|00001510| 61 63 65 73 20 69 6e 20 | 74 68 65 0a 23 09 73 65 |aces in |the.#.se|
|00001520| 61 72 63 68 65 64 20 76 | 65 72 73 69 6f 6e 2e 0a |arched v|ersion..|
|00001530| 23 0a 23 20 54 68 69 73 | 20 70 72 6f 67 72 61 6d |#.# This| program|
|00001540| 20 72 65 6c 69 65 73 20 | 6f 6e 20 74 68 65 20 63 | relies |on the c|
|00001550| 6f 6e 76 65 6e 74 69 6f | 6e 20 74 68 61 74 20 74 |onventio|n that t|
|00001560| 68 65 20 63 6c 6f 73 69 | 6e 67 20 7d 20 6f 66 20 |he closi|ng } of |
|00001570| 61 20 0a 23 20 62 69 62 | 20 65 6e 74 72 79 20 69 |a .# bib| entry i|
|00001580| 73 20 74 68 65 20 6f 6e | 6c 79 20 7d 20 69 6e 20 |s the on|ly } in |
|00001590| 74 68 65 20 66 69 72 73 | 74 20 6e 6f 6e 2d 77 68 |the firs|t non-wh|
|000015a0| 69 74 65 73 70 61 63 65 | 20 63 6f 6c 75 6d 6e 2c |itespace| column,|
|000015b0| 0a 23 20 61 6e 64 20 74 | 68 61 74 20 74 68 65 20 |.# and t|hat the |
|000015c0| 6f 70 65 6e 69 6e 67 20 | 40 20 69 73 20 61 6c 73 |opening |@ is als|
|000015d0| 6f 20 74 68 65 72 65 2e | 0a 23 0a 0a 0a 0a 24 2a |o there.|.#....$*|
|000015e0| 20 3d 20 31 3b 20 20 20 | 23 20 6d 61 6b 65 20 73 | = 1; |# make s|
|000015f0| 65 61 72 63 68 65 73 20 | 6f 6e 20 76 61 72 73 20 |earches |on vars |
|00001600| 77 69 74 68 20 69 6d 62 | 65 64 64 65 64 20 6e 65 |with imb|edded ne|
|00001610| 77 6c 69 6e 65 73 20 77 | 6f 72 6b 0a 0a 23 0a 23 |wlines w|ork..#.#|
|00001620| 20 63 75 73 74 6f 6d 69 | 7a 65 20 74 68 69 73 20 | customi|ze this |
|00001630| 74 6f 20 77 68 61 74 65 | 76 65 72 20 69 73 20 72 |to whate|ver is r|
|00001640| 69 67 68 74 20 6c 6f 63 | 61 6c 6c 79 0a 23 0a 24 |ight loc|ally.#.$|
|00001650| 64 65 66 61 75 6c 74 66 | 69 6c 65 20 3d 20 22 2f |defaultf|ile = "/|
|00001660| 75 2f 73 39 2f 75 2f 66 | 69 63 75 73 2f 44 4f 43 |u/s9/u/f|icus/DOC|
|00001670| 2f 66 69 63 75 73 2e 62 | 69 62 22 3b 0a 24 62 61 |/ficus.b|ib";.$ba|
|00001680| 64 6b 65 79 73 20 3d 20 | 22 73 74 72 69 6e 67 22 |dkeys = |"string"|
|00001690| 3b 20 20 20 20 23 20 6b | 65 79 73 20 74 6f 20 69 |; # k|eys to i|
|000016a0| 67 6e 6f 72 65 0a 0a 0a | 23 0a 23 20 64 6f 20 61 |gnore...|#.# do a|
|000016b0| 72 67 75 6d 65 6e 74 20 | 70 72 6f 63 65 73 73 69 |rgument |processi|
|000016c0| 6e 67 0a 23 0a 0a 69 66 | 20 28 24 23 41 52 47 56 |ng.#..if| ($#ARGV|
|000016d0| 20 3e 3d 20 31 20 26 26 | 20 24 41 52 47 56 5b 30 | >= 1 &&| $ARGV[0|
|000016e0| 5d 20 65 71 20 22 2d 6b | 22 29 20 7b 0a 09 24 6b |] eq "-k|") {..$k|
|000016f0| 65 79 77 6f 72 64 20 3d | 20 24 41 52 47 56 5b 31 |eyword =| $ARGV[1|
|00001700| 5d 3b 0a 09 73 68 69 66 | 74 20 28 40 41 52 47 56 |];..shif|t (@ARGV|
|00001710| 29 3b 0a 09 73 68 69 66 | 74 20 28 40 41 52 47 56 |);..shif|t (@ARGV|
|00001720| 29 3b 0a 7d 3b 0a 0a 69 | 66 20 28 24 23 41 52 47 |);.};..i|f ($#ARG|
|00001730| 56 20 3d 3d 20 30 29 20 | 7b 0a 09 24 66 69 6c 65 |V == 0) |{..$file|
|00001740| 20 3d 20 24 64 65 66 61 | 75 6c 74 66 69 6c 65 3b | = $defa|ultfile;|
|00001750| 0a 09 24 70 61 74 74 65 | 72 6e 20 3d 20 24 41 52 |..$patte|rn = $AR|
|00001760| 47 56 5b 30 5d 3b 0a 7d | 20 65 6c 73 69 66 20 28 |GV[0];.}| elsif (|
|00001770| 24 23 41 52 47 56 20 3d | 3d 20 31 29 20 7b 0a 09 |$#ARGV =|= 1) {..|
|00001780| 24 66 69 6c 65 20 3d 20 | 24 41 52 47 56 5b 30 5d |$file = |$ARGV[0]|
|00001790| 3b 0a 09 24 70 61 74 74 | 65 72 6e 20 3d 20 24 41 |;..$patt|ern = $A|
|000017a0| 52 47 56 5b 31 5d 3b 0a | 7d 20 65 6c 73 65 20 7b |RGV[1];.|} else {|
|000017b0| 0a 09 64 69 65 20 28 22 | 55 73 61 67 65 3a 20 6c |..die ("|Usage: l|
|000017c0| 6f 6f 6b 62 69 62 20 5b | 2d 6b 20 6b 65 79 77 6f |ookbib [|-k keywo|
|000017d0| 72 64 5d 20 5b 62 69 62 | 66 69 6c 65 2e 62 69 62 |rd] [bib|file.bib|
|000017e0| 5d 20 72 65 67 65 78 70 | 5c 6e 22 20 2e 0a 09 09 |] regexp|\n" ....|
|000017f0| 22 20 20 20 4b 65 79 77 | 6f 72 64 20 72 65 73 74 |" Keyw|ord rest|
|00001800| 72 69 63 74 73 20 74 68 | 65 20 72 65 67 65 78 70 |ricts th|e regexp|
|00001810| 20 73 65 61 72 63 68 20 | 74 6f 20 74 68 61 74 20 | search |to that |
|00001820| 62 69 62 74 65 78 20 22 | 20 2e 0a 09 09 09 22 66 |bibtex "| ....."f|
|00001830| 69 65 6c 64 20 6e 61 6d | 65 20 28 61 75 74 68 6f |ield nam|e (autho|
|00001840| 72 2c 20 65 74 63 2e 29 | 5c 6e 22 20 2e 0a 09 09 |r, etc.)|\n" ....|
|00001850| 22 20 20 20 44 65 66 61 | 75 6c 74 20 62 69 62 66 |" Defa|ult bibf|
|00001860| 69 6c 65 20 69 73 20 24 | 64 65 66 61 75 6c 74 66 |ile is $|defaultf|
|00001870| 69 6c 65 2c 20 2d 20 69 | 6e 64 69 63 61 74 65 73 |ile, - i|ndicates|
|00001880| 20 73 74 64 69 6e 2e 5c | 6e 22 20 2e 0a 09 09 22 | stdin.\|n" ...."|
|00001890| 20 20 20 52 65 67 65 78 | 70 20 69 73 20 61 20 50 | Regex|p is a P|
|000018a0| 65 72 6c 20 72 65 67 65 | 78 70 2e 5c 6e 22 29 3b |erl rege|xp.\n");|
|000018b0| 0a 7d 3b 0a 0a 23 0a 23 | 20 68 61 6e 64 6c 65 20 |.};..#.#| handle |
|000018c0| 74 68 65 20 6b 65 79 77 | 6f 72 64 20 62 79 20 6d |the keyw|ord by m|
|000018d0| 6f 64 69 66 79 69 6e 67 | 20 74 68 65 20 70 61 74 |odifying| the pat|
|000018e0| 74 65 72 6e 0a 23 0a 69 | 66 20 28 64 65 66 69 6e |tern.#.i|f (defin|
|000018f0| 65 64 28 24 6b 65 79 77 | 6f 72 64 29 29 20 7b 0a |ed($keyw|ord)) {.|
|00001900| 09 24 70 61 74 74 65 72 | 6e 20 3d 20 22 5e 5c 5c |.$patter|n = "^\\|
|00001910| 73 2a 24 7b 6b 65 79 77 | 6f 72 64 7d 5c 5c 73 2a |s*${keyw|ord}\\s*|
|00001920| 3d 2e 2a 24 7b 70 61 74 | 74 65 72 6e 7d 22 3b 0a |=.*${pat|tern}";.|
|00001930| 23 09 70 72 69 6e 74 20 | 22 70 61 74 74 65 72 6e |#.print |"pattern|
|00001940| 20 69 73 20 24 70 61 74 | 74 65 72 6e 5c 6e 22 3b | is $pat|tern\n";|
|00001950| 0a 7d 3b 0a 0a 0a 0a 23 | 0a 23 20 6c 6f 6f 6b 69 |.};....#|.# looki|
|00001960| 6e 67 20 66 6f 72 20 62 | 65 67 69 6e 6e 69 6e 67 |ng for b|eginning|
|00001970| 20 6f 66 20 62 69 62 20 | 65 6e 74 72 79 20 69 73 | of bib |entry is|
|00001980| 20 73 74 61 74 65 20 31 | 2c 20 69 6e 20 62 69 62 | state 1|, in bib|
|00001990| 20 69 73 20 73 74 61 74 | 65 20 32 0a 23 0a 24 73 | is stat|e 2.#.$s|
|000019a0| 74 61 74 65 20 3d 20 31 | 3b 0a 0a 0a 23 0a 23 20 |tate = 1|;...#.# |
|000019b0| 43 65 72 74 61 69 6e 20 | 6b 65 79 73 20 77 65 20 |Certain |keys we |
|000019c0| 72 65 61 6c 6c 79 20 77 | 61 6e 74 20 74 6f 20 69 |really w|ant to i|
|000019d0| 67 6e 6f 72 65 20 62 65 | 63 61 75 73 65 0a 23 20 |gnore be|cause.# |
|000019e0| 74 68 65 79 27 72 65 20 | 6e 6f 74 20 62 69 62 20 |they're |not bib |
|000019f0| 65 6e 74 72 69 65 73 2e | 20 20 54 68 65 79 27 72 |entries.| They'r|
|00001a00| 65 20 6c 69 73 74 65 64 | 20 68 65 72 65 2e 0a 23 |e listed| here..#|
|00001a10| 0a 40 62 61 64 6b 65 79 | 73 20 3d 20 73 70 6c 69 |.@badkey|s = spli|
|00001a20| 74 28 2f 2c 2f 2c 20 24 | 62 61 64 6b 65 79 73 29 |t(/,/, $|badkeys)|
|00001a30| 3b 0a 66 6f 72 65 61 63 | 68 20 24 69 20 28 40 62 |;.foreac|h $i (@b|
|00001a40| 61 64 6b 65 79 73 29 20 | 7b 0a 09 24 62 61 64 6b |adkeys) |{..$badk|
|00001a50| 65 79 73 7b 24 69 7d 20 | 3d 20 22 62 61 64 22 3b |eys{$i} |= "bad";|
|00001a60| 20 20 20 23 20 6a 75 73 | 74 20 6d 61 6b 65 20 74 | # jus|t make t|
|00001a70| 68 65 6d 20 64 65 66 69 | 6e 65 64 0a 7d 3b 0a 0a |hem defi|ned.};..|
|00001a80| 0a 0a 23 0a 23 20 54 6f | 20 64 6f 20 73 65 61 72 |..#.# To| do sear|
|00001a90| 63 68 65 73 20 72 69 67 | 68 74 2c 20 77 65 20 68 |ches rig|ht, we h|
|00001aa0| 61 76 65 20 74 6f 20 6d | 61 6b 65 20 65 76 65 72 |ave to m|ake ever|
|00001ab0| 79 74 68 69 6e 67 0a 23 | 20 66 6f 72 20 61 20 66 |ything.#| for a f|
|00001ac0| 69 65 6c 64 20 6f 6e 20 | 6f 6e 65 20 6c 69 6e 65 |ield on |one line|
|00001ad0| 2e 0a 23 20 20 20 20 54 | 68 69 73 20 72 6f 75 74 |..# T|his rout|
|00001ae0| 69 6e 65 20 64 6f 65 73 | 20 74 68 61 74 2c 20 61 |ine does| that, a|
|00001af0| 6e 64 20 61 6c 73 6f 20 | 67 65 74 73 20 72 69 64 |nd also |gets rid|
|00001b00| 20 6f 66 20 7b 7d 27 73 | 0a 23 20 77 68 69 63 68 | of {}'s|.# which|
|00001b10| 20 74 65 6e 64 20 74 6f | 20 67 65 74 20 69 6e 20 | tend to| get in |
|00001b20| 74 68 65 20 77 61 79 20 | 66 6f 72 20 73 65 61 72 |the way |for sear|
|00001b30| 63 68 65 73 2e 20 20 49 | 6e 20 74 68 65 0a 23 20 |ches. I|n the.# |
|00001b40| 73 61 6d 65 20 76 65 69 | 6e 2c 20 69 74 20 63 6f |same vei|n, it co|
|00001b50| 6c 6c 61 70 73 65 73 20 | 61 6c 6c 20 77 68 69 74 |llapses |all whit|
|00001b60| 65 73 70 61 63 65 20 74 | 6f 20 73 69 6e 67 6c 65 |espace t|o single|
|00001b70| 20 73 70 61 63 65 73 2e | 0a 23 0a 23 20 54 6f 20 | spaces.|.#.# To |
|00001b80| 6b 6e 6f 77 20 77 68 65 | 6e 20 74 6f 20 6a 6f 69 |know whe|n to joi|
|00001b90| 6e 20 6c 69 6e 65 73 2c | 20 77 65 20 75 73 65 20 |n lines,| we use |
|00001ba0| 74 77 6f 20 73 69 6d 70 | 6c 65 20 68 65 75 72 69 |two simp|le heuri|
|00001bb0| 73 74 69 63 73 3a 0a 23 | 20 69 73 20 74 68 65 72 |stics:.#| is ther|
|00001bc0| 65 20 61 72 65 20 61 20 | 6f 64 64 20 6e 75 6d 62 |e are a |odd numb|
|00001bd0| 65 72 20 6f 66 20 22 27 | 73 20 6f 6e 20 61 20 6c |er of "'|s on a l|
|00001be0| 69 6e 65 2c 20 77 65 20 | 6d 75 73 74 20 65 6e 74 |ine, we |must ent|
|00001bf0| 65 72 20 6f 72 20 65 78 | 69 74 0a 23 20 6d 75 6c |er or ex|it.# mul|
|00001c00| 74 69 2d 6c 69 6e 65 20 | 6d 6f 64 65 2e 20 20 49 |ti-line |mode. I|
|00001c10| 66 20 74 68 65 72 65 20 | 61 72 65 20 6d 6f 72 65 |f there |are more|
|00001c20| 20 7b 27 73 20 74 68 61 | 6e 20 7d 27 73 2c 20 77 | {'s tha|n }'s, w|
|00001c30| 65 20 6d 75 73 74 20 65 | 6e 74 65 72 2c 0a 23 20 |e must e|nter,.# |
|00001c40| 61 6e 64 20 69 66 20 74 | 68 65 72 65 20 61 72 65 |and if t|here are|
|00001c50| 20 6d 6f 72 65 20 7d 27 | 73 20 74 68 61 6e 20 7b | more }'|s than {|
|00001c60| 27 73 20 77 65 20 6d 75 | 73 74 20 65 78 69 74 20 |'s we mu|st exit |
|00001c70| 28 61 6e 79 74 68 69 6e | 67 20 6f 6e 0a 23 20 74 |(anythin|g on.# t|
|00001c80| 68 65 20 66 69 72 73 74 | 20 6c 69 6e 65 20 69 73 |he first| line is|
|00001c90| 20 69 67 6e 6f 72 65 64 | 29 2e 0a 23 0a 0a 73 75 | ignored|)..#..su|
|00001ca0| 62 20 70 72 69 6e 74 74 | 6f 73 65 61 72 63 68 20 |b printt|osearch |
|00001cb0| 7b 0a 09 6c 6f 63 61 6c | 20 28 24 70 72 69 6e 74 |{..local| ($print|
|00001cc0| 29 20 3d 20 40 5f 3b 0a | 09 6c 6f 63 61 6c 20 28 |) = @_;.|.local (|
|00001cd0| 24 73 65 61 72 63 68 2c | 20 24 6d 6f 64 65 29 20 |$search,| $mode) |
|00001ce0| 3d 20 28 22 22 2c 20 31 | 29 3b 0a 09 6c 6f 63 61 |= ("", 1|);..loca|
|00001cf0| 6c 20 28 24 6f 70 65 6e | 63 75 72 6c 65 79 2c 20 |l ($open|curley, |
|00001d00| 24 63 6c 6f 73 65 63 75 | 72 6c 65 79 29 20 3d 20 |$closecu|rley) = |
|00001d10| 28 30 2c 30 29 3b 0a 0a | 09 40 6c 69 6e 65 73 20 |(0,0);..|.@lines |
|00001d20| 3d 20 73 70 6c 69 74 28 | 2f 5c 6e 2f 2c 20 24 70 |= split(|/\n/, $p|
|00001d30| 72 69 6e 74 29 3b 0a 09 | 40 6c 69 6e 65 73 5b 30 |rint);..|@lines[0|
|00001d40| 5d 20 3d 7e 20 73 2f 7b | 2f 20 2f 3b 0a 09 66 6f |] =~ s/{|/ /;..fo|
|00001d50| 72 65 61 63 68 20 24 6c | 6e 20 28 40 6c 69 6e 65 |reach $l|n (@line|
|00001d60| 73 29 20 7b 0a 09 09 23 | 20 72 65 6d 6f 76 65 20 |s) {...#| remove |
|00001d70| 61 6e 64 20 63 6f 75 6e | 74 20 63 75 72 6c 65 79 |and coun|t curley|
|00001d80| 20 62 72 61 63 6b 65 74 | 73 0a 09 09 24 6f 70 65 | bracket|s...$ope|
|00001d90| 6e 63 75 72 6c 65 79 20 | 3d 20 28 24 6c 6e 20 3d |ncurley |= ($ln =|
|00001da0| 7e 20 73 2f 5b 7b 5d 2f | 2f 67 29 3b 0a 09 09 24 |~ s/[{]/|/g);...$|
|00001db0| 63 6c 6f 73 65 63 75 72 | 6c 65 79 20 3d 20 28 24 |closecur|ley = ($|
|00001dc0| 6c 6e 20 3d 7e 20 73 2f | 5b 7d 5d 2f 2f 67 29 3b |ln =~ s/|[}]//g);|
|00001dd0| 0a 09 09 69 66 20 28 24 | 6f 70 65 6e 63 75 72 6c |...if ($|opencurl|
|00001de0| 65 79 2d 24 63 6c 6f 73 | 65 63 75 72 6c 65 79 20 |ey-$clos|ecurley |
|00001df0| 3c 20 30 29 20 7b 0a 09 | 09 09 24 6d 6f 64 65 20 |< 0) {..|..$mode |
|00001e00| 3d 20 31 3b 0a 09 09 7d | 20 65 6c 73 69 66 20 28 |= 1;...}| elsif (|
|00001e10| 24 6f 70 65 6e 63 75 72 | 6c 65 79 2d 24 63 6c 6f |$opencur|ley-$clo|
|00001e20| 73 65 63 75 72 6c 65 79 | 20 3e 20 30 29 20 7b 0a |securley| > 0) {.|
|00001e30| 09 09 09 24 6d 6f 64 65 | 20 3d 20 30 3b 0a 09 09 |...$mode| = 0;...|
|00001e40| 7d 20 65 6c 73 65 20 7b | 0a 09 09 09 23 20 72 65 |} else {|....# re|
|00001e50| 6d 6f 76 65 20 75 6d 6c | 61 75 74 73 20 73 6f 20 |move uml|auts so |
|00001e60| 71 75 6f 74 65 20 68 61 | 6e 64 6c 69 6e 67 20 77 |quote ha|ndling w|
|00001e70| 6f 72 6b 73 2c 0a 09 09 | 09 23 20 61 6e 64 20 74 |orks,...|.# and t|
|00001e80| 68 65 6e 20 63 68 61 6e | 67 65 20 6d 6f 64 65 73 |hen chan|ge modes|
|00001e90| 20 69 66 20 72 65 71 75 | 69 72 65 64 2e 0a 09 09 | if requ|ired....|
|00001ea0| 09 24 6c 6e 20 3d 7e 20 | 73 2f 5c 5c 22 2f 2f 67 |.$ln =~ |s/\\"//g|
|00001eb0| 3b 0a 09 09 09 24 6d 6f | 64 65 20 3d 20 21 24 6d |;....$mo|de = !$m|
|00001ec0| 6f 64 65 20 20 69 66 20 | 28 28 24 6c 6e 20 3d 7e |ode if |(($ln =~|
|00001ed0| 20 74 72 2f 22 2f 22 2f | 29 20 25 20 32 20 3d 3d | tr/"/"/|) % 2 ==|
|00001ee0| 20 31 29 3b 0a 09 09 7d | 3b 0a 09 09 24 73 65 61 | 1);...}|;...$sea|
|00001ef0| 72 63 68 20 2e 3d 20 24 | 6c 6e 3b 0a 09 09 24 73 |rch .= $|ln;...$s|
|00001f00| 65 61 72 63 68 20 2e 3d | 20 22 5c 6e 22 20 20 69 |earch .=| "\n" i|
|00001f10| 66 20 28 24 6d 6f 64 65 | 29 3b 0a 09 7d 3b 0a 09 |f ($mode|);..};..|
|00001f20| 24 73 65 61 72 63 68 20 | 3d 7e 20 73 2f 5b 20 5c |$search |=~ s/[ \|
|00001f30| 74 5d 2b 2f 20 2f 67 3b | 0a 09 72 65 74 75 72 6e |t]+/ /g;|..return|
|00001f40| 20 24 73 65 61 72 63 68 | 3b 0a 7d 0a 0a 0a 0a 0a | $search|;.}.....|
|00001f50| 6f 70 65 6e 20 28 49 4e | 46 2c 20 22 3c 24 66 69 |open (IN|F, "<$fi|
|00001f60| 6c 65 22 29 20 7c 7c 20 | 64 69 65 20 28 22 63 61 |le") || |die ("ca|
|00001f70| 6e 6e 6f 74 20 6f 70 65 | 6e 20 62 69 62 66 69 6c |nnot ope|n bibfil|
|00001f80| 65 20 24 66 69 6c 65 22 | 29 3b 0a 0a 77 68 69 6c |e $file"|);..whil|
|00001f90| 65 20 28 3c 49 4e 46 3e | 29 20 7b 0a 23 09 70 72 |e (<INF>|) {.#.pr|
|00001fa0| 69 6e 74 20 22 6c 69 6e | 65 20 22 2c 20 24 69 2b |int "lin|e ", $i+|
|00001fb0| 2b 2c 20 22 20 73 74 61 | 74 65 3d 24 73 74 61 74 |+, " sta|te=$stat|
|00001fc0| 65 3a 20 24 5f 5c 6e 22 | 3b 0a 0a 09 69 66 20 28 |e: $_\n"|;...if (|
|00001fd0| 24 73 74 61 74 65 20 3d | 3d 20 31 29 20 7b 0a 09 |$state =|= 1) {..|
|00001fe0| 09 69 66 20 28 2f 5e 5b | 20 5c 74 5d 2a 40 28 5c |.if (/^[| \t]*@(\|
|00001ff0| 77 2b 29 2f 29 20 7b 20 | 20 20 23 20 62 65 67 69 |w+)/) { | # begi|
|00002000| 6e 6e 69 6e 67 20 6f 66 | 20 65 6e 74 72 79 0a 09 |nning of| entry..|
|00002010| 09 09 24 6b 65 79 20 3d | 20 24 31 20 3d 7e 20 74 |..$key =| $1 =~ t|
|00002020| 72 2f 41 2d 5a 2f 61 2d | 7a 2f 3b 20 20 20 23 20 |r/A-Z/a-|z/; # |
|00002030| 63 61 73 65 20 69 6e 73 | 65 6e 73 69 74 69 76 65 |case ins|ensitive|
|00002040| 20 6b 65 79 77 6f 72 64 | 73 0a 09 09 09 69 66 20 | keyword|s....if |
|00002050| 28 21 20 64 65 66 69 6e | 65 64 28 24 62 61 64 6b |(! defin|ed($badk|
|00002060| 65 79 73 7b 24 31 7d 29 | 29 20 7b 0a 09 09 09 09 |eys{$1})|) {.....|
|00002070| 24 73 74 61 74 65 20 3d | 20 32 3b 0a 09 09 09 09 |$state =| 2;.....|
|00002080| 24 62 69 62 65 6e 74 72 | 79 20 3d 20 24 5f 3b 0a |$bibentr|y = $_;.|
|00002090| 09 09 09 7d 3b 0a 09 09 | 7d 3b 0a 09 7d 20 65 6c |...};...|};..} el|
|000020a0| 73 69 66 20 28 24 73 74 | 61 74 65 20 3d 3d 20 32 |sif ($st|ate == 2|
|000020b0| 29 20 7b 0a 09 09 24 62 | 69 62 65 6e 74 72 79 20 |) {...$b|ibentry |
|000020c0| 2e 3d 20 24 5f 3b 0a 09 | 09 69 66 20 28 2f 5e 5b |.= $_;..|.if (/^[|
|000020d0| 20 5c 74 5d 2a 7d 2f 29 | 20 7b 20 20 20 23 20 65 | \t]*}/)| { # e|
|000020e0| 6e 64 69 6e 67 0a 09 09 | 09 24 73 65 61 72 63 68 |nding...|.$search|
|000020f0| 65 6e 74 72 79 20 3d 20 | 26 70 72 69 6e 74 74 6f |entry = |&printto|
|00002100| 73 65 61 72 63 68 28 24 | 62 69 62 65 6e 74 72 79 |search($|bibentry|
|00002110| 29 3b 0a 09 09 09 70 72 | 69 6e 74 20 22 24 62 69 |);....pr|int "$bi|
|00002120| 62 65 6e 74 72 79 5c 6e | 22 20 20 69 66 20 28 24 |bentry\n|" if ($|
|00002130| 73 65 61 72 63 68 65 6e | 74 72 79 20 3d 7e 20 2f |searchen|try =~ /|
|00002140| 24 70 61 74 74 65 72 6e | 2f 69 29 3b 0a 09 09 09 |$pattern|/i);....|
|00002150| 24 73 74 61 74 65 20 3d | 20 31 3b 0a 09 09 7d 0a |$state =| 1;...}.|
|00002160| 09 7d 20 65 6c 73 65 20 | 7b 0a 09 09 64 69 65 20 |.} else |{...die |
|00002170| 28 22 73 74 61 74 65 20 | 70 72 6f 62 6c 65 6d 2c |("state |problem,|
|00002180| 20 24 73 74 61 74 65 5c | 6e 22 29 3b 0a 09 7d 3b | $state\|n");..};|
|00002190| 0a 7d 0a 0a 0a 53 48 41 | 52 5f 45 4f 46 0a 63 68 |.}...SHA|R_EOF.ch|
|000021a0| 6d 6f 64 20 2b 78 20 27 | 6c 6f 6f 6b 62 69 62 74 |mod +x '|lookbibt|
|000021b0| 65 78 27 0a 66 69 20 23 | 20 65 6e 64 20 6f 66 20 |ex'.fi #| end of |
|000021c0| 6f 76 65 72 77 72 69 74 | 69 6e 67 20 63 68 65 63 |overwrit|ing chec|
|000021d0| 6b 0a 23 09 45 6e 64 20 | 6f 66 20 73 68 65 6c 6c |k.#.End |of shell|
|000021e0| 20 61 72 63 68 69 76 65 | 0a 65 78 69 74 20 30 0a | archive|.exit 0.|
|000021f0| 0a | |. | |
+--------+-------------------------+-------------------------+--------+--------+