git reset and newly created files.

2005-08-21 Thread Junio C Hamano
When you made a mistake and committed a set of incomplete changes, the git reset command comes handy. ... Edit, compile, and test. $ git commit -s -m 'The perfect change.' ... Test again, OOPS it fails --- it was not perfect. $ git reset HEAD^ foo: needs update bar: needs

Re: git reset and newly created files.

2005-08-21 Thread Sam Ravnborg
So you would naturally be tempted to do this: ... Re-edit, compile, and test. This time it is perfect. $ git commit -a -C ORIG_HEAD Well, not really. You can lose any file newly created in ORIG_HEAD this way. Instead, you need to do this: ... Re-edit, compile, and