From 8b99d2420c6fc81bddb77950cd618cc46c565f2b Mon Sep 17 00:00:00 2001 From: Matthias Kretschmann Date: Sat, 28 Mar 2015 02:42:45 +0100 Subject: [PATCH] updates --- paths => bash_paths | 3 +-- bash_profile | 9 ++++++++- bin/npm-upgrade.sh | 9 --------- bin/update-dotfiles.sh | 2 +- bin/update-everything.sh | 17 +---------------- bootstrap.sh | 2 +- gitconfig | 8 ++++++++ ruby.sh | 4 ++-- 8 files changed, 22 insertions(+), 32 deletions(-) rename paths => bash_paths (98%) delete mode 100755 bin/npm-upgrade.sh diff --git a/paths b/bash_paths similarity index 98% rename from paths rename to bash_paths index 24076a8..8cd1d46 100644 --- a/paths +++ b/bash_paths @@ -2,6 +2,7 @@ # Directories to be prepended to PATH declare -a dirs_to_prepend=( + "$HOME/.bin" "/usr/local/sbin" "/usr/local/bin" # Ensure that this bin always takes precedence over `/usr/bin` ) @@ -9,8 +10,6 @@ declare -a dirs_to_prepend=( # Directories to be appended to PATH declare -a dirs_to_append=( "/usr/bin" - "$HOME/.bin" - "$HOME/.rvm/bin" "$(brew --prefix coreutils)/libexec/gnubin" # Add brew-installed GNU core utilities bin "$(brew --prefix)/share/npm/bin" # Add npm-installed package bin "$(brew --prefix android-sdk)/tools" diff --git a/bash_profile b/bash_profile index 74958a6..aceb597 100644 --- a/bash_profile +++ b/bash_profile @@ -12,7 +12,7 @@ # Load ~/.private, ~/.bash_prompt # ---------------------------------------------------------------------- -for file in ~/.{bash_prompt,aliases,exports,paths,private,inputrc}; do +for file in ~/.{bash_paths,bash_prompt,exports,aliases,inputrc,private}; do [ -r "$file" ] && [ -f "$file" ] && source "$file" done; unset file; @@ -59,5 +59,12 @@ complete -C aws_completer aws # grunt-cli tab completion eval "$(grunt --completion=bash)" +# ---------------------------------------------------------------------- +# rvm +# ---------------------------------------------------------------------- + +# Add RVM to PATH for scripting +export PATH="$PATH:$HOME/.rvm/bin" + # Load RVM into a shell session *as a function* [[ -s "$HOME/.rvm/scripts/rvm" ]] && source "$HOME/.rvm/scripts/rvm" \ No newline at end of file diff --git a/bin/npm-upgrade.sh b/bin/npm-upgrade.sh deleted file mode 100755 index 4ead4c8..0000000 --- a/bin/npm-upgrade.sh +++ /dev/null @@ -1,9 +0,0 @@ -#!/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-dotfiles.sh b/bin/update-dotfiles.sh index 00d384a..3ea1ce8 100755 --- a/bin/update-dotfiles.sh +++ b/bin/update-dotfiles.sh @@ -15,7 +15,7 @@ dir=~/Projects/dotfiles # list of files/folders to symlink in homedir -files="aliases bashrc bash_profile bash_prompt exports gemrc gitconfig gitignore hushlogin inputrc paths private tm_properties generator.json npmrc bin" +files="aliases bashrc bash_profile bash_paths bash_prompt exports gemrc gitconfig gitignore hushlogin inputrc private tm_properties generator.json npmrc bin" # ---------------------------------------------------------------------- diff --git a/bin/update-everything.sh b/bin/update-everything.sh index 3e3e897..f2fb4c8 100755 --- a/bin/update-everything.sh +++ b/bin/update-everything.sh @@ -34,8 +34,7 @@ echo "$(tput sgr0)" # reset npm install npm -g # update all global packages -#npm update -g -sh npm-upgrade.sh +npm update -g # # Ruby @@ -57,20 +56,6 @@ rvm gemset update rvm cleanup all -# -# Gems -# ------------- - -echo "$(tput setaf 136)" -echo "Update gems " -echo "==============================" -echo "$(tput sgr0)" # reset - -gem update --system -gem update - - - echo "$(tput setaf 64)" # green echo "-------------------------------" echo " ✓ all done" diff --git a/bootstrap.sh b/bootstrap.sh index d39605b..864299e 100755 --- a/bootstrap.sh +++ b/bootstrap.sh @@ -15,7 +15,7 @@ dir=$DOTFILES_DIR # list of files/folders to symlink in homedir -files="aliases bashrc bash_profile bash_prompt exports gemrc gitconfig gitignore hushlogin inputrc paths private tm_properties generator.json npmrc bin" +files="aliases bashrc bash_profile bash_paths bash_prompt exports gemrc gitconfig gitignore hushlogin inputrc private tm_properties generator.json npmrc bin" # ---------------------------------------------------------------------- diff --git a/gitconfig b/gitconfig index 9fd3fa8..b2e075e 100644 --- a/gitconfig +++ b/gitconfig @@ -88,3 +88,11 @@ [user] name = email = m@kretschmann.io +[filter "media"] + clean = git media clean %f + smudge = git media smudge %f + required = true +[filter "hawser"] + clean = git hawser clean %f + smudge = git hawser smudge %f + required = true diff --git a/ruby.sh b/ruby.sh index 88de702..619c5ba 100755 --- a/ruby.sh +++ b/ruby.sh @@ -7,8 +7,8 @@ curl -sSL https://get.rvm.io | bash rvm requirements # Install a Ruby -rvm install 2.2.0 -rvm use --default 2.2.0 +rvm install 2.1.4 +rvm use --default 2.1.4 rvm rubygems latest # Install gems