Skip to content

Commit

Permalink
better shits
Browse files Browse the repository at this point in the history
  • Loading branch information
Jigish Patel committed Feb 12, 2015
1 parent 62a282d commit c6d5ed9
Show file tree
Hide file tree
Showing 5 changed files with 56 additions and 74 deletions.
11 changes: 0 additions & 11 deletions bashrc
Original file line number Diff line number Diff line change
Expand Up @@ -36,9 +36,6 @@ alias b='cat ~/.bashrc |grep'

export GOPATH=~/.go

export SCALA_HOME=/usr/local/scala
export SBT_OPTS="-XX:+CMSClassUnloadingEnabled -XX:PermSize=256M -XX:MaxPermSize=512M"

export PATH=${PATH}:~/bin:/usr/local/go/bin:${SCALA_HOME}/bin:${GOPATH}/bin:/usr/local/sbin

# Colorized Prompt
Expand Down Expand Up @@ -110,14 +107,6 @@ function gclone_ctl {
git clone ssh://git@github.com/$1
}

# Spotify
alias spn='spotify next && spotify status'
alias spf='spotify shuffle'
alias spr='spotify repeat'
alias sps='spotify status'
alias spt='spotify toggle && spotify status'
alias spp='spotify toggle && spotify status'

[[ -s "$HOME/.bashrc.`uname`" ]] && source "$HOME/.bashrc.`uname`"
[[ -s "$HOME/.bashrc.accompani" ]] && source "$HOME/.bashrc.accompani"
[[ -s "$HOME/.bashrc.local" ]] && source "$HOME/.bashrc.local"
9 changes: 8 additions & 1 deletion bashrc.Darwin
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,11 @@ dropbox-ctl() {
open "http://dl.dropbox.com/u/56340597/$1"
}
alias dropbox=dropbox-ctl
alias jsonpp=/usr/local/Cellar/jsonpp/86.64/bin/jsonpp

# Spotify
alias spn='spotify next && spotify status'
alias spf='spotify shuffle'
alias spr='spotify repeat'
alias sps='spotify status'
alias spt='spotify toggle && spotify status'
alias spp='spotify toggle && spotify status'
34 changes: 34 additions & 0 deletions bootstrap
Original file line number Diff line number Diff line change
@@ -1,4 +1,38 @@
#!/bin/bash

CURRDIR=`pwd`
SCRIPTDIR=$(cd `dirname $0` && pwd)

# Update git submodules
cd $SCRIPTDIR
git pull
git submodule update --init
cd vim-config
git submodule update --init

# Create Links
cd ~
[[ ! -L .bashrc ]] && [[ -f .bashrc ]] && mv .bashrc .bashrc.old
[[ ! -L .bashrc ]] && ln -s $SCRIPTDIR/bashrc .bashrc
[[ ! -L .bashrc.`uname` ]] && ln -s $SCRIPTDIR/bashrc.`uname` .bashrc.`uname`
[[ ! -L .gitconfig ]] && ln -s $SCRIPTDIR/gitconfig .gitconfig
[[ ! -L .git-global-ignore ]] && ln -s $SCRIPTDIR/git-global-ignore .git-global-ignore
[[ ! -L .tigrc ]] && ln -s $SCRIPTDIR/tigrc .tigrc
[[ ! -L .vim ]] && ln -s $SCRIPTDIR/vim-config .vim
[[ ! -L .vimrc ]] && ln -s .vim/vimrc .vimrc
[[ ! -L .screenrc ]] && ln -s $SCRIPTDIR/screenrc .screenrc
[[ ! -L .zshrc ]] && ln -s $SCRIPTDIR/zshrc .zshrc
mkdir -p bin
cd bin
[[ ! -L z.sh ]] && ln -s $SCRIPTDIR/z/z.sh

[ ! $(which go) = "" ] && go get -u github.com/github/hub

# preinstall vim bundle
cd ~/.vim/bundle/neobundle.vim
./bin/neoinstall

# run os-specific shit
$SCRIPTDIR/bootstrap.`uname`

cd $CURRDIR
52 changes: 14 additions & 38 deletions bootstrap.Darwin
Original file line number Diff line number Diff line change
@@ -1,6 +1,19 @@
#!/bin/bash

CURRDIR=`pwd`
SCRIPTDIR=$(cd `dirname $0` && pwd)

# Create Links
cd ~
[[ ! -L .slate.js ]] && ln -s $SCRIPTDIR/slate.js .slate.js
[[ ! -L .xvimrc ]] && ln -s $SCRIPTDIR/xvimrc .xvimrc
[[ ! -L .gvimrc ]] && ln -s .vim/gvimrc .gvimrc
mkdir -p bin
cd bin
[[ ! -L spotify ]] && ln -s $SCRIPTDIR/spotify

ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"

brew install curl wget the_silver_searcher chruby ruby-build htop

if [[ "$TERM_PROGRAM" == "iTerm.app" ]] ; then
printf "\n> You appear to be running this script from within iTerm.app which could\n"
Expand All @@ -16,42 +29,5 @@ if ps wwwaux | egrep -q 'iTerm\.app' >/dev/null ; then
exit 4
fi

SCRIPTDIR=$(cd `dirname $0` && pwd)

# Update git submodules
cd $SCRIPTDIR
git submodule update --init
#git submodule foreach checkout master
cd vim-config
git submodule update --init

# Create Links
cd ~
[[ ! -L .bashrc ]] && [[ -f .bashrc ]] && mv .bashrc .bashrc.old
[[ ! -L .bashrc ]] && ln -s $SCRIPTDIR/bashrc .bashrc
[[ ! -L .bashrc.`uname` ]] && ln -s $SCRIPTDIR/bashrc.`uname` .bashrc.`uname`
[[ ! -L .gitconfig ]] && ln -s $SCRIPTDIR/gitconfig .gitconfig
[[ ! -L .git-global-ignore ]] && ln -s $SCRIPTDIR/git-global-ignore .git-global-ignore
[[ ! -L .tigrc ]] && ln -s $SCRIPTDIR/tigrc .tigrc
[[ ! -L .vim ]] && ln -s $SCRIPTDIR/vim-config .vim
[[ ! -L .slate.js ]] && ln -s $SCRIPTDIR/slate.js .slate.js
[[ ! -L .zshrc ]] && ln -s $SCRIPTDIR/zshrc .zshrc
[[ ! -L .vimrc ]] && ln -s .vim/vimrc .vimrc
[[ ! -L .xvimrc ]] && ln -s $SCRIPTDIR/xvimrc .xvimrc
[[ ! -L .gvimrc ]] && ln -s .vim/gvimrc .gvimrc
cd bin
[[ ! -L z.sh ]] && ln -s $SCRIPTDIR/z/z.sh
[[ ! -L spotify ]] && ln -s $SCRIPTDIR/spotify

# Copy iTerm2 Configs
cp $SCRIPTDIR/iterm2-config/com.googlecode.iterm2.plist ~/Library/Preferences/

ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"

brew install curl wget the_silver_searcher chruby ruby-build htop

# preinstall vim bundle
cd ~/.vim/bundle/neobundle.vim
./bin/neoinstall

cd $CURRDIR
24 changes: 0 additions & 24 deletions bootstrap.Linux
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
#!/bin/bash

CURRDIR=`pwd`
SCRIPTDIR=$(cd `dirname $0` && pwd)

# we need to disable strict host checking for github since we're likey automating this shit
Expand All @@ -11,32 +10,9 @@ sudo apt-get update
#sudo apt-get install -y mosh
sudo apt-get install -y perl curl wget ctags screen ngrep silversearcher-ag

# Update git submodules
cd $SCRIPTDIR
git pull
git submodule update --init
cd vim-config
git submodule update --init

# Create Links
cd ~
[[ ! -L .bashrc ]] && [[ -f .bashrc ]] && mv .bashrc .bashrc.old
[[ ! -L .bashrc ]] && ln -s $SCRIPTDIR/bashrc .bashrc
[[ ! -L .bashrc.`uname` ]] && ln -s $SCRIPTDIR/bashrc.`uname` .bashrc.`uname`
[[ ! -L .gitconfig ]] && ln -s $SCRIPTDIR/gitconfig .gitconfig
[[ ! -L .git-global-ignore ]] && ln -s $SCRIPTDIR/git-global-ignore .git-global-ignore
[[ ! -L .tigrc ]] && ln -s $SCRIPTDIR/tigrc .tigrc
[[ ! -L .vim ]] && ln -s $SCRIPTDIR/vim-config .vim
[[ ! -L .zshrc ]] && ln -s $SCRIPTDIR/zshrc .zshrc
[[ ! -L .screenrc ]] && ln -s $SCRIPTDIR/screenrc .screenrc
[[ ! -L .vimrc ]] && ln -s .vim/vimrc .vimrc
mkdir -p bin
cd bin
[[ ! -L z.sh ]] && ln -s $SCRIPTDIR/z/z.sh

[ ! $(which go) = "" ] && go get -u github.com/github/hub

cd ~/.vim/bundle/neobundle.vim
./bin/neoinstall

cd $CURRDIR

0 comments on commit c6d5ed9

Please sign in to comment.