Re: Restore a single file in the index back to HEAD

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 10/27/06, Junio C Hamano <junkio@xxxxxxx> wrote:
On the other hand, I designed --index-info to be compatible with
ls-tree output (it is not an accident, it was designed).  In

        git ls-tree HEAD frotz | git update-index --index-info

"frotz" part does not have to be the exact path but can be a
directory name.  It means "revert everything in this directory".

This is quite heavy-handed and you would probably want to run
update-index --refresh afterwards.

I would prefer "git update-index --reset frotz" or "git checkout
--index HEAD frotz". git ls-tree|git update-index is too cryptic for
me and too long for my fingers.
--
Duy
-
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]