DICO(1) GNU Dico Reference DICO(1)
NAME
dico - GNU dictionary client program
SYNOPSIS
dico [-DHISamqtv] [-c STRING] [-d NAME] [-i DBNAME] [-k STRING] [-p
SERVICE] [-s NAME] [-u NAME] [--autologin=NAME] [--client=STRING]
[--database=NAME] [--dbs] [--help] [--host=SERVER] [--info=DBNAME]
[--key=STRING] [--levdist=N] [--levenshtein-distance=N] [--match]
[--noauth] [--nosasl] [--password=STRING] [--port=SERVICE] [--quiet]
[--sasl] [--serverhelp] [--serverinfo] [--source-info] [--source=ADDR]
[--strategies] [--strategy=NAME] [--time-stamp] [--transcript]
[--user=NAME] [--verbose] [URL-or-WORD]
dico -h
dico --help
dico --usage
dico --version
NOTE
This manpage is a short description of GNU dico. For a detailed discus-
sion, including examples and usage recommendations, refer to the GNU Di-
co Manual available in texinfo format. If the info reader and GNU Dico
documentation are properly installed on your system, the command
info dico
should give you access to the complete manual.
You can also view the manual using the info mode in emacs(1), or find it
in various formats online at
http://www.gnu.org.ua/software/dico/manual
If any discrepancies occur between this manpage and the GNU Dico Manual,
the later shall be considered the authoritative source.
DESCRIPTION
Console-based utility for querying dictionary servers. It has two oper-
ation modes.
In single query mode, dico performs a query, displays its result and ex-
its immediately. This mode is enabled if a word or a URL was given in
the command line.
In interactive mode, dico enters a read-and-eval loop, in which it reads
requests from the keyboard, performs the necessary searches, and dis-
plays obtained results on the screen.
Upon startup, dico looks for initialization files named .dico in the
current user's home directory, and the current working directory. If
found, these files are read in order, and their contents is treated as a
sequence of commands, which are executed. See the section COMMANDS, for
a discussion of available commands.
OPTIONS
Server Selection
-d, --database=NAME]fR
Select database to search.
--host=SERVER
Connect to this server.
-p, --port=SERVICE
Specify port to connect to.
--source=ADDR
Set source address for TCP connections.
Operation Modes
-D, --dbs
Show available databases.
-H, --serverhelp
Show server help.
-I, --serverinfo
Show information about the server.
-S, --strategies
Show available search strategies.
-i, --info=DBNAME
Show information about database DBNAME.
--levdist, --levenshtein-distance=N
Set maximum Levenshtein distance to N.
-m, --match
Match instead of define.
-q, --quiet
Do not print the normal dico welcome banner.
-s, --strategy=NAME
Select a strategy for matching. Implies --match.
Authentication
-a, --noauth
Disable authentication.
--autologin=NAME
Set the name of autologin file to use.
-c, --client=STRING
Additional text for client command.
-k, --key, --password=STRING
Set shared secret for authentication.
--nosasl
Disable SASL authentication.
--sasl Enable SASL authentication (default).
-u, --user=NAME
Set user name for authentication.
Debugging
--source-info
Include source line information in the debugging output.
-t, --transcript
Enable session transcript.
--time-stamp
Include time stamp in the debugging output.
-v, --verbose
Increase debugging verbosity level.
Other Options
-V, --version
Print program version.
-h, --help
Print a short summary of command line options.
--usage
Display a short usage message.
COMMANDS
In interactive mode dico reads commands from the standard input, exe-
cutes them and displays results on the standard output. If the standard
input is connected to a terminal, the readline and history facilities
are enabled.
The input syntax is designed so as to save you the maximum amount of
typing.
A line beginning with a # sign introduces a comment and is ignored.
Typing quiestion mark alone shows a short usage summary.
All commands begin with a command prefix, a single punctuation character
used to tell a command from a define or match request. The default com-
mand prefix is a dot.
Any input starting with a slash is a match request. For example,
/sail
will display all headwords matching the word sail in the currently se-
lected database.
Any input not starting with / or command prefix is a definition request.
It is looked up using the defaault server and database settings, and the
result is displayed on the screen.
Dico initialization files have the same syntax, excepting that no com-
mand prefix is used by default.
Available commands (without prefix) are summarized in the table below:
autologin FILE
Use FILE for authentication. If FILE begins with ~/, this prefix
is replaced with the name of the current user home directory,
followed by /. The prefix ~USER/ is replaced with the home di-
rectory of USER. This command is mostly useful in the initial-
ization file.
See the section AUTOLOGIN FILE, for a discussion of this feature.
close Close the existing connection.
database [NAME]
Without argument, display the currently selected database. With
argument, select the database NAME.
distance [N]
If the remote server supports xlev experimental capability, this
command shows the maximum Levenshtein distance. With argument,
it sets the distance.
help Displays short command usage summary. For convenience, a single
question mark can be used instead of this command.
history
Show command history.
info [NAME]
Display information about the database NAME, or the currently se-
lected database, if used without arguments.
ld List databases.
ls List strategies.
open HOST [PORT]
Establish connection with remote server HOST. If given, use PORT
instead of the default 2628.
pager [COMMAND]
Sets or displays external command used for paging output.
prefix [CHAR]
Without argument, shows the currently selected command prefix.
With argument, sets command prefix to the given value.
prompt STRING
Sets dico command line prompt.
quiet yes|no
Toggle the startup banner. Useful in the initialization file.
quit Quit the dico shell.
sasl [yes|no]
Without argument, show whether the SASL authentication is en-
abled. With argument, enable or disable it.
strategy [NAME]
Without argument, display the currently selected matching
strateguy. With argument, select the strategy NAME.
transcript [yes|no]
Enable or disable session transcript. When the transcript is on,
dico displays raw DICT commands and answers as they are executed.
It is useful for debugging purposes.
Used without arguments, this command shows current state of the
transcript.
version
Print program version.
warranty
Print the copyright statement.
AUTOLOGIN FILE
After connecting to a remote server, dico checks if the server supports
authentication and attempts to authenticate itself if so. The authenti-
cation credentials are taken from the following sources:
1. Command line options --user and --password.
2. URL given as a command line argument.
3. Autologin files.
These three sources are consulted in that order, i.e., a user name sup-
plied with the --user command line option takes precedence over the one
found in an URL and over any names supplied by autologin files.
If, after consulting all these sources, the user name is established,
while the password is not, the resulting action depends on whether the
standard input is connected to a terminal. If it is, dico will ask the
user to supply a password. If it is not, authentication is aborted and
connection to the server is closed.
Some authentication mechanisms require additional credentials. For ex-
ample, GSSAPI authentication requires a service name. These credentials
can be supplied only in autologin file.
Autologin file is a plaintext file that contains authentication informa-
tion for various DICT servers. At most two autologin files are consult-
ed: first the session-specific file, if it is supplied by autologin com-
mand or by the --autologin command line option, next the default file
.dicologin in the user's home directory. The default autologin file is
examined only if no matching record was found in the session-specific
one.
The file format is similar to that of .netrc.
Empty lines and comments are ignored. Comments are introduced by a
pound sign. Non-empty lines constitute statements. Tokens in a state-
ment are separated with spaces, tabs, or newlines. A valid statement
must begin with one of the following:
machine NAME
This statement contains parameters for authenticating on server
NAME.
default
This statement contains parameters for authenticating on any
server, not explicitly listed in one of the machine statements.
There can be at most one default statement in autologin file.
Its exact location does not matter, it will always be matched af-
ter all explicit machine statements.
The following clauses can follow:
login NAME
Supplies the user name for this server.
password STRING
Supplies the password for this server.
noauth Do not perform authentication on this server.
sasl Enable SASL authentication.
nosasl Disable SASL authentication.
mechanisms LIST
Declare acceptable SASL mechanisms. The LIST argument is a com-
ma-separated list of mechanism names, without intervening white-
space. Multiple mechanisms clauses may be present, in which case
the corresponding lists are concatenated.
service NAME
Declare service name, for authentication methods that need it.
If this token is omitted, the default service name dico is used.
realm NAME
Declare realm for authentication.
host NAME
Set host name for this server. By default, it is determined au-
tomatically.
SEE ALSO
dicod(8).
Complete GNU Dico manual: run info dico or use emacs(1) info mode to
read it.
Online copies of GNU Dico documentation in various formats can be found
at:
http://www.gnu.org.ua/software/dico/manual
AUTHORS
Sergey Poznyakoff
BUG REPORTS
Report bugs to <bug-dico@gnu.org.ua>.
COPYRIGHT
Copyright © 2008-2014 Sergey Poznyakoff
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licens-
es/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
GNU DICO August 5, 2016 DICO(1)
Generated by dwww version 1.16 on Tue Dec 16 06:22:54 CET 2025.