All of lore.kernel.org
 help / color / mirror / Atom feed
* git branch performance problem?
@ 2007-10-10 20:22 Han-Wen Nienhuys
  2007-10-10 20:44 ` Lars Hjemli
  0 siblings, 1 reply; 26+ messages in thread
From: Han-Wen Nienhuys @ 2007-10-10 20:22 UTC (permalink / raw)
  To: git

Hello,

I'm seeing very slow performance with 'git-branch'.  Is this the
canonical way to find out the current branch? ( I know I can look into
.git/HEAD, but how likely is that to break in the future?)

hanwen@lilypond:/tmp/z$ time git branch
* foo
  master

real    0m0.307s
user    0m0.232s
sys     0m0.038s

hanwen@lilypond:/tmp/z$ git --version
git version 1.5.1.rc1.949.g322bc


On NFS this takes 5 seconds. Note that I have a humongous amount of
remotes, but those should not be examined without -r, right?

hanwen@lilypond:/tmp/z$ find .git/refs/remotes | wc -l
1856

-- 
Han-Wen Nienhuys - hanwen@xs4all.nl - http://www.xs4all.nl/~hanwen

^ permalink raw reply	[flat|nested] 26+ messages in thread
* Re: git branch performance problem?
@ 2007-10-12 17:32 Salikh Zakirov
  0 siblings, 0 replies; 26+ messages in thread
From: Salikh Zakirov @ 2007-10-12 17:32 UTC (permalink / raw)
  To: hanwen; +Cc: Linus Torvalds, Lars Hjemli, git

Han-Wen Nienhuys wrote:
> For cherrypicking convenience, I would still appreciate it if there
> was a mechanism similar to alternates that would allow me to view
> objects from an alternate repo; objects found through this mechanism
> should never be assumed to be present in the database, of course.

There exist a script contrib/workdir/git-new-workdir,
which creates a new working copy that literally shares the same object store.
It will share both object store and branches, so some care must be taken:
branch which checkout out in one shared working directory must never be
updated
(committed or pulled into) from the other shared working directory.

Said that, I personally find this trick very useful for browsing code 
from different branch and quick bug fixing.

^ permalink raw reply	[flat|nested] 26+ messages in thread

end of thread, other threads:[~2007-10-12 17:36 UTC | newest]

Thread overview: 26+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-10-10 20:22 git branch performance problem? Han-Wen Nienhuys
2007-10-10 20:44 ` Lars Hjemli
2007-10-10 21:17   ` Han-Wen Nienhuys
2007-10-10 21:24     ` Han-Wen Nienhuys
2007-10-10 21:30       ` Han-Wen Nienhuys
2007-10-10 21:39         ` J. Bruce Fields
2007-10-10 21:45           ` Lars Hjemli
2007-10-10 21:49             ` Han-Wen Nienhuys
2007-10-10 21:53               ` J. Bruce Fields
2007-10-10 22:01                 ` Han-Wen Nienhuys
2007-10-10 21:53               ` Johannes Schindelin
2007-10-10 22:55             ` Spam: " Brandon Casey
2007-10-11  9:41               ` Mike Ralphson
2007-10-11 10:58                 ` Johannes Schindelin
2007-10-10 23:39         ` Linus Torvalds
2007-10-11  2:26           ` Han-Wen Nienhuys
2007-10-11  6:41             ` Alex Riesen
2007-10-11 10:46             ` Johannes Schindelin
2007-10-11 13:11               ` Han-Wen Nienhuys
2007-10-11 15:16             ` Linus Torvalds
2007-10-12 17:19             ` Salikh Zakirov
2007-10-10 21:34       ` Lars Hjemli
2007-10-10 21:54       ` [PATCH] git-branch: only traverse the requested refs Lars Hjemli
2007-10-10 23:00         ` Johannes Schindelin
2007-10-10 23:30           ` Lars Hjemli
  -- strict thread matches above, loose matches on Subject: below --
2007-10-12 17:32 git branch performance problem? Salikh Zakirov

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.