dots

Personal dotfiles
git clone git://git.gormless.xyz/dots.git
Log | Files | Refs

fmt.1 (1555B)


      1 .TH FMT 1
      2 .SH NAME
      3 fmt, htmlfmt \- simple text formatters
      4 .SH SYNOPSIS
      5 .B fmt
      6 [
      7 .I option ...
      8 ]
      9 [
     10 .I file ...
     11 ]
     12 .PP
     13 .B htmlfmt
     14 [
     15 .B -a
     16 ] [
     17 .B -c
     18 .I charset
     19 ] [
     20 .B -u
     21 .I url
     22 ] [
     23 .I file ...
     24 ]
     25 .SH DESCRIPTION
     26 .I Fmt
     27 copies the given
     28 .I files
     29 (standard input by default)
     30 to its standard output, filling and indenting lines.
     31 The options are
     32 .TP
     33 .BI -l " n
     34 Output line length is
     35 .IR n ,
     36 including indent (default 70).
     37 .TP
     38 .BI -w " n
     39 A synonym for
     40 .BR -l .
     41 .TP
     42 .BI -i " n
     43 Indent
     44 .I n
     45 spaces (default 0).
     46 .TP
     47 .BI -j
     48 Do not join short lines: only fold long lines.
     49 .PP
     50 Empty lines and initial white space in input lines are preserved.
     51 Empty lines are inserted between input files.
     52 .PP
     53 .I Fmt
     54 is idempotent: it leaves already formatted text unchanged.
     55 .PP
     56 .I Htmlfmt
     57 performs a similar service, but accepts as input text formatted with
     58 HTML tags.
     59 It accepts
     60 .IR fmt 's
     61 .B -l
     62 and
     63 .B -w
     64 flags and also:
     65 .TP
     66 .BI -a
     67 Normally
     68 .I htmlfmt
     69 suppresses the contents of form fields and anchors (URLs and image files); this flag
     70 causes it to print them, in square brackets.
     71 .TP
     72 .BI -c " charset
     73 change the default character set from iso-8859-1 to
     74 .IR charset .
     75 This is the character set assumed if there isn't one
     76 specified by the html itself in a <meta> directive.
     77 .TP
     78 .BI -u " url
     79 Use
     80 .I url
     81 as the base URL for the document when displaying anchors; sets
     82 .BI -a .
     83 .SH SOURCE
     84 .B \*9/src/cmd/fmt.c
     85 .PP
     86 .B \*9/src/cmd/htmlfmt
     87 .SH BUGS
     88 .I Htmlfmt
     89 makes no attempt to render the two-dimensional geometry of tables;
     90 it just treats the table entries as plain, to-be-formatted text.