home *** CD-ROM | disk | FTP | other *** search
- ############################################################################
- #
- # Name: 1.4
- #
- # Title: look up words in hacker's jargon database
- #
- # Author: Richard L. Goerwitz
- #
- # Version: jargon.icn
- #
- ############################################################################
- #
- # Defines hacker's jargon. Usage is simply "jargon word," where word
- # is some bit of hacker's slang for which a definition is desired.
- # Aborts with an exit code of 1 on no-arg invocation. If a "word"
- # arg is given, but no definition is found, jargon exits with status
- # 2. Otherwise the appropriate entry for "word" is displayed.
- #
- # Database is based on the jargon file, version 2.7.1, posted to alt.
- # sources on March 1, 1991. Might work on other versions, though I
- # have not tested it out.
- #
- ############################################################################
- #
- # Links: gettext.icn, adjuncts.icn
- #
- ############################################################################
-
- procedure main(a)
-
- local database, usage, no, yes
-
- # Change this, if you use a different location.
- database := "/usr/local/lib/jargon/jargon.wrd"
-
- no := &ucase || "-/"; yes := &lcase || " "
- usage := "usage: jargon word"
- *a = 1 | stop(usage)
- write(gettext(trim(map(a[1], no, yes)), database)) | exit(2)
-
- end
-