1@pindex ngettext
2@cindex @code{ngettext} program, usage
3@example
4ngettext [@var{option}] [@var{textdomain}] @var{msgid} @var{msgid-plural} @var{count}
5@end example
6
7@cindex lookup plural message translation
8The @code{ngettext} program displays the native language translation of a
9textual message whose grammatical form depends on a number.
10
11@noindent @strong{Arguments}
12
13@table @samp
14@item -d @var{textdomain}
15@itemx --domain=@var{textdomain}
16@opindex -d@r{, @code{ngettext} option}
17@opindex --domain@r{, @code{ngettext} option}
18Retrieve translated messages from @var{textdomain}.  Usually a @var{textdomain}
19corresponds to a package, a program, or a module of a program.
20
21@item -e
22@opindex -e@r{, @code{ngettext} option}
23Enable expansion of some escape sequences.  This option is for compatibility
24with the @samp{gettext} program.  The escape sequences
25@samp{\a}, @samp{\b}, @samp{\c}, @samp{\f}, @samp{\n}, @samp{\r}, @samp{\t},
26@samp{\v}, @samp{\\}, and @samp{\} followed by one to three octal digits, are
27interpreted like the SystemV @samp{echo} program does.
28
29@item -E
30@opindex -E@r{, @code{ngettext} option}
31This option is only for compatibility with the @samp{gettext} program.  It has
32no effect.
33
34@item -h
35@itemx --help
36@opindex -h@r{, @code{ngettext} option}
37@opindex --help@r{, @code{ngettext} option}
38Display this help and exit.
39
40@item -V
41@itemx --version
42@opindex -V@r{, @code{ngettext} option}
43@opindex --version@r{, @code{ngettext} option}
44Output version information and exit.
45
46@item @var{textdomain}
47Retrieve translated message from @var{textdomain}.
48
49@item @var{msgid} @var{msgid-plural}
50Translate @var{msgid} (English singular) / @var{msgid-plural} (English plural).
51
52@item @var{count}
53Choose singular/plural form based on this value.
54
55@end table
56
57If the @var{textdomain} parameter is not given, the domain is determined from
58the environment variable @code{TEXTDOMAIN}.  If the message catalog is not
59found in the regular directory, another location can be specified with the
60environment variable @code{TEXTDOMAINDIR}.
61