maurobaraldi

.gitconfig

Jul 11th, 2013
75
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.15 KB | None | 0 0
  1. [core]
  2. excludesfile = ~/.gitignore
  3. autocrlf = input
  4. editor = vim # If you uses emacs, you are poser!!
  5. pager = less -R
  6.  
  7. [user]
  8. name = Mauro Baraldi
  9.  
  10. [color]
  11. branch = auto
  12. diff = auto
  13. status = auto
  14. interactive = auto
  15.  
  16. [color "branch"]
  17. current = yellow
  18. local = blue
  19. remote = green
  20.  
  21. [color "diff"]
  22. meta = yellow bold
  23. frag = magenta bold
  24. old = red bold
  25. new = green bold
  26.  
  27. [diff]
  28. external = /home/mauro/.hooks/diff.py
  29.  
  30. [github]
  31. user = maurobaraldi
  32.  
  33. [status]
  34. showUntrackedFiles = no
  35.  
  36. [alias]
  37. # Basics
  38. a = add
  39. b = branch
  40. c = commit
  41. d = diff
  42. f = fetch
  43. l = log
  44. m = merge
  45. o = checkout
  46. p = pull
  47. ps = push
  48. r = reset
  49. s = status
  50.  
  51. # == Sugar Sintaxes ==
  52.  
  53. # branch
  54. branches = branch -a # List all branches (local + remotes)
  55.  
  56. # log
  57. activity = log --oneline --graph --decorate # Show activity (log) most like gitk deafult view
  58. history = log --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit --
  59. unadd = git reset HEAD # remove a file from index
  60. what = "!f() { git log --author=$1; }; f" # Show what was done by user
  61. between = "!f() { git log --since=$1 --until=$2; }; f" # Show what was done by range date
  62. files = "!f() { git diff-tree --no-commit-id --name-only -r $1; }; f" # Show files changed in a given commit
  63.  
  64. whatis = show -s --pretty='tformat:%h (%s, %ad)' --date=short
  65. whois = "!sh -c 'git log -i -1 --pretty=\"format:%an <%ae>\n\" --author=\"$1\"' -"
  66. tagit = "!f() { git tag $(date +'%Y%m%d_%H%M'); }; f"
  67. goodmorning = "!sh -c 'git checkout develop; git pull; make'"
  68. merged = branch -a --merged # Show merged branchs (remote/local)
  69. unmerged = branch -a --no-merged # Show unmerged branchs (remote/local)
  70. diffs = "!for i in `git diff --name-only`; do git diff $i; done"
  71. checkallout = "!for i in `git diff --name-only`; do git checkout $i; done"
  72. sync = "!git pull && git push"
  73. cam = commit -am
Advertisement
Add Comment
Please, Sign In to add comment