Re: What to expect after GIT 0.99.7
- From
Petr Baudis <pasky@suse.cz>
- Date
- Sep 19, 2005, 08:36 UTC
- Message-ID
- <20050919083650.GA22269@pasky.or.cz>
- In-Reply-To
- <7vwtldsbv2.fsf@assigned-by-dhcp.cox.net>
Dear diary, on Mon, Sep 19, 2005 at 10:25:21AM CEST, I got a letter where Junio C Hamano <junkio@cox.net> told me that...
Show 20 quoted lines
> Matthias Urlichs <smurf@smurf.noris.de> writes: > > > Hi, Junio C Hamano wrote: > > > >> * Perhaps a tool to revert a single file to pre-modification > >> state? git-cat-file blob `git-ls-files | grep foo` >foo or > >> git-cat-file blob `git-ls-tree HEAD foo` >foo? What should > >> the command be called? git-revert is taken so is > >> git-checkout. > > > > git-checkout can be extended to accept filenames, which would have the > > additional benefit of enabling me to get any revision, not just HEAD. > > > > So can git-reset. > > > > I agree with Anton's "git clean"; with an optional -r <commit> > > argument, that would be a better solution. > > It probably is because I am BK untainted, but 'git clean' sounds > as if it would do 'git-ls-files --others | xargs rm -f'.
FWIW, that's also what cg-clean does. It uses cg-restore -f filename to restore files to the state of the last commit, but it's not like I'd be terribly happy about that.
-- Petr "Pasky" Baudis Stuff: http://pasky.or.cz/ If you want the holes in your knowledge showing up try teaching someone. -- Alan Cox