April 16, 2009
Git is frustrating
I love version control systems. I especially love versioning systems that are distributed. It's total geek porn. Having learned that Python recently decided to switch from Subversion to Mercurial, I decided to see what made Mercurial so special. Besides, I was previously using Git and found it incredibly frustrating, so why not?
Some people claim that Git's killer feature is its index. What's the index you ask? You can think of it like a staging area before you actually commit a change. If you change a file, you must "git add" the changes to the index, then commit the change. This makes committing a three stage process:
- Modify files
-
Add the modifications to the index (
git add [files]) -
Commit the modified index (
git commit)
Having to do this three stage process on each checkin seems silly (yes, I know about git commit -a, and the benefits of the index). But all I want to do is commit a change. I don't want to have to think about the index, staging, and all the other little "killer features" of git. I found myself spending more time learning out to use Git than I was coding. Don't get me wrong, I love learning about version control systems, but this was borderline ridiculous.
Then the day came when I tried to check in a file with extra whitespace. Git flat out refused to let this happen.
# git commit
* You have some suspicious patch lines:
*
* In test.py
* trailing whitespace (line 20)
Why is the VCS inspecting the contents of my code? Shouldn't it be totally agnostic to the contents of the file?
Posted by J.P. Cummins ● Comments (1)
Comments
Joshua Kugler April 17, 2009 at 1:22 p.m.
Somebody apparently added a pre-commit hook to your repository.
Commenting is disabled after one week.