zsh-workers
 help / color / mirror / code / Atom feed
999c412a1b202e12c22794421912faa13537dca1 blob 1577 bytes (raw)

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
 
#compdef numfmt gnumfmt

local units="((auto\:1K\ =\ 1000,\ 1Ki\ =\ 1024 si\:1K\ =\ 1000 iec\:1K\ =\ 1024 iec-i\:1Ki\ =\ 1024))"

_arguments -S \
  '(H)--debug[print warnings about invalid input]' \
  '(H -z --zero-terminated -d --delimiter)'{-d+,--delimiter=}'[use specified field delimiter instead of whitespace]:delimiter' \
  '(H)--field=[replace numbers in specified input fields]:fields [1]' \
  '(H)--format=[use printf style floating-point format]:format' \
  "(H)--from=[auto-scale input numbers to specified units]:unit [none]:$units" \
  '(H)--from-unit=[specify the input unit size]:unit size [1]' \
  '(H)--grouping[use locale-defined digit grouping e.g. 1,000,000]' \
  '(H)--header=-[print (without converting) initial header lines]::header lines [1]' \
  '(H)--invalid=[specify failure mode for invalid numbers]:mode [abort]:(abort fail warn ignore)' \
  '(H)--padding=[pad the output to specified width]:width; positive - right-align; negative - left-align' \
  '(H)--round=[use specified method for rounding when scaling]:method [from-zero]:(up down from-zero towards-zero nearest)' \
  '(H)--suffix=[add suffix to output numbers and accept optional suffix in input numbers]:suffix' \
  "(H)--to=[auto-scale output numbers to specified unit]:unit:$units" \
  '(H)--to-unit=[specify output unit size]:unit size [1]' \
  '(H -z --zero-terminated -d --delimiter)'{-z,--zero-terminated}'[line delimiter is NUL, not newline]' \
  '(H)*: :_guard "^-*" number' \
  + 'H' \
  '(- *)--help[display usage information]' \
  '(- *)--version[display version information]'
debug log:

solving 999c412a1 ...
found 999c412a1 in https://git.vuxu.org/mirror/zsh/

Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).