Thread (1 message) 1 message, 1 author, 2016-06-15

Re: git init doesn't create master branch

From: Junio C Hamano <hidden>
Date: 2016-06-15 22:57:29

"Ákos, Tajti" [off-list ref] writes:
Thanks for clarifying this thing for me! I don't really insist on
having a master branch it's just that I tried to pull from a
repository bundle and I got this error message:

"Cannot merge multiple branches into empty head"

The command was:

git pull ../dump.dmp refs/heads/*:refs/heads/*

Is this a better way of doing this?
You are not trying to merge all branches contained in the dump, so
"pull" is a wrong thing to use here.

    $ git fetch --update-head-ok ../dump.dmp refs/heads/*:refs/heads/*

would be one way.  Or you could just use the dumpfile as if it were
a normal remote and say (without running "git init")

    $ git clone dump.dmp undump

to extract it in a new directory "undump" (this may require your
dumpfile created with HEAD, though).
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help