Sam Posted November 25, 2014 Report Share Posted November 25, 2014 Hello everybody, When I try to sync Plastic with a git repo that contains submodules I get stuck with this error : The equivalent Git reposytory for '' has not been defined. The xlink cannot be pushed... (see capture) The message tells me to add equivalence in gitsync.conf, but this file doesn't exist on the indicated location. Moreover I have no idea on how to write the requested "equivalence", I only found how to map users and emails, but I found nowhere on the web information about the "submodule section" of the file gitsync.conf The targetted git repositories are already synced with another plastic repository on my server, so the mapping should be possible. Did someone succeed in that ? Any part of documentation I missed ? A big thank by advance for help. Link to comment Share on other sites More sharing options...
manu Posted November 25, 2014 Report Share Posted November 25, 2014 Hi Sam! look, edit the gitsync.conf file, you can specify the submodules references as follows: [submodules]git://localhost/code -> code@localhost:8084 writable:true relativeserver:truegit://localhost/doc -> doc@localhost:8084 writable:false relativeserver:true or... [submodules]git://localhost/repoA -> gitsync@localhost:8084 writable:true relativeserver:truec:\\tmp\\repos\\repoB -> repoB@localhost:8084 writable:false relativeserver:true Link to comment Share on other sites More sharing options...
Sam Posted November 25, 2014 Author Report Share Posted November 25, 2014 Thanks a lot, I will try to create the file myself then. I still have couple of questions : - what is the syntax for a git repository over https (from github, ie: https://github.com/user/repo.git), can I write directly : https://github.com/user/repo.git -> gitsync@localhost:8084 writable:true relativeserver:true ? - Perhaps I misunderstood something, is it true that I have to set the gitsync.conf file up on client side ? Does it means that every client have to set-up its own file ? Is there a way to make the mapping populating over the clients connected to my server ? Or perhaps is it automatic ? Link to comment Share on other sites More sharing options...
manu Posted November 25, 2014 Report Share Posted November 25, 2014 Hi Sam, - what is the syntax for a git repository over https (from github, ie: https://github.com/user/repo.git), can I write directly : https://github.com/user/repo.git -> gitsync@localhost:8084 writable:true relativeserver:true ? It should be the same as the one defined in the .gitmodules file, for example: [submodule "externals/repoB"] path = externals/repoB url = c:\\tmp\\repos\\repoB Then I need to use the "c:\\tmp\\repos\\repoB" path in my gitsync.conf file. - Perhaps I misunderstood something, is it true that I have to set the gitsync.conf file up on client side ? Does it means that every client have to set-up its own file ? Is there a way to make the mapping populating over the clients connected to my server ? Or perhaps is it automatic ? Yes, everyone using the gitSync with the external git repository and the local Plastic SCM server has to manually configure the file. Link to comment Share on other sites More sharing options...
Sam Posted November 26, 2014 Author Report Share Posted November 26, 2014 Hi Manu, It begins to work but I stuck to the next step : For one repository I had the message : The equivalent Git repository for 'https://github.com/user/repoX.git' has not been defined. The xlink cannot be pushed So I have added the following line on gitsync.conf : [submodules] https://github.com/user/repoX.git -> repoX@ssl://personalserver:8088 writable:true relativeserver:true I retried the sync then I had another message for the new adresse of the git repo who has been moved during the project's life : The equivalent Git repository for 'https://personalGitServer/Git/repoX.git' has not been defined. The xlink cannot be pushed So I have added a second line on gitsync.conf, pointing to the same plastic repository (all the history of the moved git repo is consistent, only it's address changed) [submodules] https://github.com/user/repoX.git -> repoX@ssl://personalserver:8088 writable:true relativeserver:true https://personalGitServer/Git/repoX.git -> repoX@ssl://personalserver:8088 writable:true relativeserver:true Then I had a new error : The configuration file : 'C:\Users\Sam\AppData\Local\plastic4\gitsync.conf cannot be read, because it's data is invalid or corrupt. I understand that it is because there are two lines pointing to the same Plastic repository ... OK, but this can happend, nothing is tricky here, just a change of git repo address that results on a modification of .gitmodules file during the progress of the project. I can't maintain a sync of another Plastic repo to the old git repo address because it doesn't exists anymore (deleted on github after a full history copy to another server). So this is the first problem I still have. The second one happens on 5-6 git repositories I want to sync, each of them have only one or two submodules but this time the message is the one of the first capture of the first message (with nothing between the apostophes ''). The submodules and .gitmodules file weren't present since the first commit but they were added later. The equivalent Git repository for '' has not been defined. The xlink cannot be pushed So I guess if Plastic makes something wrong by reading an unexisting file in the first commits (.gitmodules is not in the fist commits) or perhaps reading a blank line that it interprets as a blank repository url. Anyway it seems to have a real problem with this. Can I do something by myself or do I need to wait for un update of Plastic ? I'm really stuck with this. Thanks for your help. Sam Link to comment Share on other sites More sharing options...
Sam Posted December 4, 2014 Author Report Share Posted December 4, 2014 Hi Manu, hi everyone, Is there any hope to test new syntax or something I don't know at the moment ? Thank you Link to comment Share on other sites More sharing options...
manu Posted December 4, 2014 Report Share Posted December 4, 2014 Hi! it's not possible to set those rules. A -> Z B -> Z The Z plastic repository will only work with one git URL, so you can't configure it with 2 (A & B ). Link to comment Share on other sites More sharing options...
manu Posted December 4, 2014 Report Share Posted December 4, 2014 So I guess if Plastic makes something wrong by reading an unexisting file in the first commits (.gitmodules is not in the fist commits) or perhaps reading a blank line that it interprets as a blank repository url. Anyway it seems to have a real problem with this. Let me check that with an empty git ".gitmodules" file. Link to comment Share on other sites More sharing options...
Sam Posted January 7, 2015 Author Report Share Posted January 7, 2015 Hi Manu, Did you try the empty .gitmodules file ? I'm still not able to sync some repos :-( Thank you by advance. Link to comment Share on other sites More sharing options...
manu Posted January 7, 2015 Report Share Posted January 7, 2015 Hi Sam, unfortunately for us the empty gitsubmodules file does not makes us fail. Is there any chance to get access to your repo so we can track where the failure is coming from? Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.