Removed custom.bash and am now completely ignoring all files within the custom directory. Started de-macify to provide more support for linux (thanks to alsemyonov on github).

pull/4/head^2
Robert R Evans 2010-10-06 17:27:55 -07:00
parent a6d20e67fe
commit c9da086643
11 changed files with 51 additions and 18 deletions

1
.gitignore vendored
View File

@ -1,3 +1,2 @@
.DS_Store .DS_Store
custom/*.bash custom/*.bash
!custom/example.bash

View File

@ -30,6 +30,9 @@ rails-help
git-help git-help
</code></pre> </code></pre>
## Your Custom scripts, aliases, and functions
If you have custom stuff that you don't want committed to bash it, put those scripts into the custom directory. It is automatically ignored by git.
## Themes ## Themes

View File

@ -51,6 +51,13 @@ done
export PS1=$PROMPT export PS1=$PROMPT
# Adding Support for other OSes
PREVIEW="less"
[ -s /usr/bin/gloobus-preview ] && PREVIEW="gloobus-preview"
[ -s /Applications/Preview.app ] && PREVIEW="/Applications/Preview.app"
# #
# Custom Help # Custom Help

View File

@ -1,3 +1,5 @@
if [ `which brew` ]; then
if [ -f `brew --prefix`/Library/Contributions/brew_bash_completion.sh ]; then if [ -f `brew --prefix`/Library/Contributions/brew_bash_completion.sh ]; then
. `brew --prefix`/Library/Contributions/brew_bash_completion.sh . `brew --prefix`/Library/Contributions/brew_bash_completion.sh
fi fi
fi

View File

@ -1,4 +0,0 @@
#!/bin/bash
# Your Custom Bash alias', functions, etc.
#

View File

@ -12,16 +12,16 @@ function myip {
# View man documentation in Preview # View man documentation in Preview
pman () { pman () {
man -t "${1}" | open -f -a /Applications/Preview.app/ man -t "${1}" | open -f -a $PREVIEW
} }
pcurl() { pcurl() {
curl "${1}" | open -f -a /Applications/Preview.app/ curl "${1}" | open -f -a $PREVIEW
} }
pri() { pri() {
ri -T "${1}" | open -f -a /Applications/Preview.app/ ri -T "${1}" | open -f -a $PREVIEW
} }

View File

@ -18,3 +18,7 @@ function git_remove_missing_files() {
function local-ignore() { function local-ignore() {
echo "$1" >> .git/info/exclude echo "$1" >> .git/info/exclude
} }
function gitignore() {
echo ".DS_Store" >> .gitignore
}

View File

@ -1,4 +1,8 @@
#!/bin/bash #!/bin/bash
#
# The install directory is hard-coded. TOOD: allow the directory to be specified on the command line.
#
function rails_jquery { function rails_jquery {
curl -o public/javascripts/rails.js http://github.com/rails/jquery-ujs/raw/master/src/rails.js curl -o public/javascripts/rails.js http://github.com/rails/jquery-ujs/raw/master/src/rails.js

View File

@ -3,9 +3,14 @@
# Desktop Programs # Desktop Programs
alias fireworks="open -a '/Applications/Adobe Fireworks CS3/Adobe Fireworks CS3.app'" alias fireworks="open -a '/Applications/Adobe Fireworks CS3/Adobe Fireworks CS3.app'"
alias photoshop="open -a '/Applications/Adobe Photoshop CS3/Adobe Photoshop.app'" alias photoshop="open -a '/Applications/Adobe Photoshop CS3/Adobe Photoshop.app'"
alias preview="open -a '/Applications/Preview.app'" alias preview="open -a '$PREVIEW'"
alias xcode="open -a '/Developer/Applications/Xcode.app'" alias xcode="open -a '/Developer/Applications/Xcode.app'"
alias filemerge="open -a '/Developer/Applications/Utilities/FileMerge.app'" alias filemerge="open -a '/Developer/Applications/Utilities/FileMerge.app'"
alias safari="open -a safari" alias safari="open -a safari"
alias firefox="open -a firefox" alias firefox="open -a firefox"
alias dashcode="open -a dashcode" alias dashcode="open -a dashcode"
if [ -s /usr/bin/firefox ] ; then
unalias firefox
fi

View File

@ -7,7 +7,6 @@ alias gs='git status'
alias gl='git pull' alias gl='git pull'
alias gup='git fetch && git rebase' alias gup='git fetch && git rebase'
alias gp='git push' alias gp='git push'
alias gd='git diff | mate'
alias gdv='git diff -w "$@" | vim -R -' alias gdv='git diff -w "$@" | vim -R -'
alias gc='git commit -v' alias gc='git commit -v'
alias gca='git commit -v -a' alias gca='git commit -v -a'
@ -16,6 +15,20 @@ alias gba='git branch -a'
alias gcount='git shortlog -sn' alias gcount='git shortlog -sn'
alias gcp='git cherry-pick' alias gcp='git cherry-pick'
case $OSTYPE in
linux*)
alias gd='git diff | vim -R -'
;;
darwin*)
alias gd='git diff | mate'
;;
darwin*)
alias gd='git diff'
;;
esac
function git-help() { function git-help() {
echo "Git Custom Aliases Usage" echo "Git Custom Aliases Usage"
echo echo

View File

@ -1,7 +1,7 @@
#!/bin/bash #!/bin/bash
# prompt themeing # prompt themeing
PROMPT='\n${bold_blue}$(prompt_char)$(git_prompt_info) ${orange}\h ${reset_color}in ${green}\w ${reset_color}→ ' PROMPT='${bold_blue}$(prompt_char)$(git_prompt_info) ${orange}\h ${reset_color}in ${green}\w ${reset_color}→ '
# git themeing # git themeing
GIT_THEME_PROMPT_DIRTY=" ${red}" GIT_THEME_PROMPT_DIRTY=" ${red}"