Hacker News new | past | comments | ask | show | jobs | submit login

I will play a devil's advocate.

What about white space sensitive language like Python (that's one of things I hate about the language)?

Diff also gets easily confused, because its context window is pretty small.




I'm repeating my comment in a sibling thread, but I think it's worth repeating (paraphrasing) -

(A) If the thing you have in mind can be inferred by looking at two commits, then you don't have to record the intention of the changes into the version control system because you can compute it later when needed.

(B) If the thing you have in mind can't be reliably inferred by looking at two commits, then you need some other way to tell the version control system about your intention.

For example, if you're just re-indenting a python source file, are you going to:

1. expect the system to automatically/heuristically realize you're just re-indenting it --> see (A)

2. explicitly tell the system that you've reindented it when making the commit --> are you sure you're bothered to do that?

3. Consistently and exclusively use a specialized IDE that records all your actions and transforms it to the corresponding intentions as recognized by the version control system?


There are alternate diff algorithms that can be selected within even standard git diff. It's just stuck on the traditional one as the default.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: