Description
Currently, our MSBuild target generates a Semantic Version (SemVer) for each project in the solution based on individual version.txt files. This approach can lead to redundancy and inconsistencies when managing versioning across multiple projects.
To simplify version management, we propose allowing a single version.txt file to be used for the entire solution instead of requiring separate files for each project.
Proposed Changes
-
Single Version File:
- Introduce support for a centralized
version.txt file located at the solution level, which all projects can reference for versioning.
- Ensure that the MSBuild target reads from this single file and generates the same SemVer for all projects in the solution.
-
Backwards Compatibility:
- Maintain support for existing projects that still use individual
version.txt files.
- Implement logic to check for the presence of a solution-level
version.txt and prioritize it over project-level files if both exist.
-
Documentation Update:
- Update the project documentation to reflect this new feature, including setup instructions for using the centralized versioning approach.
-
Testing:
- Create test cases to ensure that the versioning behaves as expected when using both the centralized and individual
version.txt setups.
Benefits
- Simplified Version Management: Having a single version file reduces redundancy and makes it easier to manage versioning across multiple projects.
- Consistency: Ensures that all projects in the solution are using the same version number, preventing discrepancies and confusion.
- Ease of Use: Simplifies the process for developers, who will no longer need to update multiple version files for each release.
Description
Currently, our MSBuild target generates a Semantic Version (SemVer) for each project in the solution based on individual
version.txtfiles. This approach can lead to redundancy and inconsistencies when managing versioning across multiple projects.To simplify version management, we propose allowing a single
version.txtfile to be used for the entire solution instead of requiring separate files for each project.Proposed Changes
Single Version File:
version.txtfile located at the solution level, which all projects can reference for versioning.Backwards Compatibility:
version.txtfiles.version.txtand prioritize it over project-level files if both exist.Documentation Update:
Testing:
version.txtsetups.Benefits