mirror of
https://github.com/ohmybash/oh-my-bash.git
synced 2024-05-11 05:55:37 +00:00
Merge pull request #288 from stroggoslav/fix-lesspipe
Fix exporting LESSOPEN
This commit is contained in:
@ -3,7 +3,17 @@
|
||||
# see /usr/share/doc/bash/examples/startup-files (in the package bash-doc)
|
||||
|
||||
# make less more friendly for non-text input files, see lesspipe(1)
|
||||
[ -x /usr/bin/lesspipe ] && eval "$(SHELL=/bin/sh lesspipe)"
|
||||
if [ -z "${LESSOPEN}" ];then
|
||||
if [ -f /etc/gentoo-release ]; then
|
||||
export LESSOPEN="|lesspipe %s"
|
||||
else
|
||||
if [ -x /usr/bin/lesspipe ]; then
|
||||
eval "$(SHELL=/bin/sh /usr/bin/lesspipe)"
|
||||
elif [ -x /usr/bin/lesspipe.sh ]; then
|
||||
eval "$(SHELL=/bin/sh /usr/bin/lesspipe.sh)"
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
|
||||
# set variable identifying the chroot you work in (used in the prompt below)
|
||||
if [ -z "${debian_chroot:-}" ] && [ -r /etc/debian_chroot ]; then
|
||||
|
Reference in New Issue
Block a user