diff rc/bash @ 296:7251d4f5e5c9

Ensure we have less.
author Edho Arief <edho@myconan.net>
date Sun, 15 Jan 2012 08:42:56 +0700
parents 5fbe9461efea
children 73981a7539dd 81bfcb3015bd
line wrap: on
line diff
--- a/rc/bash	Thu Jan 12 10:43:27 2012 +0300
+++ b/rc/bash	Sun Jan 15 08:42:56 2012 +0700
@@ -21,13 +21,12 @@
 export HISTFILESIZE=10000
 export HISTCONTROL=ignoredups
 
-export PAGER="less -Rins"
+export PAGER=more
 export EDITOR=vi
 export LANG="en_US.UTF-8"
 export CLICOLOR=
 export LSCOLORS=ExGxFxdxCxegedabagExEx
 
-alias less="less -Rins"
 alias ls="ls -F"
 alias rm="rm -i"
 alias rd="rdesktop -g 1280x600 -K -a 15 -x m -z -P -r sound:off -r clipboard:CLIPBOARD -5"
@@ -167,6 +166,11 @@
   export EDITOR=vim
 fi
 
+if command -v less > /dev/null 2>&1; then
+  alias less="less -Rins"
+  export PAGER="less -Rins"
+fi
+
 rm -If "/tmp/.nonexistent.$(date '+%Y%m%d%H%M%S')" 2> /dev/null && alias rm="rm -I"
 
 [ -f "${HOME}/.ecos_bash.after" ] && . "${HOME}/.ecos_bash.after"