I've been coding in a particular file for too long without committing, and I've ended up with a situation where I want to commit feature (A) that removes a line of code. But, in my file, I also have work on feature (B) that adds a new line of code in the place of the code removed by feature (A).
In order to commit feature (A), I want to commit the change that deletes the original line. I don't want to commit the change that adds the new line from feature (B).
How do I just commit the deletion of the line, and leave the addition as an unstaged change?
