

GitHub - Shiny new commit styles - remi
https://github.com/blog/926-shiny-new-commit-styles

======
akkartik
I'm not sure how I feel about the present-tense dictum. When I commit
frequently most of my commit messages end up in present tense anyway, but
sometimes they don't, and it all still reads pretty well. I think the emphasis
should be on frequent commits which keep the narrative of a codebase coherent
and chugging along.

Here's an example changelog:
<http://github.com/akkartik/wart/commits/unstable>. Criticisms?

~~~
chousuke
I think the present tense recommendation comes from the expectation that each
commit works as a stand-alone patch. Thus the commit message does not describe
what changes you did to the repository, but what the _patch does_ to it.

Git provides a wealth of tools to craft perfect commits, and if you use them,
it's not difficult to end up with a nice history of "add this, remove that,
modify something else" changesets that (usually) would make sense even when
separated from the surrounding history.

~~~
akkartik
_"Git provides a wealth of tools to craft perfect commits"_

Pointers please?

~~~
chousuke
Others already mentioned rebasing, but I think the most important tool is the
index, or "the staging area". Lots of people not used to Git tend to see the
index as an unnecessary extra step, but it's really what enables the good
stuff.

In short, the index allows you to decide what goes in a single commit,
regardless of the actual contents of a working directory. You can commit only
a single line from a file if you want. If you learn how the index works and
why it works like it does, understanding the rest becomes much easier.

You can also eg. resolve a conflict piece-by-piece by adding resolved parts to
the index, diffing against the working directory, and then finally committing
once the content of the index looks correct.

There are many tutorials and I'm not sure which one is the best but I think
the book "Pro Git" does a good job at explaining the index among other things.
It's freely available online at <http://progit.org>

~~~
akkartik
Sorry I read your original as 'crafting perfect commit _messages_ '.

------
lenary
is it just me, or does anyone else think that though the design is prettier,
it kinda makes other parts of the app look bad - for instance compare the
commit style to the tree listings. it's not that one or the other look bad,
it's just the dissimilarity is jarring.

~~~
wrl
I agree, the new commits use a different motif than the old ones and it
definitely looks odd (especially on the code tree pages). Maybe this is the
sign of a coming design refresh?

~~~
zacclark
I think it is, check out Kneath's (a designer at github) dribble:

<http://dribbble.com/kneath>

------
extramoose
GitHub is doing a fantastic job of building a consistent presence from top to
bottom. The changes as a whole have been extremely impressive over the past
few months. I, as a designer that uses GitHub on a daily basis at work, am
very enthusiastic about the latest updates, the new commit styles included.
The GitHub team has been extremely quick to iterate and launch updates
recently. I'm sure there's plenty more to come.

------
foobarbazetc
Update GitHub:FI, please. :(

------
Kwpolska
You shall say that it's on GitHub in the title.

~~~
remi
You’re right; I didn’t realize I could edit the title after I posted it.

