* Editing git-svn metadata
@ 2009-05-02 1:02 Orestis Markou
2009-05-04 15:39 ` Michael J Gruber
0 siblings, 1 reply; 2+ messages in thread
From: Orestis Markou @ 2009-05-02 1:02 UTC (permalink / raw)
To: git
Hello,
I couldn't find anything in the manpages for this, and I don't know
where else to look for it.
As mentioned here: http://article.gmane.org/gmane.comp.version-control.git/116382
, an svn repository I'm working against has a weird layout on which
git-svn chokes on. I'm working around that by using grafts to inform
git about the history of the branches. It involves some manual work
but it's fine.
Another problem I have (possibly linked) is that branches are only
detected after the first commit to them - the commit that creates the
branch is not recorded by git-svn at all. This forces me to do a
'dummy' commit from svn in order to even see the branch in git-svn.
Given that I have all the information I need (branch name, parent id),
is there any file I can manually edit to inform git-svn about my
branches?
Alternatively, and more usefully to git in general, perhaps I can have
a look at the git-svn code and add some diagnostics to see what's
failing, and provide a patch? I looked for a developer guide but
couldn't find one (only how to write tests).
Regards,
Orestis
--
orestis@orestis.gr
http://orestis.gr/
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: Editing git-svn metadata
2009-05-02 1:02 Editing git-svn metadata Orestis Markou
@ 2009-05-04 15:39 ` Michael J Gruber
0 siblings, 0 replies; 2+ messages in thread
From: Michael J Gruber @ 2009-05-04 15:39 UTC (permalink / raw)
To: Orestis Markou; +Cc: git
Orestis Markou venit, vidit, dixit 02.05.2009 03:02:
> Hello,
>
> I couldn't find anything in the manpages for this, and I don't know
> where else to look for it.
>
> As mentioned here: http://article.gmane.org/gmane.comp.version-control.git/116382
> , an svn repository I'm working against has a weird layout on which
> git-svn chokes on. I'm working around that by using grafts to inform
> git about the history of the branches. It involves some manual work
> but it's fine.
>
> Another problem I have (possibly linked) is that branches are only
> detected after the first commit to them - the commit that creates the
> branch is not recorded by git-svn at all. This forces me to do a
> 'dummy' commit from svn in order to even see the branch in git-svn.
>
> Given that I have all the information I need (branch name, parent id),
> is there any file I can manually edit to inform git-svn about my
> branches?
>
> Alternatively, and more usefully to git in general, perhaps I can have
> a look at the git-svn code and add some diagnostics to see what's
> failing, and provide a patch? I looked for a developer guide but
> couldn't find one (only how to write tests).
It may depend on how you create branches in svn. The usual way is to
copy from trunk (or another branch) in the way the attached script does.
For me, the relevant output is
* master
remotes/mybranch
remotes/trunk
which is pretty much what it should be. Do you create (empty) branches
by doing a mkdir in an svn check out of the base dir (below trunk)?
Michael
--- %< ---
#!/bin/bash
rm -Rf svnrepo svnwc gitrepo
svnurl="file://localhost"`pwd`/svnrepo
svnadmin create svnrepo
svn co $svnurl svnwc
(
cd svnwc
mkdir trunk branches tags
svn add trunk branches tags
svn ci -m init
(
cd trunk
echo a > a
svn add a
svn ci -m A
svn cp -m mybranch $svnurl/trunk $svnurl/branches/mybranch
)
)
git svn clone -s $svnurl gitrepo
(
cd gitrepo
git branch -a
)
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2009-05-04 15:39 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-05-02 1:02 Editing git-svn metadata Orestis Markou
2009-05-04 15:39 ` Michael J Gruber
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).