diff --git a/aliases b/aliases index 38f7894..ab49070 100644 --- a/aliases +++ b/aliases @@ -11,7 +11,7 @@ alias krlc='ssh kremalicious' alias esp="open -a Espresso" # Update All The Things -alias update='sudo softwareupdate -i -a; brew update; brew upgrade; brew cleanup; npm update npm -g; npm update -g; rvm get branch master; rvm cleanup all; gem update --system; gem update' +alias update='update.sh' # Recursively delete `.DS_Store` files alias cleanup="find . -type f -name '*.DS_Store' -ls -delete" diff --git a/bash_profile b/bash_profile index 1f8f570..d6d76a1 100644 --- a/bash_profile +++ b/bash_profile @@ -61,6 +61,7 @@ export ARCHFLAGS="-arch x86_64" # we want the various sbins on the path along with /usr/local/bin PATH="$PATH:/usr/local/sbin:/usr/sbin:/sbin" PATH="/usr/local/bin:$PATH" +[ -d "$HOME/.bin" ] && PATH="$HOME/.bin:$PATH" # if these bins exist, then add them to the PATH ANDROID_HOME="/usr/local/opt/android-sdk" diff --git a/bin/npm-upgrade.sh b/bin/npm-upgrade.sh new file mode 100755 index 0000000..4ead4c8 --- /dev/null +++ b/bin/npm-upgrade.sh @@ -0,0 +1,9 @@ +#!/bin/sh + +set -e +set -x + +for package in $(npm -g outdated --parseable --depth=0 | cut -d: -f2) +do + npm -g install "$package" +done diff --git a/bin/update.sh b/bin/update.sh new file mode 100755 index 0000000..44226ba --- /dev/null +++ b/bin/update.sh @@ -0,0 +1,41 @@ +#!/bin/bash + +# +# OS X +# ------------- + +sudo softwareupdate -i -a + +# +# Homebrew +# ------------- + +brew update +brew upgrade +brew cleanup + + +# +# npm +# ------------- + +# update npm itself +npm update npm -g + +# update all global packages +#npm update -g +sh npm-upgrade.sh + + +# +# Ruby +# ------------- +rvm get branch master +rvm cleanup all + + +# +# Gems +# ------------- +gem update --system +gem update \ No newline at end of file diff --git a/update.sh b/bootstrap-update.sh similarity index 97% rename from update.sh rename to bootstrap-update.sh index 106a960..f2bf444 100755 --- a/update.sh +++ b/bootstrap-update.sh @@ -14,7 +14,7 @@ # dotfiles directory dir=~/Projects/dotfiles # list of files/folders to symlink in homedir -files="aliases bashrc bash_profile bash_prompt gemrc gitconfig gitignore_global hushlogin inputrc private tm_properties generator.json npmrc" +files="aliases bashrc bash_profile bash_prompt gemrc gitconfig gitignore_global hushlogin inputrc private tm_properties generator.json npmrc bin" # ---------------------------------------------------------------------- # change to the dotfiles directory diff --git a/make.sh b/bootstrap.sh similarity index 97% rename from make.sh rename to bootstrap.sh index 0a5da86..337aa9b 100755 --- a/make.sh +++ b/bootstrap.sh @@ -14,7 +14,7 @@ # dotfiles directory dir=~/Projects/dotfiles # list of files/folders to symlink in homedir -files="aliases bashrc bash_profile bash_prompt gemrc gitconfig gitignore_global hushlogin inputrc private tm_properties generator.json npmrc" +files="aliases bashrc bash_profile bash_prompt gemrc gitconfig gitignore_global hushlogin inputrc private tm_properties generator.json npmrc bin" # ---------------------------------------------------------------------- # change to the dotfiles directory