From 50a5960367ebec71041a8d27f9b053e7b838470e Mon Sep 17 00:00:00 2001 From: Alexander Sulfrian Date: Thu, 5 Feb 2009 12:58:04 +0100 Subject: alias nano to pico if only pico is available --- bashrc/common/alias.sh | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'bashrc/common') diff --git a/bashrc/common/alias.sh b/bashrc/common/alias.sh index a915ec3..d21cc87 100644 --- a/bashrc/common/alias.sh +++ b/bashrc/common/alias.sh @@ -13,6 +13,13 @@ alias ....="cd ../../.." # make default what should be default alias sudo="sudo -H" +# some distibutions (e.g. SuSE) has no nano but pico +if ! hash nano > /dev/null 2>&1 ; then + if hash pico > /dev/null 2>&1 ; then + alias nano="pico" + fi +fi + # mkdir + chdir mkcd() { mkdir -p $1 && cd $1 -- cgit v1.2.3