Utility scripts

hcat: Print HTML

A simple script for embedding HTML content - just pipe to to stdin:

echo 'E = mc<sup>2</sup>' | hcat

displays: E = mc2.

imgcat: Send an image file to DomTerm

This script “prints” the contents of the named image file to domterm. This uses a “data:” URI with the file contents sent directly to domterm, so it works when working remotely.

imgcat [-n] [--attrname=attrvalue]... filename

The filename must be a file that can be displayed by an HTML <img> element, most commonly a png or jpg file.

-n

Do not append a newline.

--attrname=attrvalue

Specify the given attribute; for example: --height=200. Valid attrnames are the following, which are specified in the HTML specification: alt, longdesc, height, width, border, hspace, vspace, class.