Re: Efficient way to import snapshots?
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Jul 30, 2007, 21:04 UTC
- Message-ID
- <7vps29k3gm.fsf@assigned-by-dhcp.cox.net>
- In-Reply-To
- <alpine.LFD.0.999.0707301240330.4161@woody.linux-foundation.org>
Linus Torvalds <torvalds@linux-foundation.org> writes:
Show 14 quoted lines
> That said, I just noticed something nasty: "git add ." is *horrible*. It > does the full SHA1 re-computation even though the index is up-to-date. > That's really nasty. > > So right now, due to this performance bug, it's actually much better to do > something more complex, namely something like > > git ls-files -o | git update-index --add --stdin > git commit -a > > which is a lot more efficient than just doing "git add .". > > Junio? I _thought_ we already took the index into account with "git add", > but we obviously don't.
I do not know offhand.
By the way, the above "something more complex" may be a simple "git add -u".