lesspipe.sh is an input filter for the pager less as described in less's man page. The script runs under a ksh-compatible shell (ksh, bash, zsh) and allows you to use less to view files with binary content, compressed files, archives, and files contained in archives. Viewing files by accessing a device file is implemented to some extent (DOS filesystems and tar files). It supports many formats (both as plain and compressed files using compress, gzip, bzip2, or zip). Syntax highlighting for many languages is available through a helper script, "code2color".
| Tags | Text Processing |
|---|---|
| Licenses | GPL |
| Operating Systems | POSIX |
| Implementation | Unix Shell |
Recent releases


Changes: A major restructuring of the lesspipe code took place. Support for even more file types has been added (e.g. jar and lzip). The test suite was enhanced, several bugs were fixed, and the code was cleaned up. The documentation has been updated.


Changes: lesspipe now comes with improved UTF-8 support. It will automatically convert the display between UTF-8 and ISO-8859-1 charsets, depending on the LANG environment variable. The handling of 7-zip files has been improved and lzma compressed files are now recognized. The documentation and code has been cleaned up and minor bugs have been corrected.


Changes: lesspipe now displays human-readable information for even more file types. Support for viewing gpg encrypted files and binary plist files (MacOS X) has been included. For HTML display, the program links is now preferred over lynx, and mp3 file information can be viewed using id3v2. The configure script now correctly works with the most recent file command. Several other minor corrections have been made as well.


Changes: lesspipe now includes support for viewing the contents of rar and 7-zip archives and to display an ASCII representation of the contents of Openoffice documents. For images (PNG, GIF, JPEG, and other formats), the file's format and characteristics are shown. Debian packages can now be viewed without installing dpkg. Various small bugfixes and optimizations were done. The documentation and the test suite have been enhanced.


Changes: Minor bugs were fixed. lesspipe.sh was hanging on AIX systems. An archive file named "bzip2.tar.gz" was misinterpreted as a bz2 file.