Re: Newbie question

2 messages, 2 authors, 2016-06-15 · open the first message on its own page

Re: Newbie question

From: George Spelvin <hidden>
Date: 2016-06-15 22:49:36

Jakub Narebski wrote:
You have the repository itself (the object database containg all
version info plus other info).  Put those files and directories into
<project>/.git subdirectory, and use "git checkout" from within it.
You should have checked out files in <project>/ directory.
What he said.  Cloning it in the first place is the easier approach, but
what happened is that you got a copy of a "bare" repostitory (without
checked-out files, suitable only for remote access), which is typically
in a directory named "project.git".

What you want is a normal tree, where all the git files are in "project/.git"

This is pretty easy to do:

mkdir project
mv project.git project/.git
cd project
git config core.bare true
git checkout

That does 3 things:
- Set up the directory structure correctly,
- unset the core.bare flag, which disables certain commands that
  make no sense on a bare repository, and
- Check out a working copy

Re: Newbie question

From: Thomas Hochstein <hidden>
Date: 2016-06-15 22:49:36

George Spelvin wrote:
git config core.bare true
[...]
- unset the core.bare flag, which disables certain commands that
  make no sense on a bare repository, and
Shouldn't that be
| git config core.bare false
then?

Regards,
-thh
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help