Browse code

Merging geoffgarside work

Robby Russell authored on 31/08/2009 at 22:09:34
Showing 6 changed files
... ...
@@ -2,7 +2,8 @@ alias pu='pushd'
2 2
 alias po='popd'
3 3
 
4 4
 alias sc='ruby script/console'
5
-alias ss='ruby script/server'
5
+alias sd='ruby script/server --debugger'
6
+alias ss='thin --stats "/thin/stats" start'
6 7
 
7 8
 alias mr='mate CHANGELOG app config db lib public script spec test'
8 9
 alias .='pwd'
... ...
@@ -10,11 +11,12 @@ alias ...='cd ../..'
10 10
 
11 11
 alias _='sudo'
12 12
 
13
-alias g='grep -in'
13
+#alias g='grep -in'
14
+alias g='git'
14 15
 
15 16
 alias history='fc -l 1'
16 17
 
17
-alias ls='ls -GF'
18
+alias ls='ls -F'
18 19
 alias ll='ls -al'
19 20
 
20 21
 alias sgem='sudo gem'
... ...
@@ -26,4 +28,12 @@ alias git-svn-dcommit-push='git svn dcommit && git push github master:svntrunk'
26 26
 bindkey '\ew' kill-region
27 27
 
28 28
 bindkey -s '\el' "ls\n"
29
-bindkey -s '\e.' "..\n"
30 29
\ No newline at end of file
30
+bindkey -s '\e.' "..\n"
31
+
32
+alias et='mate . &'
33
+alias ett='mate app config lib db public spec test Rakefile Capfile Todo &'
34
+alias etp='mate app config lib db public spec test vendor/plugins vendor/gems Rakefile Capfile Todo &'
35
+alias etts='mate app config lib db public script spec test vendor/plugins vendor/gems Rakefile Capfile Todo &'
36
+
37
+bindkey "^[[A" history-beginning-search-backward
38
+bindkey "^[[B" history-beginning-search-forward
... ...
@@ -30,4 +30,26 @@ function zsh_stats() {
30 30
 
31 31
 function uninstall_oh_my_zsh() {
32 32
   /bin/sh $ZSH/tools/uninstall.sh
33
-}
34 33
\ No newline at end of file
34
+}
35
+
36
+function tab() {
37
+  osascript 2>/dev/null <<EOF
38
+    tell application "System Events"
39
+      tell process "Terminal" to keystroke "t" using command down
40
+    end
41
+    tell application "Terminal"
42
+      activate
43
+      do script with command "cd $PWD; $*" in window 1
44
+    end tell
45
+EOF
46
+}
47
+
48
+function take() {
49
+  mkdir -p $1
50
+  cd $1
51
+}
52
+
53
+function tm() {
54
+  cd $1
55
+  mate $1
56
+}
... ...
@@ -3,7 +3,7 @@ function git_prompt_info() {
3 3
   if [[ -d .git ]]; then
4 4
     ref=$(git symbolic-ref HEAD 2> /dev/null) || return
5 5
     branch=${ref#refs/heads/}
6
-    CURRENT_BRANCH="%{$fg[red]%}git:(%{$fg[green]${branch}%{$fg[red])"
6
+    CURRENT_BRANCH="git:(%{$fg[red]%}${branch}%{$fg[blue]%})%{$reset_color%}$(parse_git_dirty)"
7 7
   else
8 8
     CURRENT_BRANCH=''
9 9
   fi
... ...
@@ -12,5 +12,5 @@ function git_prompt_info() {
12 12
 }
13 13
 
14 14
 parse_git_dirty () {
15
-  [[ $(git status | tail -n1) != "nothing to commit (working directory clean)" ]] && echo "%{$fg[white] ♻ "
15
+  [[ $(git status | tail -n1) != "nothing to commit (working directory clean)" ]] && echo " %{$fg[yellow]%}✗%{$reset_color%}"
16 16
 }
... ...
@@ -29,4 +29,4 @@ setopt prompt_subst
29 29
 
30 30
 export LSCOLORS="Gxfxcxdxbxegedabagacad"
31 31
 
32
-source "$ZSH/themes/$ZSH_THEME.zsh-theme"
33 32
\ No newline at end of file
33
+source "$ZSH/themes/$ZSH_THEME.zsh-theme"
34 34
new file mode 100644
... ...
@@ -0,0 +1,2 @@
0
+# PROMPT="[%*] %n:%c $(git_prompt_info)%(!.#.$) "
1
+PROMPT='[%*] %{$fg[cyan]%}%n%{$reset_color%}:%{$fg[green]%}%c%{$reset_color%}$(git_prompt_info) %(!.#.$) '
... ...
@@ -4,12 +4,12 @@ export ZSH=$HOME/.oh-my-zsh
4 4
 # Set to the name theme to load.
5 5
 # Look in ~/.oh-my-zsh/themes/
6 6
 export ZSH_THEME="robbyrussell"
7
+# export ZSH_THEME="geoffgarside"
7 8
 
8 9
 # Load all of the config files in ~/oh-my-zsh that end in .zsh
9 10
 # TIP: Add files you don't want in git to .gitignore
10 11
 for i in $ZSH/*zsh; do source $i; done;
11 12
 
12 13
 # Customize to your needs...
13
-export PATH=~/bin:/opt/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/opt/local/sbin:/opt/local/lib/postgresql83/bin
14
-
14
+#export PATH=~/bin:/opt/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/opt/local/sbin:/opt/local/lib/postgresql83/bin
15 15