config 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. [user]
  2. name = Thomas Dy
  3. email = thatsmydoing@gmail.com
  4. [merge]
  5. conflictstyle = zdiff3
  6. [core]
  7. autocrlf = input
  8. hooksPath = ~/.config/git/hooks
  9. untrackedcache = true
  10. [delta]
  11. features = side-by-side line-numbers decorations
  12. whitespace-error-style = 22 reverse
  13. [delta "decorations"]
  14. commit-decoration-style = bold yellow box ul
  15. file-style = bold yellow ul
  16. file-decoration-style = none
  17. [color]
  18. ui = true
  19. [diff]
  20. algorithm = histogram
  21. [difftool]
  22. prompt = false
  23. [difftool "difft"]
  24. cmd = difft "$LOCAL" "$REMOTE"
  25. [push]
  26. default = current
  27. [branch]
  28. # we use a hook to set this up instead
  29. autoSetupMerge = false
  30. sort = -committerdate
  31. [remote]
  32. pushDefault = origin
  33. [alias]
  34. root = !pwd
  35. lg = "log --color --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr)%C(bold blue)<%an>%Creset' --abbrev-commit"
  36. p = push
  37. pf = push --force-with-lease
  38. # history fast-forward (to push)
  39. hff = merge --ff-only @{push}
  40. # history reset hard (to push)
  41. hrh = reset --hard @{push}
  42. # head's history fast-forward (works even if a different branch is checked out)
  43. hhff = "!git push . $(git head)@{upstream}:$(git head)"
  44. # head's history reset hard
  45. hhrh = hhff --force
  46. # rebase upstream
  47. ru = rebase @{upstream}
  48. # rebase interactive upstream
  49. riu = rebase -i @{upstream}
  50. # rebase interactive autosquash upstream
  51. riau = rebase -i --autosquash @{upstream}
  52. ca = commit --amend
  53. smash = "!git add -u && git ca --no-edit && git pf"
  54. reset-head = remote set-head origin -a
  55. head = for-each-ref --format="%(symref:lstrip=-1)" refs/remotes/origin/HEAD
  56. sh = "!git switch $(git head)"
  57. [include]
  58. path = ./config.local