4a3b87e295
Changes to units.1: - Change the description to a more descriptive "conversion calculator". - Sort options. - Split the description into sections to make it easier to navigate the manual page. - Improve the description of various options. - Document the default value of the output format. - Use more mdoc macros for better readability. - Document the behavior of the PATH environmental variable. - Improve examples. - Add sections: EXIT STATUS, DIAGNOSTICS, and HISTORY. - Document that units(1) cannot convert negative values and it handles long unit lists poorly. - Update the documentation of the -V flag to match the implementation. units(1) prints its version and the units data file instead of its version and usage information. Changes to units.c: - Update usage information. - Sort longopts elements. This commit does not attempts to change the current behavior of units(1). What's left to do is probably defining a better versioning (at the moment units(1) always reports "FreeBSD units" as its version) and changing the behavior of the -V flag to only print version. Reviewed by: allanjude (earlier version), bcr Approved by: bcr (mentor) Differential Revision: https://reviews.freebsd.org/D18977 |
||
---|---|---|
.. | ||
tests | ||
definitions.units | ||
Makefile | ||
Makefile.depend | ||
README | ||
units.1 | ||
units.c |
# $FreeBSD$ This is a program which I wrote as a clone of the UNIX 'units' command. I threw it together in a couple days, but it seems to work, with some restrictions. I have tested it under DOS with Borland C and Ultrix 4.2, and SunOS 4.1. This program differs from the unix units program in the following ways: it can gracefully handle exponents larger than 9 in output it uses 'e' to denote exponentiation in numbers prefixes are listed in the units file it tries both -s and -es plurals it allows use of * for multiply and ^ for exponentiation in the input the output format is somewhat different Adrian Mariano (adrian@cam.cornell.edu or mariano@geom.umn.edu)