Skip to content

Conversation

@carlosmn
Copy link
Member

@carlosmn carlosmn commented Jul 1, 2015

Oh my, regex.

We were missing the pattern to match a full stop just after the submodule name, so when we wanted to look for 'Test_App' , we would create the lookup rule submodule\.Test_App.* which is obviously wrong. We want submodule\.Test_App\..* or we end up looking up the 'Test_App2' submodule as well.

This fixes #3284

carlosmn added 2 commits July 1, 2015 21:14
When two submodules are fairly similar, we may end up loading the wrong
one.
The regex we use to look at the gitmodules file does not correctly
delimit the name of submodule which we want to look up and puts '.*'
straight after the name, maching on any submodule which has the seeked
submodule as a prefix of its name.

Add the missing '\.' in the regex so we want a full stop to exist both
before and after the submodule name.
carlosmn added a commit that referenced this pull request Jul 2, 2015
Correctly delimit the keys for submodule lookup
@carlosmn carlosmn merged commit eb94199 into master Jul 2, 2015
@carlosmn carlosmn deleted the cmn/submodule-duplicate branch August 3, 2015 17:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

git_submodule_reload gets confused by submodules with the same path

2 participants