How to commit change of submodule commit in VS 2022

TS 1 Reputation point

In Visual Studio 2022, with a Git repository that uses a submodule, how do I commit the change for which submodule commit the main repository points to? I've turned on multi-repo support, and Visual Studio is tracking the changes in both repositories. I've made a new commit in the submodule, and now I want the main repository to point to the submodule's new commit.

In the Git Changes window, it shows that the submodule has changed. I have no uncommitted changes inside the submodule, so it seems to be telling me (appropriately) that the submodule is on a new commit. But when I try to stage that change, nothing happens, and when I click "Commit All", I get the error message "commit --allow-empty-message --file='".

Visual Studio
Visual Studio
A family of Microsoft suites of integrated development tools for building applications for Windows, the web and mobile devices.
4,752 questions
{count} votes