text2html
text2html [-t] [file]
text2html
reads input from stdin.
Without flag "-t
", text2html
converts only three characters '&
', '<
' and '>
' to '&
', '<
' and '>
' respectively. Thus spaces are untouched and thereby contiguous spaces are visible as single space; line breaks are also ignored.
With the flag, the converted text will be shown on browser screen much faithfully.
The first space code in contiguous spaces is untouched but spaces that follows are converted to ' 
'. Thus contiguous spaces is visible as it is. Contiguous empty lines are visible as it is.
term% cat b three spaces " " three lines follows text end here. term% text2html b three spaces " " three lines follows text end here. term% text2html -t b <p>three spaces " "</p> <p>three lines follows</p> <br> <br> <br> <p>text end here.</p>
http://plan9.aichi-u.ac.jp/netlib/cgitools/