home *** CD-ROM | disk | FTP | other *** search
- #*************************************************************************
- #
- # Set up variables and flags
- #
- #*************************************************************************
-
- options +lEeFs
-
- PS1 = '$_ANSI_P3[$PWD]: $_ANSI_P1'
- PS2 = '$_ANSI_P3> $_ANSI_P1'
- PNPC = 21
- LOGOUT = 'echo "\nBye!\n"'
-
- _ANSI_BS = "^[[1m"
- _ANSI_BE = "^[[m"
- _ANSI_P1 = "^[[0;31;40m"
- _ANSI_P2 = "^[[0;32;40m"
- _ANSI_P3 = "^[[0;33;40m"
- _ANSI_CLEAR = "^[[H^[[2J"
-
-
- #*************************************************************************
- #
- # Set up ash aliases
- #
- #*************************************************************************
-
- alias unalias = 'unset -a'
- alias unfunc = 'unset -f'
- alias aliases = 'set -a'
- alias functions = 'set -f'
- alias variables = 'set -v'
- alias builtins = 'set -b'
- alias help = 'set -bfa'
- alias logout = 'exit 0'
- alias makedir = 'mkdir'
- alias delete = 'rm'
- alias remove = 'rm'
- alias pwd = 'echo "$PWD"'
- alias clear = 'echo -n $_ANSI_CLEAR'
- alias cls = 'echo -n $_ANSI_CLEAR'
- alias '!' = 'history -e'
- alias '!!' = 'history -e -1'
- alias ll = 'ls -lb'
- alias dir = 'ls -b'
- alias ctpri = 'ChangeTaskPri'
- alias . = 'source'
-
-
- #*************************************************************************
- #
- # Set up ash functions
- #
- #*************************************************************************
-
- function path { # set or examine path
-
- local component;
-
- if [ $# -eq 0 ]
- then
- echo "$PATH";
- elif [ "$1" = "-add" -o "$1" = "add" ]
- then
- shift
- for component in $* do
-
- if [ $( expr index "$PATH," "$component," ) -eq 0 ]
- then
- PATH = "$PATH,$component"
- fi
-
- done
- else
- PATH = "$1"
- fi
-
- export PATH
- }
-
- function stack { # set or change stack size
-
- if [ $# -eq 0 ]
- then
- c:stack
- return
- fi
-
- if [ $1 -lt 4000 -o $1 -gt 128000 ]
- then
- echo "Invalid stack size. Use 4000 to 128000"
- return
- fi
-
- c:stack $(expr $1 + 12000)
- }
-