Checking out on a different+partial directory

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Say that I have a repository at /some/dir, and a tree that contains
most of its files at /another/dir (the second is a build directory,
made with `git archive', so some files removed due to export-ignore
attributes and some built files are present).

Is there a convenient way to make /some/dir usable as a repository?
Two things that I tried are

  git --work-tree=/another/dir reset --hard master

which one time, but then failed with "fatal: unable to read tree...",
and another is

  cp -a /some/dir/.git /another/dir
  cd /another/dir
  git reset --hard master

which looks like it can suffer from the same problem.

(It would be especially nice if there's a way to have only different
files touched in /another/dir.)

-- 
          ((lambda (x) (x x)) (lambda (x) (x x)))          Eli Barzilay:
                    http://barzilay.org/                   Maze is Life!
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]