I would need to print the contents of a file (e.g.,
cat $file), but wrap output at a given column width (let's say 80 cols), independently of terminal width.
Is there something in the "standard" Unix arsenal that would give me this functionality?
The basic tool for doing this is fold(1). For example,
will fold the lines in $file to fit within 80 columns and break lines at spaces.