The other day I had accidentally committed a file that worked on my machine but failed on everyone else's. I was unaware that this change was committed, and thus a little flurry of emails was sent around to everybody *but* me (more on this later). Then finally a solution was sent around to which I was CC'd. It said that the appropriate changes had been made, and we can all relax now. I take issue with the last part of that email because this one simple command happens to exist: `git checkout master~5 FILE`.
Whew, the mild anger that may have been expressed is over.
So there are some things to be learned from this:
Forgive Easily
This is more in the sense of code, rather than people, although it certainly applies to both. Tom Mornini once said to me, "Rubinius forgives easily", in that if I make a mistake, then the error can be easily reverted, no harm done; this is where `git checkout` comes in! With this neat-o command, you can revert was was wronged in about the 5 seconds it takes to review `git log` and type the proper command, and then you can be on your merry little way. "But wait, Mr. Seydar! How does this apply to things when multiple files got fucked up?" Real simple, champ: `git checkout master~5 .` will have you back on the road in no time.
Typical Social Network
And of course, here's why I wasn't contacted initially as soon as the issue reared its ugly head - I'm not in their usual social network, and we're all working on this in our spare time! True, I *should've* been contacted, but I wasn't, because they don't think "Hey, did I include that kid?".
So let's get a nice quick lil' summary of what's up here: I learned two good lessons, one of which has already been drilled into my head (the first one). This experience was good because I got to learn the second lesson, the one about why things can happen.
Forgive easily and include your entire work team in your social network. Done. QEMFD