After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 448168 - Support for Mercurial and git
Support for Mercurial and git
Status: RESOLVED FIXED
Product: damned-lies
Classification: Infrastructure
Component: general
unspecified
Other All
: Normal minor
: ---
Assigned To: Claude Paroz
damned-lies Maintainer(s)
Depends on:
Blocks:
 
 
Reported: 2007-06-16 11:11 UTC by Dimitris Glezos
Modified: 2007-06-18 19:15 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Add support for hg and git to DL (6.89 KB, patch)
2007-06-16 11:16 UTC, Dimitris Glezos
none Details | Review
Complete patch (24.54 KB, patch)
2007-06-17 00:27 UTC, Claude Paroz
none Details | Review
Revised patch (25.15 KB, patch)
2007-06-17 21:17 UTC, Claude Paroz
committed Details | Review

Description Dimitris Glezos 2007-06-16 11:11:03 UTC
Please describe the problem:
Attaching a patch that adds support to DL from Mercurial and git.

Steps to reproduce:


Actual results:


Expected results:


Does this happen every time?


Other information:
Comment 1 Dimitris Glezos 2007-06-16 11:16:23 UTC
Created attachment 90052 [details] [review]
Add support for hg and git to DL

Basically copied the existing SVN class and tweaked it slightly. Two issues:

 1. The mechanism that selects which SCM should be called is not really good with defaults. If you specify a default <gitrepo> and override it with an <cvsrepo> it won't work; you'd need to explicitly override the second with a '<cvsrepo />'.

 2. Probably it would be wiser to tweak the XML and add generic <scmrepo> etc, and one <activeSCM>git</activeSCM> for example, to avoid all those IFs. This however implies that all SCMs follow the root-module-webpage model, which is true, but.. ah well. :-)
Comment 2 Claude Paroz 2007-06-16 14:43:51 UTC
You're right. What about creating a single <scmroot type="svn|cvs|git|hg"> (and accordingly <scmmodule> and <scmweb>)? 
Comment 3 Claude Paroz 2007-06-16 20:30:51 UTC
I just committed a rather big patch including your patch for supporting git and mercurial. Great!

I replaced cvs and svn tags by a generic scm... serie of tags. See gnome-modules.xml.in for details. Hope it's clear and clean enough!
Comment 4 Claude Paroz 2007-06-17 00:26:25 UTC
I had to revert this patch, due to a very strange bug. The potbase is not setting correctly for most modules.
This happens in modules.py :
if not here.has_key('potbase'):
     here['potbase'] = self.modules[module]['id']

This line affect a unique potbase to all modules which don't have it set explicitly in gnome-modules.xml. I don't see the relation between the patch and this bug :-(
Comment 5 Claude Paroz 2007-06-17 00:27:19 UTC
Created attachment 90108 [details] [review]
Complete patch
Comment 6 Claude Paroz 2007-06-17 21:17:16 UTC
Created attachment 90172 [details] [review]
Revised patch

I think I found the problem. I changed more properly the defaults handling in data.py. Will check and eventually commit tomorrow.
Comment 7 Claude Paroz 2007-06-18 19:15:10 UTC
Now I hope it's definitely fixed.