1
0
Эх сурвалжийг харах

Update Go, NVM/bash_completion, and iTerm integration

Tom McKenzie 7 жил өмнө
parent
commit
d327ab6d36

+ 4 - 2
.rc.d/applications.sh

@@ -2,11 +2,13 @@
 if [ -d "${HOME}/.nvm" ]; then
   export NVM_DIR="$HOME/.nvm"
   [ -s "$NVM_DIR/nvm.sh" ] && . "$NVM_DIR/nvm.sh" # This loads nvm
+  [ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion"  # This loads nvm bash_completion
 fi
 
 # export golang bin path
-if [ -d "$HOME/go/bin" ]; then
-  export PATH=$PATH:$HOME/go/bin
+if [ -d "$HOME/go" ]; then
+  export GOPATH=$HOME/go
+  export PATH=$PATH:$GOPATH/bin
 fi
 
 # thefuck

+ 2 - 1
.rc.d/docker.sh

@@ -1,4 +1,5 @@
-if [ $(type docker) ]; then
+type docker &>/dev/null
+if [ $? -eq 0 ]; then
   alias dredisflush="docker-compose exec redis redis-cli FLUSHALL"
   alias dnewmigration="docker-compose exec web bundle exec rails generate migration"
   alias dmigrate="docker-compose exec web bundle exec rake db:migrate"

+ 4 - 0
.zshrc.d/iterm.zsh

@@ -4,3 +4,7 @@ test -e "${HOME}/.iterm2_shell_integration.zsh" && source "${HOME}/.iterm2_shell
 function set-title {
   echo -ne "\033]0;"$*"\007"
 }
+
+function set-status {
+  it2setkeylabel set status $*
+}

+ 0 - 5
README.md

@@ -8,8 +8,3 @@ Not totally organised yet, but includes the important things.
 
 * Loads [zgen](https://github.com/tarjoilija/zgen) under zsh
 * `.rc.d` directory idea borrowed from https://github.com/chr4/shellrc
-
-
-# todo
-
-* Use `felixgravila/zsh-abbr-path` for RPROMPT