Skip to content

Instantly share code, notes, and snippets.

@ademar111190
Last active January 12, 2019 17:47
Show Gist options
  • Save ademar111190/f7a1601c6fef4fe2226ce7352a718d0e to your computer and use it in GitHub Desktop.
Save ademar111190/f7a1601c6fef4fe2226ce7352a718d0e to your computer and use it in GitHub Desktop.
Some .zprofile commands
.profile_secrets
vim
#!/usr/bin/env bash
case "$(uname -s)" in
Darwin)
OS="MAC"
export $OS
;;
Linux)
OS="LINUX"
export $OS
;;
esac
source ~/.profile_paths
source ~/.profile_secrets
source ~/.profile_alias
neofetch
# typos
alias gti=git
alias got=git
alias gt=git
alias g=git
alias goit=git
alias giut=git
alias cd..="cd .."
# custom commands
case $OS in
LINUX)
alias pbcopy='xclip -selection clipboard'
alias pbpaste='xclip -selection clipboard -o'
;;
esac
alias copyCmd='fc -ln -1 | awk '\''{$1=$1}1'\'' | pbcopy'
alias random='function _random() { echo $(($RANDOM % $1 + 1)); }; _random'
alias ip="curl -s checkip.dyndns.org | sed -e 's/.*Current IP Address: //' -e 's/<.*$//'"
case $OS in
MAC)
export ANDROID_HOME="${HOME}/Library/Android/sdk"
export JAVA_HOME=$(/usr/libexec/java_home)
;;
LINUX)
export ANDROID_HOME="TODO"
export JAVA_HOME="/usr/bin/java"
;;
esac
PATH="${ANDROID_HOME}:${PATH}"
PATH="${ANDROID_HOME}/platform-tools:${PATH}"
PATH="${ANDROID_HOME}/tools:${PATH}"
PATH="${ANDROID_HOME}/emulator:${PATH}"
PATH="${ANDROID_HOME}/tools/bin:${PATH}"
PATH="/Library/Frameworks/Python.framework/Versions/3.6/bin:${PATH}"
PATH="/Applications:${PATH}"
export PATH
export DOTZ="${HOME}/Workspace/dotz-android"
export DOTZ_CORE="${HOME}/Workspace/dotz-android/Dotz/libraries/core"
export FOXBIT="${HOME}/Workspace/foxbit-android"
export YODA="${HOME}/Workspace/foxbit-yoda-study"
export NICOLAS="${HOME}/Workspace/porquenao-slackbot"
export REVENGE="${HOME}/Workspace/porquenao-crypto-revenge-android"
export REVENGE_FIREBASE="${HOME}/Workspace/porquenao-crypto-revenge-firebase"
" Plugins will be downloaded under the specified directory.
call plug#begin('~/.vim/plugged')
" Declare the list of plugins.
Plug 'https://github.com/junegunn/vim-easy-align.git'
Plug 'https://github.com/junegunn/vim-github-dashboard.git'
Plug 'https://github.com/sirver/UltiSnips.git'
Plug 'https://github.com/honza/vim-snippets.git'
Plug 'https://github.com/scrooloose/nerdtree.git'
Plug 'https://github.com/Xuyuanp/nerdtree-git-plugin.git'
" List ends here. Plugins become visible to Vim after this call.
call plug#end()
" Genral
autocmd FileType * set tabstop=2|set shiftwidth=2|set noexpandtab
:nmap <c-s> :w<CR>
:imap <c-s> <Esc>:w<CR>a
" Nerd tree
let NERDTreeShowHidden=1
map <c-t> :NERDTreeToggle<CR>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment