Skip to content

git_submodule_reload gets confused by submodules with the same path #3284

@joshaber

Description

@joshaber

This is a recent regression.

I'm working on updating objective-git to the latest SHA. We have some submodule tests that use the following .gitmodules:

[submodule "Test_App"]
        path = Test_App
        url = ../Test_App
[submodule "Test_App2"]
        path = Test_App2
        url = ../Test_App
[submodule "Archimedes"]
        path = Archimedes
        url = https://github.com/github/Archimedes

If we use git_submodule_lookup to look up Test_App, and then call git_submodule_name, we get Test_App2.

The PR with the failing test: libgit2/objective-git#472

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions