DORMANTno replies

[PATCH] Preliminary branch-import support for git in tailor

From: Yann Dirson <hidden>
Date: 2016-06-15 22:42:28

Here is my first try at working with branches with tailor.
This patch applies to current tailor from the darcs repo.

Attached: the patch, and the sample config I used to test it against a
public repo.

Possible improvements:

- the parent-repo parameter is probably generic enough to be useful
for other targets, but it is currently a git-target parameter only

- the change to tailor.py to avoid loosing the initial commit log on
the imported branch probably breaks all other targets because of the
previous issue

- autodetection of the branchpoint would be great, but that surely
deserves to be done in core tailor

- I'll have a try next to add support for pushing git branches to cvs
ones: that will give us a real 2-way sync between cvs and git


Generic problems noticed:

- not all tags from the cvs repo I tested against were imported
(problem specific to the cvs source ?)

- I could not make the cvsps source work to verify it fetches tags
better than the cvs one

- the "projects" parameter has to be specified explicitely to force
the ordering of branch imports - I would have expected the declaration
order to be used.

- it would probably be cleaner to have the *Repository classes in
repository.py moved into their own files: currently we have to modify
a generic file to add backend-specific options, that's not really
generic.  What about loading the necessary class when it is found
mentionned in the config ?


Comparison with git-cvsimport

- tailor can give strange results in some cases, but I believe it is
more correct than git-cvsimport.  An example is when the cvs branch
you import does not exist in some files for any reason (I had a branch
only for the src/ dir - corrected that now): in that case tailor
correctly shows deletions for those files in the branch initial
commit, whereas git-cvsimport only works on changes, and does not do
anything special (this may be cvsps doing magic behind his back).

- run against a local copy of the repository, tailor is orders of
magnitude slower than git-cvsimport (git-cvsimport returned instantly
on my repo), some profiling has to be done.

-- 
Yann Dirson    [off-list ref] |
Debian-related: [off-list ref] |   Support Debian GNU/Linux:
                                    |  Freedom, Power, Stability, Gratis
     http://ydirson.free.fr/        | Check <http://www.debian.org/>

Attachments

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