diff --git a/dotfiles/lib/shellrc/aliases.sh b/dotfiles/lib/shellrc/aliases.sh index 2b373109..31c9f254 100644 --- a/dotfiles/lib/shellrc/aliases.sh +++ b/dotfiles/lib/shellrc/aliases.sh @@ -4,6 +4,7 @@ alias tmux_cb_to_remote_cb='tmux saveb - | linux_nc_paste_to_remote_clipboard' alias timestamp='date +%s' alias go2dotfiles='cd $(dirname `readlink -f ~/.zshrc | xargs dirname`)' alias fn='find . -name ' +alias prj='cd ~/Projects' # enables the sudoing of aliases. alias sudo='sudo ' diff --git a/dotfiles/lib/shellrc/functions.sh b/dotfiles/lib/shellrc/functions.sh index d9ecbe87..b4be4690 100644 --- a/dotfiles/lib/shellrc/functions.sh +++ b/dotfiles/lib/shellrc/functions.sh @@ -175,3 +175,9 @@ function set_osx_hostname() { sudo scutil --set LocalHostName $new_hostname sudo defaults write /Library/Preferences/SystemConfiguration/com.apple.smb.server NetBIOSName -string $new_hostname } + +function fix_brew_htop() { + chmod 777 $(readlink -f `which htop`) + sudo chown root $(readlink -f `which htop`) + sudo chmod 6555 `which htop` +} diff --git a/dotfiles/lib/shellrc/path.sh b/dotfiles/lib/shellrc/path.sh index 4d68c6c7..1aefd485 100644 --- a/dotfiles/lib/shellrc/path.sh +++ b/dotfiles/lib/shellrc/path.sh @@ -7,4 +7,5 @@ function add_to_back_of_path { } add_to_back_of_path "$HOME/.local/lib/python2.6/site-packages" +add_to_front_of_path "$(brew --prefix coreutils)/libexec/gnubin" add_to_front_of_path "/usr/local/bin" diff --git a/extra.sh b/extra.sh new file mode 100644 index 00000000..6f241318 --- /dev/null +++ b/extra.sh @@ -0,0 +1,4 @@ +pip install --user -rresources/python_packages.txt + +# Install powerline. +pip install --user git+git://github.com/Lokaltog/powerline diff --git a/resources/brew.sh b/resources/brew.sh index a708b040..62be935a 100755 --- a/resources/brew.sh +++ b/resources/brew.sh @@ -5,15 +5,13 @@ brew update brew upgrade # Install GNU core utilities (those that come with OS X are outdated) -brew install coreutils -echo "Don’t forget to add $(brew --prefix coreutils)/libexec/gnubin to \$PATH." +brew install coreutils + # Install GNU `find`, `locate`, `updatedb`, and `xargs`, g-prefixed brew install findutils + # Install Bash 4 brew install bash -brew install scala -brew install sbt -brew install greadlink # Install wget with IRI support brew install wget --enable-iri @@ -22,19 +20,29 @@ brew install wget --enable-iri brew tap homebrew/dupes brew install homebrew/dupes/grep -# Install everything else +# Important tools brew install emacs brew install git brew install tmux +brew install python +brew install htop +brew link python +brew install scala +brew install sbt + +# Install everything else +brew install watch +brew install greadlink brew install nmap brew install readline brew install netcat brew install reattach-to-user-namespace brew install daemonize -ln -s /usr/local/Cellar/daemonize/1.7.4/sbin/daemonize /usr/local/bin/daemonize +brew link daemonize brew install ngrep -brew install watch brew install gist # Remove outdated versions from the cellar brew cleanup +# htop wont display all process information if the owner is not root +fix_brew_htop diff --git a/setup.sh b/setup.sh index 874a7923..29952208 100755 --- a/setup.sh +++ b/setup.sh @@ -1,5 +1,6 @@ #!/usr/bin/env bash cd `dirname $BASH_SOURCE` && source bootstrapping.sh +source dotfiles/lib/shellrc/functions.sh case `uname` in 'Darwin') source resources/osx.sh