Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

general updates

updated the readme with a feature I forgot
dump stupid old aliases
make rc controll stuff less stupid
  • Loading branch information...
commit aeede835486f49690c8c36576075804c08c4e9dc 1 parent 20a6196
@riddley authored
Showing with 36 additions and 18 deletions.
  1. +0 −4 .bash/aliases
  2. +35 −14 .bash/func
  3. +1 −0  README
View
4 .bash/aliases
@@ -33,7 +33,6 @@ alias vless='vim -u /usr/share/vim/vim71/macros/less.vim'
alias ssh='ssh -AX'
alias sagent='exec ssh-agent $SHELL -c "ssh-add; exec $SHELL"'
alias 8='cd /home/psycho/public_html/trunk'
-alias xfb='xfer_bash $BASH_HOSTS'
alias x='chmod +x'
alias ,='cd $dot'
alias untar='tar xvzf'
@@ -58,8 +57,6 @@ if [[ "${__SAMOS}" = "Linux" ]] ; then
alias m='mplayer -vo xv -ao oss'
alias dvd='m -cache 65535 dvd://'
alias jack='jack -Q'
- alias getxcvs='CVS_RSH=ssh ; export CVS_RSH; cvs -d anoncvs@anoncvs.xfree86.org:/cvs checkout xc'
- alias updatexcvs='CVS_RSH=ssh ; export CVS_RSH; cvs -d anoncvs@anoncvs.xfree86.org:/cvs update xc'
alias mpg123='mpg123 -b 2048'
alias logs='cd /www/sam/logs/'
alias ls='ls -Fh --color=auto'
@@ -80,7 +77,6 @@ alias rcslocks='rlog -L -R RCS/*,v 2>/dev/null;rlog -L -R *,v 2>/dev/null'
alias ,='cd -'
alias .='source'
alias ...='. ${HOME}/.bashrc'
-alias _=combine
alias @="cd \$whoneedspushd"
alias a='alias'
alias alais='alias'
View
49 .bash/func
@@ -38,6 +38,34 @@ if [[ "${__SAMOS}" = "Linux" ]] ; then
mv "$@" $dir;
( cd $dir && rm -rf Packages.gz && dpkg-scanpackages . /dev/null >Packages && gzip Packages )
}
+else
+
+ _storooni ()
+ {
+ local cur="${COMP_WORDS[COMP_CWORD]}"
+ local prev="${COMP_WORDS[COMP_CWORD-1]}"
+ local cmds="-h -n check listignores report stats"
+ local reportopts="-o -s -h -N"
+ local checkopts="-d -h"
+ local onlys="capacity errors hbas inqdevs metadbs metas vgs"
+ COMPREPLY=()
+ case $prev in
+ *-o*)
+ COMPREPLY=( $(compgen -W "${onlys}" -- ${cur}) )
+ ;;
+ check)
+ COMPREPLY=( $(compgen -W "${checkopts}" -- ${cur}) )
+ ;;
+ report)
+ COMPREPLY=( $(compgen -W "${reportopts}" -- ${cur}) )
+ ;;
+ storooni)
+ COMPREPLY=( $(compgen -W "${cmds}" -- ${cur}) )
+ ;;
+ esac
+ }
+ complete -F _storooni storooni
+
fi
function todot () { echo ${*%%.*}; };
function @@ () { export whoneedspushd=$PWD; };
@@ -127,16 +155,8 @@ function .bpt () { cd ~/.bashprompt/bashthemes/${1} ; };
function RCCT () {
if [[ -z "${2}" ]] ; then
ls $INITDIR;
- elif [[ "${1}" = "Start" ]] ; then
- cd / && $INITDIR/${2} start ; cd -;
- elif [[ "${1}" = "Restart" ]] ; then
- cd / && $INITDIR/${2} restart ; cd -;
- elif [[ "${1}" = "Stop" ]] ; then
- cd / && $INITDIR/${2} stop ; cd -;
- elif [[ "${1}" = "Reload" ]] ; then
- cd / && $INITDIR/${2} reload ; cd -;
else
- echo "Something bad happened.";
+ cd / && $INITDIR/${2} $1 ; cd -;
fi
}
@@ -147,11 +167,12 @@ function _myservices() {
COMPREPLY=( $( compgen -W '${COMPREPLY[@]#@($INITDIR)/}' -- $cur) )
}
-function Start () { RCCT ${FUNCNAME} ${*} ; };
-function Restart () { RCCT ${FUNCNAME} ${*} ; };
-function Reload () { RCCT ${FUNCNAME} ${*} ; };
-function Stop () { RCCT ${FUNCNAME} ${*} ; };
-complete -F _myservices Start Restart Reload Stop
+function start () { RCCT ${FUNCNAME} ${*} ; };
+function restart () { RCCT ${FUNCNAME} ${*} ; };
+function reload () { RCCT ${FUNCNAME} ${*} ; };
+function stop () { RCCT ${FUNCNAME} ${*} ; };
+function status () { RCCT ${FUNCNAME} ${*} ; };
+complete -F _myservices start restart reload stop status
# End RC stuff
function tree()
View
1  README
@@ -13,3 +13,4 @@ Highlights:
* prompt indicates if ssh-agent is available to this shell
* prompt changes color when root
* su'ing to root maintains history and $HOME etc.
+* screen windows are automatically named the short-hostname
Please sign in to comment.
Something went wrong with that request. Please try again.