Add --temp and --stage=all options to checkout-index.

Sometimes it is convient for a Porcelain to be able to checkout all
unmerged files in all stages so that an external merge tool can be
executed by the Porcelain or the end-user.  Using git-unpack-file
on each stage individually incurs a rather high penalty due to the
need to fork for each file version obtained.  git-checkout-index -a
--stage=all will now do the same thing, but faster.

Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
This commit is contained in:
Shawn Pearce
2006-03-05 03:24:15 -05:00
committed by Junio C Hamano
parent 46444f514b
commit de84f99c12
7 changed files with 371 additions and 27 deletions

View File

@ -337,7 +337,7 @@ static void check_updates(struct cache_entry **src, int nr)
if (ce->ce_flags & mask) {
ce->ce_flags &= ~mask;
if (update)
checkout_entry(ce, &state);
checkout_entry(ce, &state, NULL);
}
}
if (total) {