Skip to content

Instantly share code, notes, and snippets.

@MassivDash
Last active September 27, 2022 20:19
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save MassivDash/7e1081e3623add4061ec76652107ce25 to your computer and use it in GitHub Desktop.
Save MassivDash/7e1081e3623add4061ec76652107ce25 to your computer and use it in GitHub Desktop.
.zshrc aliases and helpers for mac and ubuntu
# GIT Aliases
alias commit='f(){
echo "commiting $@" ;
git add . ;
git commit -m "$1";
unset -f f;
}; f'
alias push="git push"
alias pushb='f(){
echo "pushing to origin" ;
git push --set-upstream origin $@ ;
unset -f f;
}; f'
alias glog="git log --graph --decorate --oneline"
alias reflog="git reflog HEAD"
alias gkup='f(){
git log --author="\(Celitan\)" --since="$@" -p > kup.txt;
}; f'
# Node Aliases
alias killNode="killall -9 KILL node"
alias findPort='f(){
echo "killing port $@";
lsof -n -i4TCP:$1
unset -f f
}; f'
# Npm Aliases
# List all global packages installed
alias nGlob="npm list -g --depth 0"
# Helper Aliases
alias copypath='pwd|pbcopy'
alias ..="cd .."
alias ...="cd ../.."
alias l.='ls -d .* --color=auto'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment