Variable Attributes

Variables can have one or more attributes that specify their internal representation, scope, or the way they are displayed.

Variable Attribute Assignment Format

typeset –H variableSet Unix to host-name file mapping for non-Unix systems
typeset –i variableSet variable to be integer type
typeset –in variableSet variable to be integer type with base n
typeset –l variableSet variable to lower case
typeset –L variableLeft justify variable; the field width is specified by the first assignment
typeset –Ln variableLeft justify variable; set field width to n
typeset –LZn variableLeft justify variable; set field width to n and strip leading zeros
typeset –r variableSet variable to be readonly (same as readonly)
typeset –R variableRight justify variable; the field width is specified by the first assignment
typeset –Rn variableRight justify variable; set field width to n
typeset –RZn variableRight justify variable; set field width to n and fill with leading zeros
typeset –t variableSet the user-defined attribute for variable. This has no meaning to the Korn shell.
typeset –u variableSet variable to upper case
typeset –x variableAutomatically export variable to the environment (same as export)
typeset –Z variableSame as typeset –RZ

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.144.228.78