git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: Git drawbacks?

From
Jacob Helwig <jacob.helwig@gmail.com>
Date
Nov 9, 2009, 14:34 UTC
Message-ID
<8c9a060911090634p4e036208mfb3160eb4c4430e9@mail.gmail.com>
In-Reply-To
<loom.20091109T084539-720@post.gmane.org>
On Sun, Nov 8, 2009 at 23:53, Dmitry Smirnov <divis1969@gmail.com> wrote:
Show 11 quoted lines
>  <david <at> lang.hm> writes:
>
>> going back to the initial poster's comments. if the android repo is 1G,
>> eliminating the history will probably have significantly less impact than
>> you expect it to.
>
> Do you have 2 or more copies of the same repository at the same time?
> If yes, can I skip cloning new copy from network?
> Or even skip cloning it at all?
> Is it possible with Git to chekout into two (few) working trees?
>

Take a look at git-new-workdir. It's in the contrib directory of git.git. This lets you skip re-cloning the same repository over again, if you want a new working copy of it. It'll also give you some space savings, by sharing certain key things in the .git directory between working copies, by using symlinks.

It does have a few caveats, however. If you have the same branch checked out in two different working copies created using git-new-workdir, and update the branch in one of them, then the other will appear to have a bunch of staged changes, even though you haven't done anything in it. The branch pointer will have been updated out from underneath it, and it will be "confused". As long as you remember not to update a branch that is checked out in more than one place on your machine, you'll never notice, thuogh.

Previous: Dmitry SmirnovNext: Dmitry Smirnov
Message 8 of 27 in “Git drawbacks?”
  1. Dmitry SmirnovNov 6, 2009
  2. Avery PennarunNov 6, 2009
  3. Dmitry SmirnovNov 6, 2009
  4. Jacob HelwigNov 6, 2009
  5. Avery PennarunNov 6, 2009
  6. david@lang.hmNov 6, 2009
  7. Dmitry SmirnovNov 9, 2009
  8. Jacob HelwigNov 9, 2009
  9. Dmitry SmirnovNov 9, 2009
  10. Jacob HelwigNov 9, 2009
  11. Dmitry PotapovNov 9, 2009
  12. Dmitry SmirnovNov 9, 2009
  13. Dmitry PotapovNov 9, 2009
  14. Dmitry SmirnovNov 10, 2009
  15. Dmitry PotapovNov 10, 2009
  16. Dmitry SmirnovNov 10, 2009
  17. Paolo BonziniNov 10, 2009
  18. B Smith-MannschottNov 9, 2009
  19. Dmitry PotapovNov 9, 2009
  20. Dmitry SmirnovNov 10, 2009
  21. Dmitry PotapovNov 10, 2009
  22. Dmitry SmirnovNov 10, 2009
  23. Paolo BonziniNov 10, 2009
  24. Dmitry PotapovNov 10, 2009
  25. Dmitry SmirnovNov 10, 2009
  26. Dmitry SmirnovNov 9, 2009
  27. Dmitry SmirnovNov 11, 2009

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.