OpenSUSE 12.2: Install package lesspipe and using it from bash
Posted by jpluimers on 2014/03/07
lesspipe is a great tool:
lesspipe.sh is an input filter for the pager less as described in less‘s man page. The script allows you to view files with binary content, compressed files, archives and files contained in archives.
… however getting it to run on OpenSUSE was a bit of a journey as it is not part of the standard OpenSUSE 12.x repository. You can only get ‘unstable’ lesspipe packages, of which the Show home:adra / lesspipe – openSUSE Build Service seems to be maintained most frequently.
This is how to install it from there:
zypper addrepo http://download.opensuse.org/repositories/home:adra/openSUSE_Factory/home:adra.repo
zypper install lesspipe
LESSOPEN="|lesspipe.sh %s"; export LESSOPEN
You can-reapply your
~/.bashrc, but note that it can give issues when appending existing environment variables like PATH. From
Use the source command (or the dot shortcut
.) which – depending if your
.bashrc is in the current directory, can be any of these: