Permalink
Browse files

adding episodes 308 and 309

  • Loading branch information...
1 parent 34cac6d commit 113bfa9be6794c4bfe5c31eb51c318ecb26ba808 @ryanb committed Dec 19, 2011
View
@@ -0,0 +1,12 @@
+RailsCasts Episode #308: Oh My ZSH
+
+http://railscasts.com/episodes/308-oh-my-zsh
+
+Commands used in episode
+
+ ps
+ wget --no-check-certificate https://github.com/robbyrussell/oh-my-zsh/raw/master/tools/install.sh -O - | sh
+ curl -L https://github.com/robbyrussell/oh-my-zsh/raw/master/tools/install.sh | sh
+ mate ~/.zshrc
+ cat ~/.bash_profile >> ~/.zshrc
+ mate ~/.oh-my-zsh
@@ -0,0 +1,3 @@
+c() { cd ~/code/$1; }
+_c() { _files -W ~/code -/; }
+compdef _c c
@@ -0,0 +1,4 @@
+PROMPT='%3~$(git_prompt_info)%# '
+
+ZSH_THEME_GIT_PROMPT_PREFIX="["
+ZSH_THEME_GIT_PROMPT_SUFFIX="]"
View
@@ -0,0 +1,34 @@
+# Path to your oh-my-zsh configuration.
+ZSH=$HOME/.oh-my-zsh
+
+# Set name of the theme to load.
+# Look in ~/.oh-my-zsh/themes/
+# Optionally, if you set this to "random", it'll load a random theme each
+# time that oh-my-zsh is loaded.
+ZSH_THEME="rbates"
+
+# Set to this to use case-sensitive completion
+# CASE_SENSITIVE="true"
+
+# Comment this out to disable weekly auto-update checks
+# DISABLE_AUTO_UPDATE="true"
+
+# Uncomment following line if you want to disable colors in ls
+DISABLE_LS_COLORS="true"
+
+# Uncomment following line if you want to disable autosetting terminal title.
+# DISABLE_AUTO_TITLE="true"
+
+# Uncomment following line if you want red dots to be displayed while waiting for completion
+# COMPLETION_WAITING_DOTS="true"
+
+# Which plugins would you like to load? (plugins can be found in ~/.oh-my-zsh/plugins/*)
+# Example format: plugins=(rails git textmate ruby lighthouse)
+plugins=(git bundler brew gem rbates)
+
+source $ZSH/oh-my-zsh.sh
+
+# Customize to your needs...
+
+export PATH="$HOME/.rbenv/bin:$PATH"
+eval "$(rbenv init -)"
View
@@ -0,0 +1,14 @@
+RailsCasts Episode #309: A Shell-Scripting Story
+
+http://railscasts.com/episodes/309-a-shell-scripting-story
+
+Commands used in episode
+
+ rake --tasks | cut -d " " -f 2
+ unfunction _rake; . ~/.zshrc
+ ls -t .rake_tasks\~ Rakefile **/*.rake | head -n 1
+ touch Rakefile
+ find . -name '*.rb' -mtime -3 | xargs grep production
+ brew install ack
+ find . -name '*.rb' -mtime -3 | xargs sed -i 's/production/staging/'
+ # other commands: sort tr comm cut paste diff patch
View
@@ -0,0 +1,8 @@
+#compdef rake
+if [[ -f Rakefile ]]; then
+ local recent=$(ls -t .rake_tasks~ Rakefile **/*.rake | head -n 1)
+ if [[ $recent != .rake_tasks~ ]]; then
+ rake --tasks | cut -d ' ' -f 2 > .rake_tasks~
+ fi
+ compadd $(cat .rake_tasks~)
+fi

0 comments on commit 113bfa9

Please sign in to comment.