Jump to content United States-English
HP.com Home Products and Services Support and Drivers Solutions How to Buy
» Contact HP
More options
HP.com home
HP-UX Reference > W


HP-UX 11i Version 3: February 2007

Technical documentation

» Feedback
Content starts here

 » Table of Contents

 » Index


what — get SCCS identification information


what [-s] file...


The what command searches the given files for all occurrences of the pattern that get(1) substitutes for %Z% (currently @(#) at this printing) and prints out what follows until the first " , >, newline, \, or null character. For example, if the C program in file f.c contains

char ident[] = "@(#)identification information";

and f.c is compiled to yield f.o and a.out, the command

what f.c f.o a.out



identification information


identification information


identification information

what is intended to be used in conjunction with the SCCS get command (see get(1)) which automatically inserts identifying information, but it can also be used where the information is inserted manually.


what recognizes the following option:


Quit after finding the first occurrence of pattern in each file.


Environment Variables

LC_CTYPE determines the interpretation of the pattern substituted for %Z% as single- and/or multibyte characters.

LC_MESSAGES determines the language in which messages are displayed.

If LC_CTYPE or LC_MESSAGES is not specified in the environment or is set to the empty string, the value of LANG is used as a default for each unspecified or empty variable. If LANG is not specified or is set to the empty string, a default of "C" (see lang(5)) is used instead of LANG. If any internationalization variable contains an invalid setting, what behaves as if all internationalization variables are set to "C". See environ(5).

International Code Set Support

Single-byte and multibyte character code sets are supported.


Exit status is 0 if any matches are found, otherwise 1. Use help for explanations (see sccshelp(1)).


The pattern @(#) may occasionally appear unintentionally in random files, but this causes no harm in nearly all cases.


what: SVID2, SVID3, XPG2, XPG3, XPG4

Printable version
Privacy statement Using this site means you accept its terms Feedback to webmaster
© 1983-2007 Hewlett-Packard Development Company, L.P.