# Manpage diff for cd No differences encountered # Manpage diff for jobs No differences encountered # Manpage diff for kill --- kill.1.original.txt Tue Dec 4 16:53:05 2007 +++ kill.1.new.txt Tue Dec 4 21:33:44 2007 @@ -283,12 +283,14 @@ ksh93 ____________________________________________________________ - | ATTRIBUTE TYPE | ATTRIBUTE VALUE | - |______________________________|______________________________| - | Availability | SUNWcsu | - |______________________________|______________________________| - | Interface Stability | Uncommitted | - |______________________________|______________________________| + | ATTRIBUTE TYPE | ATTRIBUTE VALUE | + |______________________________|____________________________| + | Availability | SUNWcsu | + |______________________________|____________________________| + | CSI | enabled | + |______________________________|____________________________| + | Interface Stability | Uncommitted | + |______________________________|____________________________| SEE ALSO csh(1), jobs(1), ksh(1), ksh93(1), ps(1), sh(1), shell_builtins(1), @@ -296,6 +298,10 @@ butes(5), environ(5), standards(5) NOTES + /usr/bin/kill + The number of realtime signals supported is defined by the + getconf value _POSIX_RTSIG_MAX. + sh The Bourne shell, sh, has a built-in version of kill to pro- vide the functionality of the kill command for processes # Manpage diff for logname --- logname.1.original.txt Fri Oct 19 08:24:45 2007 +++ logname.1.new.txt Fri Oct 19 09:08:57 2007 @@ -9,9 +9,14 @@ logname - return user's login name SYNOPSIS - logname + /usr/bin/logname + ksh93 + logname + DESCRIPTION + /usr/bin/logname + The logname utility will write the user's login name to standard output. The login name is the string that would be returned by the getlogin(3C) function. Under the conditions @@ -19,6 +24,15 @@ message to standard error and exit with a non-zero exit status. + ksh93 + logname + + logname writes the users's login name to standard output. + The login name is the string that is returned by the + getlogin(2) function. If getlogin(2) does not return + successfully, the corresponding to the real user id of the + calling process is used instead. + ENVIRONMENT VARIABLES See environ(5) for descriptions of the following environment variables that affect the execution of logname: LANG, # Manpage diff for mkfifo --- mkfifo.1.original.txt Fri Oct 19 08:27:33 2007 +++ mkfifo.1.new.txt Fri Oct 19 09:06:41 2007 @@ -11,7 +11,12 @@ SYNOPSIS /usr/bin/mkfifo [-m mode] path... + ksh93 + mkfifo [ options ] file ... + DESCRIPTION + /usr/bin/mkfifo + The mkfifo utility creates the FIFO special files named by its argument list. The arguments are taken sequentially, in the order specified; and each FIFO special file is either @@ -28,7 +33,13 @@ a=rw, modified by the current value of the file mode crea- tion mask umask(1). + ksh93 + + mkfifo creates one or more FIFO's. By default, the mode of + created FIFO is a=rw minus the bits set in the umask(1). + OPTIONS + /usr/bin/ksh93 The following option is supported: -m mode Sets the file permission bits of the newly-created @@ -38,6 +49,10 @@ strings, the op characters + and - will be inter- preted relative to an assumed initial mode of a=rw. + ksh93 + -m, --mode=mode Set the mode of created FIFO to mode. mode + is symbolic or octal mode as in chmod(1). Relative + modes assume an initial mode of a=rw. OPERANDS # Manpage diff for printf --- printf.1.original.txt Thu Nov 22 15:29:21 2007 +++ printf.1.new.txt Mon Dec 3 17:46:47 2007 @@ -17,16 +17,11 @@ DESCRIPTION /usr/bin/printf - The /usr/bin/printf command writes formatted operands to the standard - output. The _a_r_g_u_m_e_n_t operands are formatted under control of - the _f_o_r_m_a_t operand. - - ksh93 printf writes each string operand to standard output using format to control the output format. - The format operands supports the full range of ANSI C formatting specifiers - plus the following additional specifiers: + The format operands supports the full range of ANSI C/C99/XPG6 formatting + specifiers plus the following additional specifiers: %b Each character in the string operand is processed specially as follows: \a Alert character. @@ -69,7 +64,7 @@ will continue to be processed. In addition to the format specifier extensions, the following extensions of - ANSI-C are permitted in format specifiers: + ANSI C/C99/XPG6 are permitted in format specifiers: - The escape sequences \E and \e expand to the escape character which is octal 033 in ASCII. - The escape sequence \cx expands to Control-x. @@ -96,8 +91,8 @@ were supplied, numeric conversions will be treated as if 0 were supplied, and time conversions will be treated as if now were supplied. - printf is equivalent to print -f which allows additional options to be - specified. + /usr/bin/printf is equivalent to ksh93's "printf" built-in and print -f which + allows additional options to be specified. OPERANDS The following operands are supported for /usr/bin/printf: @@ -258,17 +253,12 @@ Notice that this printf utility, like the printf(3C) func- tion on which it is based, makes no special provision for dealing with multi-byte characters when using the %c conver- - sion specification or when a precision is specified in a %b - or %s conversion specification. Applications should be - extremely cautious using either of these features when there + sion specification. Applications should be extremely + cautious using either of these features when there are multi-byte characters in the character set. Field widths and precisions cannot be specified as *. - For compatibility with previous versions of SunOS 5._x, the $ - format specifier is supported for formats containing _o_n_l_y %s - specifiers. - The %b conversion specification is not part of the ISO C standard; it has been added here as a portable way to pro- cess backslash escapes expanded in string operands as pro- @@ -430,6 +420,106 @@ writes the value accumulated at the time the error was detected to standard output. + + Example 6: Alternative floating point representation 1: + The printf utility supports an alternative floating point representation + (see printf(3c) manual page's entry for the "%a"/"%A") which allows + the output of floating-point values in a format which avoids the the + usual base16 to base10 rounding errors. + + example% printf "%a\n" 2 3.1 NaN + + produces: + + 0x1.0000000000000000000000000000p+01 + 0x1.8ccccccccccccccccccccccccccdp+01 + nan + + + Example 7: Alternative floating point representation 2: + The following example shows two different representations of the + same floating-point value: + + example% x=2 ; printf "%f == %a\n" x x + + produces: + + 2.000000 == 0x1.0000000000000000000000000000p+01 + + + Example 8: Output of unicode values + The following command will print the EURO unicode symbol (code-point 0x20ac) + example% LC_ALL=en_US.UTF-8 printf "\u[20ac]\n" + + produces: + + + (where "" represents the EURO currency symbol character) + + + Example 9: Convert unicode character to unicode code-point value: + The following command will print the hexadecimal value of a given + character. + + example% export LC_ALL=en_US.UTF-8 + example% printf "%x\n" "'" + (where "" represents the EURO currency symbol character + (code-point 0x20ac)) + + produces: + + 20ac + + + Example 10: Print the numeric value of an ASCII character: + printf "%d\n" "'A" + + produces: + + 65 + + + Example 11: To print the language-independent date and time + format, the following statement could be used: + + printf "format" weekday month day hour min + (e.g. $ printf format "Sunday" "July" 3 10 2 + + For American usage, format could be the string: + + "%s, %s %d, %d:%.2d\n" + + producing the message: + + Sunday, July 3, 10:02 + + whereas for EU usage, format could be the string: + + "%1$s, %3$d. %2$s, %4$d:%5$.2d\n" + (note that the '$' charatcers must be propperly escaped, e.g. + "%1\$s, %3\$d. %2\$s, %4\$d:%5\$.2d\n" in this case) + + producing the message: + + Sunnday, 3. July, 10:02 + + +NOTES + Using format specifiers (characters following '%') which are not listed + in the printf(3c) or this manual page will result in undefined behaviour. + + Using escape sequences (the character following a backslash ('\')) which + are not listed in the printf(3c) or this manual page will result in + undefined behaviour. + + Floating-point values follow C99, XPG6 and IEEE 754 standard behaviour + and and can handle values the same way as the platform's |long double| + datatype. + + Floating-point values handle the sign seperately which allows signs + for values like NaN (i.e. -nan), Infinite (i.e. -inf) and zero + (i.e. -0.0). + ENVIRONMENT VARIABLES See environ(5) for descriptions of the following environment variables that affect the execution of printf: LANG, LC_ALL, # Manpage diff for read No differences encountered # Manpage diff for rev --- /dev/null Wed Feb 13 05:14:51 2008 +++ rev.1.new.txt Fri Nov 30 00:45:55 2007 @@ -1,0 +1,42 @@ +NAME + rev - reverse the characters or lines of one or more files + +SYNOPSIS + /usr/bin/rev [-l] [file ...] + + ksh93 + rev [-l] [file ...] + +DESCRIPTION + rev copies one or more files to standard output reversing the + order of characters on every line of the file or reversing + the order of lines of the file if -l is specified. + + If no file is given, or if the file is -, rev copies from + standard input starting at the current offset. + +OPTIONS + -l, --line Reverse the lines of the file. + +EXIT STATUS + 0 All files copied successfully. + >0 One or more files did not copy. + +ATTRIBUTES + See attributes(5) for descriptions of the following attri- + butes: + + /usr/bin/rev + ____________________________________________________________ + | ATTRIBUTE TYPE | ATTRIBUTE VALUE | + |_____________________________|_____________________________| + | Availability | SUNWcsu | + |_____________________________|_____________________________| + | CSI | Enabled | + |_____________________________|_____________________________| + | Interface Stability | Commited | + |_____________________________|_____________________________| + + +SEE ALSO + cat(1), tail(1) # Manpage diff for shcomp --- /dev/null Wed Feb 13 05:14:51 2008 +++ shcomp.1.new.txt Fri Nov 30 00:43:23 2007 @@ -1,0 +1,66 @@ +NAME + shcomp - compile a ksh93 shell script + +SYNOPSIS + shcomp [-nv] [infile [outfile]] + + shcomp -D [infile [outfile]] + +DESCRIPTION + Unless -D is specified, shcomp takes a shell script, infile, + and creates a binary format file, outfile, that ksh93 can read + and execute with the same effect as the original script. + + Since aliases are processed as the script is read, alias + definitions whose value requires variable expansion will not + work correctly. + + If -D is specifed, all double quoted strings that are preceded + by $ are printed, one literal per line, e.g. a literal $"foo" + will be printed as "foo" in the output + These are the messages that need to be translated to locale + specific versions for internationalization. + + If outfile is omitted, both modes will write their results + to standard output. If infile is also omitted, the + shell script will be read from standard input. + +OPTIONS + -D, --dictionary + Generate a list of strings that need to be + placed in a message catalog for + internationalization. + -n, --noexec Displays warning messages for obsolete or + non-conforming constructs. + -v, --verbose Displays input from infile onto standard error + as it reads it. + +EXIT STATUS + 0 Successful completion. + >0 An error occurred. + +ATTRIBUTES + See attributes(5) for descriptions of the following attri- + butes: + + /usr/bin/shcomp + ____________________________________________________________ + | ATTRIBUTE TYPE | ATTRIBUTE VALUE | + |_____________________________|_____________________________| + | Availability | SUNWcsu | + |_____________________________|_____________________________| + | CSI | Enabled | + |_____________________________|_____________________________| + | Interface Stability | See below | + |_____________________________|_____________________________| + + + The stability of the /usr/bin/shcomp command-line interface + and thesystem variables documented in shcomp(1) is "Committed"; + the compiled shell code format is "Committed Private" ("shcomp" + being the only generator of the format and /usr/bin/ksh93 the + only consumer; both share the same code via libshell) and + the output of the "-D" option is "Volatile". + +SEE ALSO + ksh93(1) # Manpage diff for sleep --- sleep.1.original.txt Thu Nov 22 17:21:44 2007 +++ sleep.1.new.txt Fri Nov 23 20:20:45 2007 @@ -9,7 +9,7 @@ sleep - suspend execution for an interval SYNOPSIS - /usr/bin/sleep _t_i_m_e + /usr/bin/sleep _seconds_ ksh93 sleep _seconds_ @@ -16,11 +16,6 @@ DESCRIPTION - /usr/bin/sleep - The sleep utility will suspend execution for at least the - integral number of seconds specified by the _t_i_m_e operand. - - ksh93 sleep suspends execution for at least the time specified by seconds or until a SIGALRM signal is received. seconds can be specifed as a floating point number but the actual granularity depends on the underlying system, normally @@ -28,10 +23,14 @@ OPERANDS - The following operands are supported for /usr/bin/sleep: + The following operands are supported for /usr/bin/sleep and ksh93's + "sleep" built-in command: - _t_i_m_e A non-negative decimal integer specifying the + _t_i_m_e A non-negative floating-point number specifying the number of seconds for which to suspend execution. + The floating-point number may be specified in all formats + required by C99/XPG6, including constants such as "Inf" or + "infinite". @@ -50,6 +49,20 @@ sleep 37 done + Example 2: Suspending command execution forever (or until a SIGALRM + signal is received): + + example% sleep Inf + + + Example 3: Suspending command execution for 0.5 seconds using + an alternative floating-point representation for the value "0.5": + + example% printf "%a\n" 0.5 + 0x1.0000000000000000000000000000p-01 + + example% sleep 0x1.0000000000000000000000000000p-01 + ENVIRONMENT VARIABLES See environ(5) for descriptions of the following environment variables that affect the execution of sleep: LANG, LC_ALL, @@ -121,9 +134,10 @@ The sleep utility will take the standard action for all other signals. + The behaviour for input values such as "NaN" (not-a-number) or negative + values is undefined. - # Manpage diff for sum --- sum.1.original.txt Fri Oct 19 03:49:51 2007 +++ sum.1.new.txt Fri Feb 15 07:27:37 2008 @@ -9,22 +9,186 @@ sum - print checksum and block count for a file SYNOPSIS - sum [-r] [file...] + /usr/bin/sum [-abBchHlLpPrRstTw] [-x method] [file...] + ksh93 + sum [-abBchHlLpPrRstTw] [-x method] [file...] + DESCRIPTION - The sum utility calculates and prints a 16-bit checksum for - the named file and the number of 512-byte blocks in the - file. It is typically used to look for bad spots, or to - validate a file communicated over some transmission line. + /usr/bin/sum + ksh93 "sum" + The sum command and ksh93 built-in command "sum" lists the + checksum, and for most methods the block count, for each file + argument. The standard input is read if there are no file + arguments. + getconf UNIVERSE determines the default + sum method: att for the att universe, bsd otherwise. The + default for the other commands is the command name itself. The + att method is a true sum, all others are order dependent. -OPTIONS - The following options are supported: + Method names consist of a leading identifier and 0 or more + options separated by -. - -r Use an alternate (machine-dependent) algorithm in - computing the checksum. + getconf PATH_RESOLVE determines how symbolic links are + handled. This can be explicitly overridden by the --logical, + --metaphysical, and --physical options below. PATH_RESOLVE can + be one of: + logical + Follow all symbolic links. + metaphysical + Follow command argument symbolic links, otherwise + don't follow. + physical + Don't follow symbolic links. +OPTIONS + The following options are supported by /usr/bin/sum + -a, --all List the checksum for all files. Use with + --total to list both individual and total + checksums and block counts. + -b, --binary Read files in binary mode. This is the + default. + -B, --scale=scale + Block count scale (bytes per block) override + for methods that include size in the output. + The default is method specific. + -c, --check Each file is interpreted as the output from a + previous sum. If --header or --permissions was + specified in the previous sum then the + checksum method is automatically determined, + otherwise --method must be specified. The + listed checksum is compared with the current + value and a warning is issued for each file + that does not match. If file was generated by + --permissions then the file mode, user and + group are also checked. Empty lines, lines + starting with #, or the line # are + ignored. Lines containing no blanks are + interpreted as [no]name[=value] options: + method=name + Checksum method to apply to subsequent + lines. + permissions + Subsequent lines were generated with + --permissions. + -h, --header Print the checksum method as the first output + line. Used with --check and --permissions. + -l, --list Each file is interpreted as a list of files, + one per line, that is checksummed. + -p, --permissions + If --check is not specified then list the file + mode, user and group between the checksum and + path. User and group matching the caller are + output as -. If --check is specified then the + mode, user and group for each path in file are + updated if necessary to match those in file. A + warning is printed on the standard error for + each changed file. + -R, --recursive Recursively checksum the contents of + directories. + -t, --total List only the total checksum and block count + of all files. --all --total lists each + checksum and the total. The total checksum and + block count may be different from the checksum + and block count of the catenation of all files + due to partial blocks that may occur when the + files are treated separately. + -T, --text Read files in text mode (i.e., treat \r\n as + \n). + -w, --warn Warn about invalid --check lines. On by + default; -w means --nowarn. + -x, --method|algorithm=method + Specifies the checksum method to apply. Parenthesized method options are readonly implementation + details. + att|sys5|s5|default + The system 5 release 4 checksum. This is the default for sum when getconf UNIVERSE is att. + This is the only true sum; all of the other methods are order dependent. + ast4|32x4|tw + The ast 128 bit PRNG hash generated by catenating 4 separate 32 bit PNRG hashes. The block + count is not printed. + bsd|ucb + The BSD checksum. + crc 32 bit CRC (cyclic redundancy check). + polynomial=mask + The 32 bit crc polynomial bitmask with implicit bit 32. The default value is + 0xedb88320. + done[=number] + XOR the final crc value with number. 0xffffffff is used if number is omitted. The + option value may be omitted. The default value is 0. + init[=number] + The initial crc value. 0xffffffff is used if number is omitted. The option value may + be omitted. The default value is 0. + rotate + XOR each input character with the high order crc byte (instead of the low order). + size[=number] + Include the total number of bytes in the crc. number, if specified, is first XOR'd + into the size. The option value may be omitted. The default value is 0. + prng 32 bit PRNG (pseudo random number generator) hash. + mpy=number + The 32 bit PRNG multiplier. The default value is 0x01000193. + add=number + The 32 bit PRNG addend. The default value is 0. + init[=number] + The PRNG initial value. 0xffffffff is used if number is omitted. The option value may + be omitted. The default value is 0x811c9dc5. + md4|MD4 + RFC1320 MD4 message digest. Cryptographically weak. The block count is not printed. + (version) + md4 (solaris -lmd) 2005-07-26 + md5|MD5 + RFC1321 MD5 message digest. Cryptographically weak. The block count is not printed. + (version) + md5 (solaris -lmd) 2005-07-26 + sha1|SHA1|sha-1|SHA-1 + RFC3174 / FIPS 180-1 SHA-1 secure hash algorithm 1. Cryptographically weak. The block count + is not printed. + (version) + sha1 (solaris -lmd) 2005-07-26 + sha256|sha-256|SHA256|SHA-256 + FIPS 180-2 SHA256 secure hash algorithm. The block count is not printed. + (version) + sha256 (solaris -lmd) 2005-07-26 + sha384|sha-384|SHA384|SHA-384 + FIPS 180-2 SHA384 secure hash algorithm. The block count is not printed. + (version) + sha384 (solaris -lmd) 2005-07-26 + sha512|sha-512|SHA512|SHA-512 + FIPS 180-2 SHA512 secure hash algorithm. The block count is not printed. + (version) + sha512 (solaris -lmd) 2005-07-26 + posix|cksum|std|standard + The posix 1003.2-1992 32 bit crc checksum. This is the default cksum(1) method. Shorthand for + crc-0x04c11db7-rotate-done-size. + zip The zip(1) crc. Shorthand for crc-0xedb88320-init-done. + fddi The FDDI crc. Shorthand for crc-0xedb88320-size=0xcc55cc55. + fnv|fnv1 + The Fowler-Noll-Vo 32 bit PRNG hash with non-zero initializer (FNV-1). Shorthand for + prng-0x01000193-init=0x811c9dc5. + ast|strsum + The ast strsum(3) PRNG hash. Shorthand for prng-0x63c63cd9-add=0x9c39c33d. + -L, --logical|follow + Follow symbolic links when traversing + directories. The default is determined by + getconf PATH_RESOLVE. + -H, --metaphysical + Follow command argument symbolic links, + otherwise don't follow symbolic links when + traversing directories. The default is + determined by getconf PATH_RESOLVE. + -P, --physical Don't follow symbolic links when traversing + directories. The default is determined by + getconf PATH_RESOLVE. + -r, --bsd Equivalent to --method=bsd --scale=512 for + compatibility with other sum(1) + implementations. + -s, --sysv Equivalent ti --method=sys5 for for + compatibility with other sum(1) + implementations. + -S, --silent|status + No output for --check; 0 exit status means all + sums matched, non-0 means at least one sum + failed to match. Ignored for --permissions. - OPERANDS The following operands are supported: @@ -32,7 +196,6 @@ standard input is used. - USAGE See largefile(5) for the description of the behavior of sum when encountering files greater than or equal to 2 Gbyte ( 2 @@ -73,14 +236,16 @@ ____________________________________________________________ | ATTRIBUTE TYPE | ATTRIBUTE VALUE | + |_____________________________|_____________________________| | Availability | SUNWesu | + |_____________________________|_____________________________| | CSI | enabled | |_____________________________|_____________________________| SEE ALSO - cksum(1), sum(1B), wc(1), attributes(5), environ(5), large- - file(5) + cksum(1), ksh93(1), sum(1B), wc(1), libmd(3lib), attributes(5), + environ(5), largefile(5) DIAGNOSTICS "Read error" is indistinguishable from end of file on most @@ -87,7 +252,9 @@ devices; check the block count. NOTES - Portable applications should use cksum(1). + Portable applications should use cksum(1), the default algorithm + for this command is defined in the POSIX standard and identical + across platforms. sum and usr/ucb/sum (see sum(1B)) return different check- sums. # Manpage diff for test --- test.1.original.txt Thu Nov 22 15:28:36 2007 +++ test.1.new.txt Fri Nov 23 20:19:14 2007 @@ -323,9 +323,11 @@ - _n_1 -eq _n_2 True if the integers _n_1 and _n_2 are + _n_1 -eq _n_2 True if the numbers _n_1 and _n_2 are algebraically equal. - (ksh93 also supports floating point numbers.) + A "number" may be integer, floating point or floating-point + constant (such as [+/-]Inf, [+/-]NaN) in any format specified + by C99/XPG6/SUS. @@ -341,34 +343,43 @@ - _n_1 -ne _n_2 True if the integers _n_1 and _n_2 are + _n_1 -ne _n_2 True if the numbers _n_1 and _n_2 are not algebraically equal. - (ksh93 also supports floating point numbers.) + A "number" may be integer, floating point or floating-point + constant (such as [+/-]Inf, [+/-]NaN) in any format specified + by C99/XPG6/SUS. - _n_1 -gt _n_2 True if the integer _n_1 is algebrai- - cally greater than the integer _n_2. - (ksh93 also supports floating point numbers.) + _n_1 -gt _n_2 True if the number _n_1 is algebrai- + cally greater than the number _n_2. + A "number" may be integer, floating point or floating-point + constant (such as [+/-]Inf, [+/-]NaN) in any format specified + by C99/XPG6/SUS. - _n_1 -ge _n_2 True if the integer _n_1 is algebrai- + _n_1 -ge _n_2 True if the number _n_1 is algebrai- cally greater than or equal to the - integer _n_2. - (ksh93 also supports floating point numbers.) + number _n_2. + A "number" may be integer, floating point or floating-point + constant (such as [+/-]Inf, [+/-]NaN) in any format specified + by C99/XPG6/SUS. + _n_1 -lt _n_2 True if the number _n_1 is algebrai- + cally less than the number _n_2. + A "number" may be integer, floating point or floating-point + constant (such as [+/-]Inf, [+/-]NaN) in any format specified + by C99/XPG6/SUS. - _n_1 -lt _n_2 True if the integer _n_1 is algebrai- - cally less than the integer _n_2. - (ksh93 also supports floating point numbers.) - - _n_1 -le _n_2 True if the integer _n_1 is algebrai- + _n_1 -le _n_2 True if the number _n_1 is algebrai- cally less than or equal to the - integer _n_2. - (ksh93 also supports floating point numbers.) + number _n_2. + A "number" may be integer, floating point or floating-point + constant (such as [+/-]Inf, [+/-]NaN) in any format specified + by C99/XPG6/SUS. @@ -714,8 +725,8 @@ endif - ksh - Example 5: Using the ksh built-in + ksh/ksh93 + Example 5: Using the ksh/ksh93 built-in ZERO=0 ONE=1 TWO=$((ONE+ONE)) ROOT=root if ((ONE > ZERO)) # _a_r_i_t_h_m_e_t_i_c_a_l _c_o_m_p_a_r_i_s_o_n @@ -822,13 +833,22 @@ sition aid for BSD applications and may not be supported in future releases. - When comparing file timestamps, the ksh93 test built-in - handles high-resolution timestamps of up to nanosecond - granularity, for filesystems which support them. + When comparing file timestamps, the /usr/bin/test and the + ksh93 test built-in handle high-resolution timestamps of up + to nanosecond granularity, for filesystems which support them. + XPG4/sh, ksh, ksh93: Is is recommended to use arithmetric + expressions (e.g. $(( x > 3.1 )) # instead of + $ /usr/bin/test "$x" -gt 3.1 # ) when comparing two floating-point + variables or a constant and a floating-point variable to prevent + rounding errors (caused by the base16 to base10 transformation) to + affect the result. Additionally the built-in arithmetric support + in XPG4/sh, ksh and ksh93 is significantly faster because it + doesn't require the explicit transformation to strings for each + comparisation. + - # Manpage diff for tty --- tty.1.original.txt Fri Oct 19 08:25:13 2007 +++ tty.1.new.txt Fri Nov 23 20:20:14 2007 @@ -9,15 +9,28 @@ tty - return user's terminal name SYNOPSIS - tty [-l] [-s] + /usr/bin/tty [-l] [-s] + ksh93 + tty [ options ] + DESCRIPTION + /usr/bin/tty + The tty utility writes to the standard output the name of the terminal that is open as standard input. The name that is used is equivalent to the string that would be returned by the ttyname(3C) function. + ksh93 + + The ksh93 tty built-in writes the name of the terminal that + is connected to standard input onto standard output. If the + standard input is not a terminal, "not a tty" will be written + to standard output. + OPTIONS + /usr/bin/tty The following options are supported: -l Prints the synchronous line number to which the @@ -29,8 +42,16 @@ -s Inhibits printing of the terminal path name, allow- ing one to test just the exit status. + ksh93 + -l, --line-number + Write the synchronous line number of the terminal + on a separate line following the terminal name line. + If the standard input is not a synchronous terminal + then "not on an active synchronous line" is written. + -s, --silent|quiet + Disable the terminal name line. + Portable applications should use [[ -t 0 ]] instead. - ENVIRONMENT VARIABLES See environ(5) for descriptions of the following environment variables that affect the execution of tty: LANG, LC_ALL,