diff options
Diffstat (limited to 'linux/bin/neo')
| -rwxr-xr-x | linux/bin/neo | 19 | 
1 files changed, 19 insertions, 0 deletions
| diff --git a/linux/bin/neo b/linux/bin/neo index 902bd04..96c5b42 100755 --- a/linux/bin/neo +++ b/linux/bin/neo @@ -1,5 +1,24 @@  #!/bin/sh +# colour definitions +normal="\033[0m" +red="\033[31m" +orange="\033[33m" +green="\033[32m" + +if [ "foo`echo -e bar`" = "foobar" ];then +  # GNU echo +  ECHO_e="echo -e" +else +  # POSIX echo +  ECHO_e="echo" +fi + +die() { +	$ECHO_e "${red}$@${normal}" >&2 +	exit 1 +} +  if [ -f "${NEO_CONFIG}" ]; then  	. "${NEO_CONFIG}" || die "Failed to source ${NEO_CONFIG}"  elif [ -f "${HOME}"/.neorc ]; then | 
