Gitting like a Pro

Gitting like a Pro

Git recipes for healthier coding

39faa5e8e938d2fbd92acc2e8ebdf65b?s=128

Stratos Pavlakis

June 13, 2017
Tweet

Transcript

  1. GITTING LIKE A PRO git recipes for healthier coding

  2. Stratos Pavlakis UI Tech Lead @ Workable https://github.com/th3hunt https://twitter.com/th3hunt who

    is this guy?
  3. Developers agreeing on Git work ow Jacques-Louis David, 1796-1799 Oil

    on Canvas
  4. No need for such drama - Git knowledgeable developer

  5. Git Anatomy

  6. $ ls -F1 .git HEAD config description hooks/ info/ objects/

    refs/
  7. Now the secret to make the most out of a

    tool is ...
  8. to make it accessible!

  9. con guration

  10. # do some less typing git config --global alias.co checkout

    git config --global alias.st status # shell out if needed la=!git config -l | grep alias | cut -c 7- # style your output log --graph \ --pretty=format':%C(yellow)%h%C(auto)%d%Creset %Creset%s %C(242)<%an>%Creset'
  11. Git Recipes

  12. KEEP A READABLE HISTORY REBASE don't merge Fixup Autosquash

  13. Programmer nds 1395 con icts after ‘git rebase develop’ 3

    days before the deadline Gustav Courbet, 1844–1845 Oil paint
  14. ESCAPE GROUNDHOG DAY AND KEEP YOUR SANITY git rerere WTF

    dude? no really... git rerere
  15. FIND THE NEEDLE IN THE HAYSTACK bisect bisect on autopilot

  16. JUMP BETWEEN BRANCHES LIKE A PRO git worktree add

  17. REVERT A BRANCH Find the mainline parent (X) git cat-

    le -p <merge-commit> Revert the merge commit git revert -m X <merge-commit>
  18. HARDCORE MAGIC lter_branch replace

  19. Thank you! Questions?