diff --git a/bash/fun b/bash/fun index de9dfdf..7a8d772 100644 --- a/bash/fun +++ b/bash/fun @@ -17,4 +17,4 @@ function pika { imgcat $IMAGE echo; } -alias pikabox='while true; do clear; pika; sleep 120; done' +alias pikabox='while true; do reset; pika; sleep 120; done' diff --git a/bash/osx/osxfun b/bash/osx/osxfun index f4b9729..a47a057 100644 --- a/bash/osx/osxfun +++ b/bash/osx/osxfun @@ -1,12 +1,13 @@ #!/bin/bash function planktimer() { # dependencies: 'say' 'termdown' + message='Push-up Time' while true; do termdown 1h30m; clear; - figlet "Plank Time" | lolcat; - say -v $(say -v ? | sed -n "/en_/p" | sed "s/ .*//" | shuf -n 1) "plank time"; + figlet "$message" | lolcat; + say -v $(say -v ? | sed -n "/en_/p" | sed "s/ .*//" | shuf -n 1) "$message"; read -n 1; if [ $1 ]; then termdown $1; diff --git a/bashrc b/bash/rc similarity index 90% rename from bashrc rename to bash/rc index e6ca080..893c229 100644 --- a/bashrc +++ b/bash/rc @@ -3,7 +3,7 @@ DOTWRYN="$HOME/.wryn" RC_DIR="$DOTWRYN/bash" # source .wryn/bash files -for file in $(find $RC_DIR -maxdepth 1 -type f); do source $file; done; +for file in $(find $RC_DIR -maxdepth 1 -type f ! -name 'rc'); do source $file; done; # osx if [[ "$OSTYPE" == "darwin"* ]]; then diff --git a/bash/rentdynamics b/bash/rentdynamics index 296506f..355cc2e 100644 --- a/bash/rentdynamics +++ b/bash/rentdynamics @@ -45,14 +45,14 @@ function rntbranchcleanup() { for dir in $(ls $RD_PATH); do rnt $dir >/dev/null 2>/dev/null; if [ -d .git ]; then - printf "clearing repository $dir..."; + printf " - %s\e[1;34m %s\e[0m..." "clearing repository" "$dir"; git branch -d $(git branch | sed -E "/develop|master|\*/d") >/dev/null 2>/dev/null; - printf "done!\n"; + printf "\e[1;32m%s\e[0m\n" " DONE"; else - echo $dir is not a git repository; + printf " - \e[1;34m%s\e[1;31m %s\e[0m" "$dir" "is not a git repository"; fi rnt; done; - echo && echo RentDynamics repository branches all clean! + printf "\n\n\e[1;36m%s\e[1;35m %s\e[0m\n\n" "RentDynamics" "repository branches all clean!"; } diff --git a/bash/utility b/bash/utility index 525307b..34f0050 100644 --- a/bash/utility +++ b/bash/utility @@ -9,3 +9,8 @@ function notes() { NOTE="$NOTE_PATH/$1$NOTE_EXTENSION"; [ $1 ] && [ -f $NOTE ] & # --- GIT ----------------------------------------------------- alias gitbranchcleanup='git branch -d $(git branch | sed -E "/develop|master|\*/d")' + + +alias pd='pushd'; +alias qd='popd'; +alias ds='dirs'; diff --git a/redirect b/redirect index 792c028..4fcac31 100755 --- a/redirect +++ b/redirect @@ -1,4 +1,4 @@ #!/bin/bash RC_DIR='$HOME/.wryn' -echo source $RC_DIR/bashrc >> $HOME/.bashrc -echo source $RC_DIR/vimrc >> $HOME/.vimrc +echo source $RC_DIR/bash/rc >> $HOME/.bashrc +echo source $RC_DIR/vim/rc.vim >> $HOME/.vimrc diff --git a/vim/en.utf-8.add.spl b/vim/en.utf-8.add.spl new file mode 100644 index 0000000..b01cd76 Binary files /dev/null and b/vim/en.utf-8.add.spl differ diff --git a/vimrc b/vim/rc.vim similarity index 92% rename from vimrc rename to vim/rc.vim index c648453..05daa57 100644 --- a/vimrc +++ b/vim/rc.vim @@ -1,6 +1,7 @@ " -- Environment Variables --------------------------------------- {{{ let $RC_DIR="/Users/w0ryn/.wryn" -let $WRYNVIMRC="$RC_DIR/vimrc" +let $VIM_DIR="$RC_DIR/vim" +let $WRYNVIMRC="$VIM_DIR/rc.vim" let $WRYNBASH="$RC_DIR/bashrc" let $MYBASHRC="/Users/w0ryn/.bashrc" " }}} @@ -21,7 +22,7 @@ syntax on " detect syntax set autoindent " match indentation with next line set smartindent " match indentation with syntax -set spellfile=$RC_DIR/en.utf-8.add +set spellfile=$VIM_DIR/en.utf-8.add set spelllang=en set showmatch " -- emit 'beep' when no matching symbol, @@ -33,7 +34,7 @@ set timeoutlen=200 " -- short timeout for multi-key functions " -- File Formatting ------------------------------------- {{{ augroup filetype_specific_formatting autocmd! - autocmd FileType python setlocal tabstop=4 softtabstop=4 shiftwidth=4 noexpandtab foldmethod=indent foldlevel=99 + autocmd FileType python setlocal tabstop=4 softtabstop=4 shiftwidth=4 expandtab foldmethod=indent foldlevel=99 autocmd FileType java setlocal tabstop=4 softtabstop=4 shiftwidth=4 noexpandtab foldmethod=indent foldlevel=99 autocmd FileType cs setlocal tabstop=4 softtabstop=4 shiftwidth=4 noexpandtab foldmethod=indent foldlevel=99 autocmd FileType html setlocal tabstop=2 softtabstop=2 shiftwidth=2 noexpandtab foldmethod=indent foldlevel=99 @@ -41,7 +42,7 @@ augroup filetype_specific_formatting autocmd FileType vim setlocal tabstop=4 softtabstop=4 shiftwidth=4 noexpandtab foldmethod=marker foldlevel=1 autocmd FileType sh setlocal tabstop=4 softtabstop=4 shiftwidth=4 noexpandtab foldmethod=indent foldlevel=99 autocmd FileType lisp setlocal tabstop=2 softtabstop=2 shiftwidth=2 expandtab foldmethod=manual foldlevel=99 -augroup END +augroup end " }}} " -- Key bindings ---------------------------------------- {{{ @@ -87,6 +88,9 @@ nnoremap Q !!$SHELL " \q for `q:` nnoremap q q: +" \t for rerun tests +nnoremap t q:?test + " \f for fold nnoremap f z nnoremap f z @@ -102,6 +106,6 @@ nnoremap _ :m -2 inoremap viwUea +" - specialized formatting +source $VIM_DIR/rd_formatting.vim " }}} - - diff --git a/vim/rd_formatting.vim b/vim/rd_formatting.vim new file mode 100644 index 0000000..e8e51a4 --- /dev/null +++ b/vim/rd_formatting.vim @@ -0,0 +1,13 @@ +augroup rent_dynamics + autocmd! + autocmd BufRead,BufEnter,BufNewFile */RentDynamics/* setlocal expandtab + autocmd BufRead,BufEnter,BufNewFile */RentDynamics/*.cs setlocal tabstop=2 softtabstop=2 shiftwidth=2 + autocmd BufRead,BufEnter,BufNewFile */RentDynamics/*.ts* setlocal tabstop=2 softtabstop=2 shiftwidth=2 + autocmd BufRead,BufEnter,BufNewFile */RentDynamics/*.scss setlocal tabstop=2 softtabstop=2 shiftwidth=2 + + autocmd BufRead,BufEnter,BufNewFile */lead-mgmt-api-v1/* setlocal expandtab + autocmd BufRead,BufEnter,BufNewFile */lead-mgmt-api-v1/*.cs setlocal tabstop=2 softtabstop=2 shiftwidth=2 + autocmd BufRead,BufEnter,BufNewFile */lead-mgmt-api-v1/*.cshtml setlocal tabstop=2 softtabstop=2 shiftwidth=2 filetype=html + + autocmd BufRead,BufNewFile */RentDynamics/* foldmethod=indent foldlevel=99 +augroup end