Commit Graph

25 Commits

Author SHA1 Message Date
maya cdbb5491cb Try freebsd's pkg-info as well
From John Hein, via Nikolai Lifanov. PR misc/52684
2018-08-16 13:31:04 +00:00
eadler 31ce73e04a wtf(6): use character classes
ok pgoyette@ silence dholland@
2018-03-07 08:25:43 +00:00
eadler 7c4228cc00 wtf(6): quote "$f"
ok pgoyette@ silence dholland@
2018-03-07 08:24:16 +00:00
pgoyette 0a18c53300 Don't skip the superfluous "is" argument if it's not superfluous!
This allows us to use `wtf is` and get information for the acronym "is"
and produces the same output as `wtf is is` withough requiring the extra
typing by the user.
2018-01-17 03:03:59 +00:00
christos ad5d6863f7 obey $ACRONYMDB like before 2015-04-21 23:56:30 +00:00
christos 96276379e9 Add -o flag. 2015-04-21 22:49:46 +00:00
abs 2de37ae37b PR/47178 from Bug Hunting
src/games/wtf/wtf:
- Correct `usage' (to match new `SYNOPSIS' from man page);
- augment comment on quering pkgsrc's help facility;
- correct interpretation of pkgsrc' help facility query result.

src/games/wtf/wtf.6:
- enhance `SYNOPSIS', document description (`.Dd'), and overal
  program description;
- augment description about quering pkgsrc's help facility;
- improve wording;
- augment `HISTORY' section;
- bump date.
2012-11-20 12:40:54 +00:00
wiz a04ce0cefc - correct `usage' message;
- improve wording.

From Bug Hunting.
2012-10-03 19:50:06 +00:00
christos 5deb5aa698 use modern shell constructs 2012-04-26 03:16:13 +00:00
jschauma f25e87abc8 allow multiple '-f acronyms' arguments to be given, which makes this behave
more consistently with ACRONYMSDB, which may also point to multiple files
2012-04-26 01:55:14 +00:00
hubertf e5fa46c791 Teach wtf(6) about pkgsrc's help facility:
% cd /usr/pkgsrc/audio/qsynth
% wtf subst
subst: ===> mk/subst.mk:
# This Makefile fragment implements a general text replacement facility.
...
2007-08-06 21:14:36 +00:00
hubertf be5e286e64 - Don't call basename $0 at many places. Use variable $PROGNAME
- Better check when neither $ACRONYMDB is define nor files in
   /usr/share/misc/ are found
 - Replace cat | fgrep to using fgrep only
 - Replace sort | uniq to using sort -u

By Slava Semushin <slava.semushin@gmail.com> in private email.
2007-01-24 13:17:42 +00:00
peter 900682383e Remove the -t flag from the usage. 2005-07-01 14:21:49 +00:00
hubertf e5a0b604a9 * Change program logic to not nest needlessly
* Search all acronyms databases, and don't force the user to
   know in which category to look (-t is gone)
 * If an acronym is not found in the database or by whatis(1),
   also check pkg_info(1). Per PR bin/30539 by Geert Hendrickx
   (geert.hendrickx@ua.ac.be)

OK'd by Julio M. Merino Vidal <jmmv>
2005-06-22 20:11:03 +00:00
jmmv 24c2b45c15 Implement a -t option, to easily select an acronyms list from /usr/share/misc.
One can do `wtf -t comp pci' and it will use /usr/share/misc/acronyms.comp
to search the acronym as usual.
2003-04-25 19:08:31 +00:00
jmmv 103c8a5c49 And use basename $0 to get program's name... 2003-04-10 09:21:19 +00:00
jmmv 013854bde3 Implement the `-f' command line option to specify which acronyms database
to use.  Overrides ACRONYMDB's value, if given.
2003-04-10 09:18:24 +00:00
salo f3a1dd8300 Use pipe ("|") as a sed command field separator and allow slash ("/")
character in acronyms.  (e.g. W/, B/C, ...)

Approved by jdolecek.
2003-02-06 15:17:01 +00:00
soren 3dbb440e9f Just print basename in usage string. 2000-11-21 00:18:52 +00:00
hubertf 8448f50af7 Do not match non-literals (REs).
A slightly different patch was submitted in PR 8388 by
Antti Kantee <pooka@iki.fi>
1999-11-15 19:14:01 +00:00
sommerfeld 7e9fe5fb1e Fix the part of pr8201 which is IMHO a bug: the error message now goes
to stderr.

The existing error message ("I don't know what xxx means") is
unchanged, as it is stylisticly in keeping with the light-hearted
nature of the program, and is also more likely to be accurate than the
"no such acronym" error message proposed in 8201.
1999-08-13 03:02:06 +00:00
drochner b0c1735026 make sure only whole words are matched, use [:space:] RE to avoid embedded
<TAB>s
1999-07-27 15:41:27 +00:00
briggs b0412de83c Check whatis(1) if we don't find an acronym matching the argument 1999-07-25 20:29:04 +00:00
lukem fb5a2a2eb1 remove sh warning when invoked with no args 1999-07-22 10:08:17 +00:00
mrg 3fd868859a Allen Briggs' wtf(6) to grovel the acronyms database. 1999-07-22 01:03:20 +00:00