*nix Documentation Project
·  Home
 +   man pages
·  Linux HOWTOs
·  FreeBSD Tips
·  *niX Forums

  man pages->IRIX man pages -> srchtxt (1)              
Title
Content
Arch
Section
 

Contents


srchtxt(1)							    srchtxt(1)


NAME    [Toc]    [Back]

     srchtxt - display contents	of, or search for a text string	in, message
     databases

SYNOPSIS    [Toc]    [Back]

     srchtxt [-s] [-i msgnum] [-l locale] [-m msgfile<b>, ...]  [text]

DESCRIPTION    [Toc]    [Back]

     The srchtxt utility is used to display all	the text strings in message
     databases,	or to search for a text	string in message databases [see
     mkmsgs(1)].  These	databases are files in the directory
     /usr/lib/locale/locale<b>/LC_MESSAGES	[see setlocale(3C)], unless a file
     name given	with the -m option contains a /.  The directory	locale can be
     viewed as the name	of the language	in which the text strings are written.
     When the -l option	is not used, the locale	directory searched is
     specified by the LC_MESSAGES environment variable if it is	set to a nonempty
 value.  Otherwise, it is specified by the environment variable LANG
     if	it is set to a non-empty value.	 Otherwise, the	directory C is used.
     Text strings may contain supplementary code set characters.

     If	no text	argument is present, then all the text strings in the files
     accessed will be displayed.

     The meanings of the options are as	follows:

     -s		 suppress printing of the message sequence numbers of the
		 messages being	displayed

     -l	locale	 access	files in the directory
		 /usr/lib/locale/locale<b>/LC_MESSAGES.  If -m msgfile is also
		 supplied, locale is ignored for msgfiles containing a /.

     -m	msgfile	 access	file(s)	specified by one or more msgfiles.  If msgfile
		 contains a / character, then msgfile is interpreted as	a
		 pathname; otherwise, it will be assumed to be in the
		 directory determined as described above.  To specify more
		 than one msgfile, separate the	file names using commas.

     -i	msgnum	 display only the message whose	numeric	id equals msgnum.
		 This option should not	normally be used with a	search text.

     text	 search	for the	text string specified by text and display each
		 one that matches.  text can take the form of a	regular
		 expression [see ed(1)].

     If	the -s option is not specified,	the displayed text is prefixed by
     message sequence numbers.	The message sequence numbers are enclosed in
     angle brackets:  <msgfile<b>:msgnum<b>>.

     msgfile	 name of the file where	the displayed text occurred





									Page 1






srchtxt(1)							    srchtxt(1)



     msgnum	 sequence number in msgfile where the displayed	text occurred

     This display is in	the format used	by gettxt(1) and gettxt(3C).

EXAMPLES    [Toc]    [Back]

     The following examples show uses of srchtxt.

     Example 1:

	  If message files have	been installed in a locale named french	by
	  using	mkmsgs(1), then	you could display the entire set of text
	  strings in the french	locale (/usr/lib/locale/french/LC_MESSAGES/*)
	  by entering:

	       srchtxt -l french

     Example 2:

	  If a set of error messages associated	with the UNIX operating	system
	  have been installed in the file UX in	the french locale
	  (/usr/lib/locale/french/LC_MESSAGES/UX), then, using the value of
	  the LANG environment variable	to determine the locale	to be
	  searched, you	could search that file in that locale for all error
	  messages dealing with	files by entering:

	       LANG=french; export LANG
	       srchtxt -m UX "[Ff]ichier"

	  If /usr/lib/locale/french/LC_MESSAGES/UX contained the following
	  strings:

	       Erreur E/S\n
	       Liste d'arguments trop longue\n
	       Fichier inexistant\n
	       Argument	invalide\n
	       Trop de fichiers	ouverts\n
	       Fichier trop long\n
	       Trop de liens\n
	       Argument	hors du	domaine\n
	       Identificateur supprim\n
	       Etreinte	fatale\n
		 .
		 .
		 .

	  then the following strings would be displayed:
	       <UX:3>Fichier inexistant\n
	       <UX:5>Trop de fichiers ouverts\n
	       <UX:6>Fichier trop long\n






									Page 2






srchtxt(1)							    srchtxt(1)



     Example 3:

	  If a set of error messages associated	with the UNIX operating	system
	  has been installed in	the file UX and	a set of error messages
	  associated with the INGRESS database product have been installed in
	  the file ingress, both in the	german locale, then you	could search
	  for the pattern [Dd]atei in both the files UX	and ingress in the
	  german locale	by entering:

	       srchtxt -l german -m UX,ingress "[Dd]atei"

FILES    [Toc]    [Back]

     /usr/lib/locale/C/LC_MESSAGES/*	     default files created by
					     mkmsgs(1)

     /usr/lib/locale/locale<b>/LC_MESSAGES/*    message files created by
					     mkmsgs(1)

SEE ALSO    [Toc]    [Back]

      
      
     ed(1), exstr(1), gettxt(1), mkmsgs(1), gettxt(3C),	setlocale(3C),
     environ(5)

DIAGNOSTICS    [Toc]    [Back]

     The error messages	produced by srchtxt are	intended to be selfexplanatory.
  They	indicate an error in the command line or errors
     encountered while searching for a particular locale and/or	message	file.


									PPPPaaaaggggeeee 3333
[ Back ]
 Similar pages
Name OS Title
lookbib FreeBSD search bibliographic databases
lkbib FreeBSD search bibliographic databases
lookbib NetBSD search bibliographic databases
lkbib NetBSD search bibliographic databases
lkbib OpenBSD search bibliographic databases
lookbib OpenBSD search bibliographic databases
gettxt Tru64 Retrieves a text string from a message catalog
gettxt IRIX retrieve a text string from a message database
DtSearchRetrieve HP-UX Return clear text of documents from DtSearch databases
nislog HP-UX display the contents of the NIS+ transaction log
Copyright © 2004-2005 DeniX Solutions SRL
newsletter delivery service