dotfiles

My personal shell configs and stuff
git clone git://git.alex.balgavy.eu/dotfiles.git
Log | Files | Refs | Submodules | README | LICENSE

gitconfig (5437B)


      1 ; vim: syntax=gitconfig
      2 [include]
      3   path = identity
      4   ; this file isn't in the repo
      5   ; sets user.name, user.email, and init.templatedir
      6 
      7 [alias]
      8     s = status
      9     wt = worktree
     10     v = "!nvim -c 'Git | only'"
     11     co = checkout
     12     cob = checkout -b
     13     f = fetch --all
     14     fapr = fetch --all --prune
     15     b = branch
     16     br = branch --remote
     17     ba = branch --all
     18     bv = branch -vv
     19 
     20     lg = log --graph --abbrev-commit --decorate --format=format:'%C(bold blue)%h%C(reset) - %C(bold green)(%ar)%C(reset) %C(white)%s%C(reset) %C(dim white)- %an%C(reset)%C(bold yellow)%d%C(reset)' --branches --remotes --tags --oneline --author-date-order
     21     lgv = log --graph --abbrev-commit --decorate --format=format:'%C(bold blue)%h%C(reset) - %C(bold cyan)%aD%C(reset) %C(bold green)(%ar)%C(reset)%C(bold yellow)%d%C(reset)%n''%w(130,10,10)%C(white)%s%C(reset) %C(dim white)- %an%C(reset)' --all --author-date-order
     22     llg = log --graph --abbrev-commit --decorate --format=format:'%C(bold blue)%h%C(reset) - %C(bold green)(%ar)%C(reset) %C(white)%s%C(reset) %C(dim white)- %an%C(reset)%C(bold yellow)%d%C(reset)' --oneline --author-date-order
     23     llgv = log --graph --abbrev-commit --decorate --format=format:'%C(bold blue)%h%C(reset) - %C(bold cyan)%aD%C(reset) %C(bold green)(%ar)%C(reset)%C(bold yellow)%d%C(reset)%n''%w(130,10,10)%C(white)%s%C(reset) %C(dim white)- %an%C(reset)' --all --author-date-order
     24     llgvv = log --graph --abbrev-commit --decorate --format=format:'%C(bold blue)%h%C(reset) - %C(bold cyan)%aD%C(reset) %C(bold green)(%ar)%C(reset)%C(bold yellow)%d%C(reset)%n''%w(130,13,13)%C(white)%s%C(reset) %C(dim white)- %an <%ce> (comm. %cn <%ce>)%C(reset)%n''%w(64,18,18)%b'  --all
     25     today = lgv --since='midnight'
     26     yesterday = lgv --since='yesterday midnight' --until='midnight'
     27     this-week = lgv --since='last-monday'
     28     past-week = lgv --since='1 weeks ago'
     29     cbsr-sprint = lgv --since='last-tuesday' --until='this-tuesday'
     30     adog = log --all --decorate --oneline --graph
     31     dog = log --decorate --oneline --graph
     32 
     33     authors = !git log --all --format='%cN <%cE>' | sort -u
     34 
     35     a = add
     36     ap = add -p
     37     af = "!git ls-files -m -o --exclude-standard | fzf --print0 -m --reverse --height=20% | xargs -0 -t -o git add"
     38     fa = af
     39     fzf = "!git ls-files -mo --exclude-standard | fzf -m --reverse --height=20%"
     40 
     41     c = commit
     42     cm = commit -m
     43     cam = commit -a -m
     44     ca = commit -a
     45     camende = commit --amend
     46     camend = commit --amend --no-edit
     47     cp = commit -p
     48 
     49     rp = reset -p
     50 
     51     ss = stash push
     52     sp = stash pop
     53     sa = stash apply
     54     sd = stash drop
     55     sl = stash list
     56 
     57     blame = "blame -w -C -C -C" # ignore whitespace, look for code movement, in multiple commits, for all commits
     58     diffs = "diff --staged"
     59     diffw = "diff --word-diff"
     60     changes = diff --summary --stat
     61     changess = changes --staged
     62     mergetest = merge --no-commit
     63     testmerge = mergetest
     64     mno = merge --no-ff
     65     mff = merge --ff-only
     66     delete-merged = "!git checkout master && git branch --merged | grep -v '\\*' | xargs -n 1 git branch -d && git fetch --all --prune"
     67     p = push
     68     pushf = push --force-with-lease
     69     pf = pull --ff-only
     70     pff = pull --ff-only
     71     fuckit = reset --hard HEAD
     72     fuckitall = reset --hard origin/master
     73     ssh = "!git remote get-url origin | sed -E 's|^https?://([^/]+)/(.+)|git@\\1:\\2|' | tr -d '\n'"
     74     home = "!f(){ git remote get-url \"${1:-origin}\" | sed -E 's|^git@([^:]+):|https://\\1/|' | tr -d '\n'; }; f"
     75     open = "!f(){ open $(git home \"$1\"); }; f"
     76     dad = "!curl https://icanhazdadjoke.com/ && echo && git add"
     77     reignore = "!git rm -r --cached .; git add ."
     78     rebase = "rebase --committer-date-is-author-date"
     79     rc = "rebase --continue"
     80     lfs-refs = "!git fetch --all && git log -p --all -S"
     81     chp = cherry-pick
     82     chpn = cherry-pick --no-commit
     83 
     84     la = "!git config -l | grep alias | cut -c 7-"
     85     rv = remote -v
     86 
     87     subget = submodule update --init
     88     subdate = submodule update --remote
     89     substatus = submodule status
     90     subactive = "!git submodule status | grep -v '^-'"
     91     subdel = "!f(){ set -x; git submodule deinit -f "$1"; rm -rf .git/modules/"$1"; git rm -f "$1"; set +x; }; f"
     92 
     93     root = !git rev-parse --show-toplevel | tr -d '\n'
     94 
     95     edit-changed = "!$EDITOR `git status --porcelain | sed -ne 's/^ M //p'`"
     96     commit-at = "!f(){\
     97     if [ $# -eq 0 ]; then\
     98     echo \"Date format: YYYY-MM-DD HH:MM:SS\";\
     99     else\
    100     GIT_COMMITTER_DATE=\"$1\" GIT_AUTHOR_DATE=\"$1\" git commit;\
    101     fi; }; f"
    102 
    103     df = !git --git-dir=$DOTFILES/.git --work-tree=$DOTFILES
    104 
    105 [submodule]
    106     recurse = 1
    107 [merge]
    108     tool = nvimdiff
    109     conflictstyle = diff3
    110 
    111 [mergetool "nvimdiff"]
    112     cmd = nvim -d \"$LOCAL\" \"$MERGED\" \"$BASE\" \"$REMOTE\" -c \"wincmd w\" -c \"wincmd J\"
    113 [diff]
    114   algorithm = histogram
    115 [core]
    116     autocrlf = input
    117 
    118 [filter "lfs"]
    119     clean = git-lfs clean -- %f
    120     smudge = git-lfs smudge -- %f
    121     process = git-lfs filter-process
    122     required = true
    123 [init]
    124     defaultBranch = master
    125 [rerere]
    126     # remember how I solved a merge conflict and reuse it
    127     enabled = true
    128     # automatically stage the reuse
    129     autoUpdate = true
    130 # Use ssh key to sign commits
    131 [gpg]
    132     format = ssh
    133 [credential]
    134 	helper = /usr/share/doc/git/contrib/credential/libsecret/git-credential-libsecret
    135 	#helper = cache
    136 [transfer]
    137     fsckobjects = true
    138 [fetch]
    139     fsckobjects = true
    140 [receive]
    141     fsckobjects = true