git / git-reference

Online Git Reference at http://git.github.io/git-reference/
Other
996 stars 363 forks source link

Confusion about git-mv #2

Closed alco closed 12 years ago

alco commented 14 years ago

Hi. In the section http://gitref.org/basic/#rm-mv you are saying that git-rm is equivalent to three commands: git rm orig mv orig new git add new

Although you emphasize it clearly that git rm removes files from disk, the above example doesn't conform to that. After executing git rm orig, the orig file will be removed from disk, so there will be nothing to apply the mv command to. This may lead to some confusion for novice git users. You should probably add --cached option, like this: git rm --cached orig mv orig new git add new

schacon commented 14 years ago

ah yes, you're right.

ComputerDruid commented 14 years ago

I'm pretty sure this was recently fixed when he pulled my commit to fix it. it appears fixed on gitref.org as well