Skip to content

Conversation

@StellarTodd
Copy link

@StellarTodd StellarTodd commented Sep 4, 2025

Added support native for projects where the solution file is not in the git repository.
Added support for working on files without a solution loaded.
Added support for worktrees and submodules (".git" is a file rather than directory)

Commit 5ef6f85
Changed GetSolutionPath to return the repository root.
This was done by looking for ".git", however; it only checked for a directory by that name.
When using submodules and worktrees, ".git" is a file not a directory.
This also changed the behavior of the function without changing its name which is confusing.
Both of these issues were resolved.

PR #21 - Git worktree support
The above fix works for submodules and worktrees and thus these changes were no longer needed.
This removes a ton of code and unnecessary complexity.

PR #29 - Support for VS2022 on ARM
The code does not build with this change.
In order to get the code to build, NuGet packages would need to be updated.
I am not sure if that would break the VS2019 version, but that seems likely.
This change was removed in order to build the code.

PR #30 - Fix for auto-generated solutions such as CMake
Added an unnecessary preference setting.
Used the current file for "repository" commands, and thus did not work correctly.
PR #30 has been superseded by this commit.

Added GetRepositoryRootPath() to retrieve the git repository root path.
This searches using the current file, if there is one, then using the solution file, if one is open.

Updated the code to call GetRepositoryRootPath() in all locations that need the repository root.
Updated variables for correctness and clarity (i.e. gitRepoPath instead of solutionPath).
Updated error message when a git repository root cannot be found.

Added support projects where the solution file is not in the git repository.
Added support for working on files without a solution loaded.
Added support for worktrees and submodules (".git" is a file rather than directory)

Commit 5ef6f85
Changed GetSolutionPath to return the repository root.
This was done by looking for ".git", however; it only checked for a directory by that name.
When using submodules and worktrees, ".git" is a file not a directory.
This also changed the behavior of the function without changing its name which is confusing.
Both of these issues were resolved.

PR MRCollective#21 - Git worktree support
The above fix works for submodules and worktrees and thus these changes were no longer needed.
This removes a ton of code an unnecessary complexity.

PR MRCollective#29 - Support for VS2022 on ARM
The code does not build with this change.
In order to get the code to build, NuGet packages would need to be updated.
I am not sure if that would break the VS2019 version, but that seems likely.
This change was removed in order to build the code.

PR MRCollective#30 - Fix for auto-generated solutions such as CMake
Added an unnecessary preference setting.
Used the current file for "repository" commands, and thus did not work correctly.
PR MRCollective#30 has been superseded by this commit.

Added GetRepositoryRootPath() to retrieve the git repository root path.
This searches using the current file, if there is one, then using the solution file if one is open.

Updated the code to GetRepositoryRootPath() in all locations that need the repository root.
Updated variables for correctness and clarity (i.e. gitRepoPath instead of solutionPath)
Updated error message when a git repository root cannot be found.
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.

1 participant