Last active
July 11, 2018 13:46
-
-
Save carlosvega20/af3f779a98093403993c6a886256b178 to your computer and use it in GitHub Desktop.
Zsh config
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Path to Oh-My-Zsh installation | |
export ZSH="/Users/carlosvega/.oh-my-zsh" | |
# Plugins | |
plugins=(git) | |
source $ZSH/oh-my-zsh.sh | |
PROMPT='$fg[yellow]$(echo "${PWD/$HOME/~}") $fg[cyan]$(git_prompt_info) $fg[magenta]$(node_version) | |
$reset_color$ ' | |
function git_prompt_info() { | |
ref=$(git symbolic-ref HEAD 2> /dev/null) || return | |
echo "$(parse_git_dirty)$(current_branch)" | |
} | |
function node_version() { | |
echo "n>$(node -v)" | |
} | |
# Utilities | |
alias mkcd="mkdir $1 && cd &1" | |
alias ls="ls -Gh" | |
# Create a temporal folder, create an empty index.js and simple package.json | |
alias node_t="tempdir=`mktemp -d` && cd $(echo '$tempdir') && touch index.js && npm init --force --yes --silent" | |
# Install vim Vundle plugins | |
alias vim_i="vim +PluginInstall +qall" | |
#Open vim with nerdTree | |
alias vim="vim +NERDTree" | |
# Android SDK | |
export ANDROID_HOME=/Users/carlosvega/Library/Android/sdk | |
export PATH=$PATH:$ANDROID_HOME/tools:$ANDROID_HOME/platform-tools | |
# JAVA 1.8 | |
export JAVA_HOME="$(/usr/libexec/java_home -v 1.8)" | |
# z to jump around folder, https://github.com/rupa/z | |
. $HOME/z.sh |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment