Last active
July 10, 2023 03:26
-
-
Save benrowe/3ab0634d25ed95ba0abd36775e6a2c9e to your computer and use it in GitHub Desktop.
Local machine 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
alias dk_restart="osascript -e 'quit app \"Docker\"' && open -a Docker" | |
alias dkps="docker ps --format '{{.ID}} - {{.Names}} - {{.Status}} - {{.Image}}'" | |
alias dk="docker" | |
alias dkl="docker logs" | |
alias dklf="docker logs -f" | |
alias dki="docker images" | |
alias dks="docker service" | |
alias dkrm="docker rm" | |
alias dkrmi="docker rmi" |
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
[user] | |
name = {user.fullname} | |
email = {user.email} | |
[commit] | |
template = /Users/{user.login}/.stCommitMsg | |
[url "ssh://[email protected]/"] | |
insteadOf = https://github.com/ | |
[push] | |
default = current | |
[pull] | |
ff = only | |
[init] | |
defaultBranch = master | |
[rebase] | |
autoStash = true | |
[alias] | |
ls = log --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit --date=relative | |
ll = log --pretty=format:"%C(yellow)%h%Cred%d\\ %Creset%s%Cblue\\ [%cn]" --decorate --numstat | |
search = "!f() { git log -p -S \"$1\" -- \"${2:-.}\"; }; f" | |
filelog = log -u | |
fl = log -u | |
a = add | |
ap = add -p | |
cm = commit -m | |
cp = cherry-pick | |
f = fetch | |
p = push | |
d = diff | |
ds = diff --stat | |
dc = diff --cached | |
dd = diff develop..HEAD --name-status | |
stat = shortlog -s -n --all --no-merges | |
s = status -s -uall | |
co = checkout | |
cob = checkout -b | |
cop = checkout -p | |
stl = stash list | |
del = branch -D | |
b = "!git for-each-ref --sort='-authordate' --format='%(authordate)%09%(objectname:short)%09%(refname)' refs/heads | sed -e 's-refs/heads/--'" | |
ba = "!git for-each-ref --format='%(authordate)%09%(objectname:short)%09%(refname)' refs | grep -i 'heads\\|remotes' | sed -e 's-refs/heads/--' | sed -e 's-refs/remotes/--'" | |
track = "!git push -u origin $(git symbolic-ref --short HEAD)" | |
undo-commit = reset --soft HEAD~1 | |
ahead = "!git rev-list --left-right --count origin/master...HEAD | awk '{print \"behind: \"$1, \"ahead: \"$2}'" | |
# show aliases | |
la = "!git config -l | grep alias | cut -c 7-" | |
tidy = "!git remote prune origin && git branch --merged >/tmp/merged-branches && vi /tmp/merged-branches && xargs git branch -d </tmp/merged-branches" | |
rbod = rebase origin/develop | |
rbom = rebase origin/master |
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
ZSH_THEME="af-magic" | |
plugins=( | |
git | |
zsh-autosuggestions | |
) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
thanks!