by K0nserv · 7y ago · 0 comments
https://github.com/k0nserv/dotfiles/blob/7721559be40bba09cd8...
alias gs="g status"
alias glff="git pull --ff-only"
alias glffc="git pull origin \$(current_branch) --ff-only"
alias glc="git pull origin \$(current_branch)"
alias gpc="git push origin \$(current_branch)"
alias gpcfl="git push origin \$(current_branch) --force-with-lease"
function goops { git add -A "$@" && git commit --amend --no-edit && gpcfl }
alias gbr="git branch -r"
alias grm="git branch --merged | grep -v \"\*\" | xargs -n 1 git branch -d"
function mkb() {
git fetch && git checkout -b "$1" origin/master
}
`mkdataenv` is nice for spinning up a quick Jupyter environment for all data analysis needs.https://github.com/k0nserv/dotfiles/blob/7721559be40bba09cd8...
function mkdataenv() {
mkvirtualenv --python /usr/local/bin/python3 $1
workon $1
mkdir "$1"
cd $1
pip install pandas jupyter numpy matplotlib seaborn
pip freeze > requirements.txt
jupyter notebook
} alias.alias config --global --get-regexp ^alias
I really like blameconflict: alias.blameconflict blame -L '/^<<<</,/^>>>>/' g fp # git fetch --prune
...
g rb origin/master master # rebase
g co -
A lot of tab and very few keys in general when working with git.My favorite aliases in this context are
alias wow=git
alias such=git
alias many=git
alias awesome=git
alias much=git