id = "gnu-units" name = "GNU Units" homepage = "https://www.gnu.org/software/units/" description = "A unit conversion program and calculator" executables = ["units", "units_cur"] [dotfiles] # The official GNU Units manual documents ~/.units as the optional personal # units data file. The interactive history file is machine-local and excluded. # https://www.gnu.org/software/units/manual/html_node/Data-Files.html # https://www.gnu.org/software/units/manual/units.html paths = ["~/.units"] exclude = ["~/.units_history"] secret = [] [commands] format = 1 label = "Convert units" description = "Convert one unit expression to another. Data files, locale, unit lists and interactive history options are left out." quality = "ai-draft" parser = { end_of_options = "--", interleave = "permute", long_equals = false, short_attached = false, short_bundles = true } [[commands.source]] id = "man" kind = "manual" url = "https://manpages.debian.org/bookworm/units/units.1.en.html" revision = "bookworm" evidence = """ -d ndigits, --digits ndigits -e, --exponential -1, --one-line -t, --terse -q, --quiet, --silent -s, --strict -v, --verbose """ [[commands.field]] id = "from" label = "From" description = "Unit expression to convert, for example 5 miles." type = "string" position = 0 sources = ["man"] [[commands.field]] id = "to" label = "To" description = "Target unit. Leave empty to see the reduced form." type = "string" position = 1 sources = ["man"] [[commands.field]] id = "digits" label = "Significant digits" type = "integer" option = ["--digits", "-d"] sources = ["man"] [[commands.field]] id = "exponential" label = "Exponential output" type = "boolean" option = ["--exponential", "-e"] sources = ["man"] [[commands.field]] id = "one_line" label = "One line" description = "Print only the forward conversion." type = "boolean" option = ["--one-line", "-1"] sources = ["man"] [[commands.field]] id = "terse" label = "Terse" description = "Print only a single conversion factor." type = "boolean" option = ["--terse", "-t"] sources = ["man"] [[commands.field]] id = "strict" label = "Strict" type = "boolean" option = ["--strict", "-s"] sources = ["man"] [[commands.field]] id = "verbose" label = "Verbose" type = "boolean" option = ["--verbose", "-v"] sources = ["man"] [[commands.task]] id = "convert" label = "Convert" fields = ["from", "to", "digits"] required = ["from", "to"] [[commands.task]] id = "factor" label = "Conversion factor only" set = { terse = [true] } lock = ["terse"] fields = ["from", "to", "terse"] required = ["from", "to"] [[commands.group]] id = "basic" label = "Basic" fields = ["from", "to", "digits", "terse"] [[commands.group]] id = "advanced" label = "Advanced" fields = ["exponential", "one_line", "strict", "verbose"]