guberm / tortoisegit

Automatically exported from code.google.com/p/tortoisegit
0 stars 0 forks source link

Submodules path/branch change #2519

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1.No option to edit and update the submodules path/branch links.
2.can be done externally by edition .gitmodules file and doing a submodule 
update

What is the expected output? What do you see instead?
An option to edit, sync ad update submodules link to different repositories/ 
different tags in a same repository

TortoiseGit 1.8.14.0 (C:\Program Files\TortoiseGit\bin) 
git version 1.9.5.msysgit.1 (C:\Program Files (x86)\Git\bin) 
Windows 7 64Bit

Please provide any additional information below.

Original issue reported on code.google.com by pavan....@gmail.com on 5 Jun 2015 at 2:57

GoogleCodeExporter commented 9 years ago

Original comment by ch3co...@gmail.com on 5 Jun 2015 at 4:47

GoogleCodeExporter commented 9 years ago
Are there any GIT commands by which I can achieve the above desired results?

The only way I could do it is to edit .gitmodules separately and update the 
submodules contents.

Original comment by pavan....@gmail.com on 5 Jun 2015 at 4:51

GoogleCodeExporter commented 9 years ago
You treat .gitmodules as a git config file, and use git config to read/write it

To write,
git config --file=.gitmodules submodule.XXX.path https://example.com/XXX.git

To list all,
git config --file=.gitmodules -l

Original comment by ch3co...@gmail.com on 5 Jun 2015 at 5:01

GoogleCodeExporter commented 9 years ago
Are these commands are correct to edit and update a submodule path?

$ git config --file=.gitmodules submodule.XXX.url https://example.com/XXX.git
$ git submodule sync
$ git submodule update --init --recursive --remote

How can these commands be implemented in TortoiseGIT?

Please give me an idea on how can i implement it.

Original comment by pavan....@gmail.com on 5 Jun 2015 at 6:48