logo
Free, unlimited AI code reviews that run on commit
git-lrc git-lrc GitHub Install Now We'd appreciate a star git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt

fmt, htmlfmt - simple text formatters

Bugs

Htmlfmt  makes  no  attempt  to  render  the two-dimensional geometry of tables; it just treats the table
       entries as plain, to-be-formatted text.

                                                                                                     FMT(1plan9)

Description

Fmt  copies  the  given  files  (standard input by default) to its standard output, filling and indenting
       lines.  The options are

       -ln   Output line length is n, including indent (default 70).

       -wn   A synonym for -l.

       -in   Indent n spaces (default 0).

       -j     Do not join short lines: only fold long lines.

       Empty lines and initial white space in input lines are preserved.  Empty lines are inserted between input
       files.

       Fmt is idempotent: it leaves already formatted text unchanged.

       Htmlfmt performs a similar service, but accepts as input text formatted with HTML tags.  It accepts fmt's
       -l and -w flags and also:

       -a     Normally htmlfmt suppresses the contents of form fields and anchors (URLs and image  files);  this
              flag causes it to print them, in square brackets.

       -ccharset
              change the default character set from iso-8859-1 to charset.  This is the character set assumed if
              there isn't one specified by the html itself in a <meta> directive.

       -uurl Use url as the base URL for the document when displaying anchors; sets -a.

Name

       fmt, htmlfmt - simple text formatters

Source

/src/cmd/fmt.c/src/cmd/htmlfmt

Synopsis

fmt [ option...  ] [ file...  ]

       htmlfmt [ -a ] [ -ccharset ] [ -uurl ] [ file...  ]

See Also