Skip to content

Instantly share code, notes, and snippets.

@codeluggage
Last active November 19, 2022 23:04
Show Gist options
  • Save codeluggage/a48f71a65b9ad0e4846b to your computer and use it in GitHub Desktop.
Save codeluggage/a48f71a65b9ad0e4846b to your computer and use it in GitHub Desktop.
Somewhat sensible .zshrc for those using Oh-My-Zsh, iTerm2, Android Studio, Xcode, and general git work.
export ZSH=$HOME/.oh-my-zsh
# Set name of the theme to load.
# Look in ~/.oh-my-zsh/themes/
# Optionally, if you set this to "random", it'll load a random theme each
# time that oh-my-zsh is loaded.
ZSH_THEME="robbyrussell"
# Uncomment the following line to use case-sensitive completion.
# CASE_SENSITIVE="true"
# Uncomment the following line to disable bi-weekly auto-update checks.
# DISABLE_AUTO_UPDATE="true"
# Uncomment the following line to change how often to auto-update (in days).
# export UPDATE_ZSH_DAYS=13
# Uncomment the following line to disable colors in ls.
# DISABLE_LS_COLORS="true"
# Uncomment the following line to disable auto-setting terminal title.
# DISABLE_AUTO_TITLE="true"
# Uncomment the following line to enable command auto-correction.
# ENABLE_CORRECTION="true"
# Uncomment the following line to display red dots whilst waiting for completion.
# COMPLETION_WAITING_DOTS="true"
# Uncomment the following line if you want to disable marking untracked files
# under VCS as dirty. This makes repository status check for large repositories
# much, much faster.
# DISABLE_UNTRACKED_FILES_DIRTY="true"
# Uncomment the following line if you want to change the command execution time
# stamp shown in the history command output.
# The optional three formats: "mm/dd/yyyy"|"dd.mm.yyyy"|"yyyy-mm-dd"
# HIST_STAMPS="mm/dd/yyyy"
# Would you like to use another custom folder than $ZSH/custom?
# ZSH_CUSTOM=/path/to/new-custom-folder
# Which plugins would you like to load? (plugins can be found in ~/.oh-my-zsh/plugins/*)
# Custom plugins may be added to ~/.oh-my-zsh/custom/plugins/
# Example format: plugins=(rails git textmate ruby lighthouse)
# Add wisely, as too many plugins slow down shell startup.
plugins=(git)
source $ZSH/oh-my-zsh.sh
# User configuration
#export PATH="/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/Users/mf/Installs/adt-bundle-mac-x86_64/sdk/platform-tools:/Users/mf/Installs/adt-bundle-mac-x86_64/sdk/tools"
export PATH="/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/Applications/AndroidStudio.app/sdk/platform-tools:/Applications/AndroidStudio.app/sdk/tools"
# export MANPATH="/usr/local/man:$MANPATH"
# Compliance with various gems, etc. for language settings in the terminal:
export LANG=en_US.UTF-8
# Preferred editor for local and remote sessions
# if [[ -n $SSH_CONNECTION ]]; then
# export EDITOR='vim'
# else
# export EDITOR='mvim'
# fi
# Compilation flags
# export ARCHFLAGS="-arch x86_64"
# ssh
# export SSH_KEY_PATH="~/.ssh/dsa_id"
# Use vim as man page viewer
# export PAGER=/usr/local/bin/vimpager
# alias less=$PAGER
# alias zless=$PAGER
# ls after cd
function chpwd() {
emulate -L zsh
ls -la && echo "----------------------------"
}
# Aliases
## For a full list of active aliases, run `alias`.
# Use browser as man page viewer
function manh() { open -a /Applications/Safari.app man://$@ ;}
alias VIMZSHRC="vim ~/.zshrc"
alias SOURCEZSHRC="source ~/.zshrc"
alias LAYUP="cd ~/Google\ Drive/Cipio/source/"
alias LAYUPmobile"cd ~/Google\ Drive/Cipio/source/Swish/"
alias SUBLIMEUSER="cd ~/Library/Application\ Support/Sublime\ Text\ 3/Packages"
alias SUBLIMEAPP="cd /Applications/Sublime\ Text.app/Contents/MacOS/Packages"
alias MEETAPP="cd ~/Google\ Drive/MeetApp/MeetApp"
alias NORDICBREEZE="cd ~/Google\ Drive/Projects/NordicBreeze"
alias PROJECTS="cd ~/Google\ Drive/Projects"
alias s="sublime"
alias v="vim"
alias c="clear"
alias t='tree -C -I "node_modules" && echo "Performing tree recursively, excluding node_modules"'
alias l="ls -la"
# git
alias g="git"
alias gs="git status --short"
alias gc="git commit"
alias gcl="git clone"
alias gaa="git add --all"
alias gl="git log"
alias glg="git log --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit"
alias gdc="git diff"
alias gdcc="git diff --cached"
alias m="meteor"
# heroku
alias h="heroku"
# ionic
alias ibi="ionic build ios"
alias iba="ionic build android"
alias iei="ionic emulate ios"
eval "`npm completion`"
### Added by the Heroku Toolbelt
export PATH="/usr/local/heroku/bin:$PATH"
export PATH="$PATH:$HOME/.rvm/bin" # Add RVM to PATH for scripting
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment