Skip to Content
Navigation:

A stick figure smiling

If you want to see more comics like this, sign up for my saturday comics newsletter or browse more comics!

Image of a comic. To read the full HTML alt text, click "read the transcript".

browse more comics! get the zine!
read the transcript!

HEAD is a tiny file containing the name of the current branch

Diagram of three boxes in a row, joined by lines. One has a heart, one has a star, and one has a squiggle. The final one, with the squiggle, is labelled “main”.

HEAD = main
main = [squiggle]

when you commit, git updates the current branch to point at the new commit

Diagram of three boxes in a row, joined by lines. One has a heart, one has a star, and one has a squiggle. The final one, with the squiggle, is labelled “main”.

HEAD = main
main = [squiggle]

Diagram of four boxes in a row, joined by lines. One has a heart, one has a star, one has a squiggle, and one has a spiral. The final one, with the spiral, is labelled “main”.

HEAD = main
main = [spiral]

SO MANY things in git use the current branch

  • git commit moves it forward
  • git merge merges into it
  • git rebase copies commits from it
  • git push and git pull sync it with a remote

many git disasters are caused by accidentally running a command while on the wrong branch

Illustration of a sad stick figure

person: git commit
person, thinking: UGH I didn’t mean to do that on main

I keep my current branch in my shell prompt

~/work/homepage (main) $

to me it’s as important as knowing what directory I’m in

panel 6

Illustration of a smiling stick figure with curly hair.

person: I think HEAD is a weird name for the current branch (why not CURRENT or something?) but we’re stuck with it

This is a page from a zine on git I'm currently writing. To get an email when the zine comes out, sign up for our announcements list:

Saturday Morning Comics!

Want another comic like this in your email every Saturday? Sign up here!

I'll send you one of my favourite comics from my archives every Saturday.
© Julia Evans 2024 | All rights reserved (see the FAQ for notes about licensing)