Visual Studio solution generator
Перейти к файлу
dependabot[bot] 5e1e280577
Bump Microsoft.VSSDK.BuildTools from 17.11.435 to 17.12.2069 (#622)
Bumps Microsoft.VSSDK.BuildTools from 17.11.435 to 17.12.2069.

---
updated-dependencies:
- dependency-name: Microsoft.VSSDK.BuildTools
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-11-05 21:49:34 -08:00
.github Update dependabot.yml 2023-11-20 10:22:16 -08:00
assets/css Update style.scss 2019-05-31 10:32:46 -07:00
branding Refactor into an executable (#84) 2020-02-11 14:56:43 -08:00
docs Update documentation to reflect latest changes (#612) 2024-10-04 17:52:13 -07:00
src Always honor ProjectGuid, if provided (#615) 2024-10-09 15:48:27 -07:00
.gitattributes Add macOS Visual Studio launch support (#492) 2023-06-30 10:29:13 -07:00
.gitignore Set RuntimeFramework Version so SlnGen will run against the latest major version of the runtime it was built against (#528) 2023-09-19 13:38:42 -07:00
CONTRIBUTING.md Update README and add CONTRIBUTING (#83) 2020-02-10 08:02:59 -08:00
Directory.Build.props Upgrade to net9.0-rc (#599) 2024-09-26 16:36:02 -07:00
Directory.Build.rsp Ship .NET Core tool as a way of just executing .NET Framework SlnGen (#164) 2020-09-01 09:19:57 -07:00
Directory.Build.targets Upgrade to net9.0-rc (#599) 2024-09-26 16:36:02 -07:00
Directory.Packages.props Bump Microsoft.VSSDK.BuildTools from 17.11.435 to 17.12.2069 (#622) 2024-11-05 21:49:34 -08:00
Directory.Solution.props Adopt Microsoft.Build.Traversal for skipping projects when building the solution (#479) 2023-05-03 12:25:36 -04:00
Directory.Solution.targets Drop support for .NET Core 3 and .NET 5 (#537) 2023-10-13 10:13:34 -07:00
LICENSE.txt Refactor into an executable (#84) 2020-02-11 14:56:43 -08:00
MicrosoftCorporation.snk Enable Authenticode signing (#88) 2020-02-13 14:04:50 -08:00
NuGet.config Add NuGet.config 2018-02-07 07:03:56 -08:00
README.md Remove telemetry collection (#481) 2023-05-03 18:00:24 +00:00
RELEASE.md Update documentation to reflect latest changes (#612) 2024-10-04 17:52:13 -07:00
SECURITY.md Microsoft mandatory file (#370) 2022-05-18 19:46:46 -04:00
SlnGen.sln Drop support for .NET Core 3 and .NET 5 (#537) 2023-10-13 10:13:34 -07:00
Test.snk Ship .NET Core tool as a way of just executing .NET Framework SlnGen (#164) 2020-09-01 09:19:57 -07:00
azure-pipelines-official.yml Publish symbols for slngen package assemblies (#617) 2024-10-09 17:34:22 -07:00
azure-pipelines.yml Upgrade to net9.0-rc (#599) 2024-09-26 16:36:02 -07:00
global.json Upgrade to net9.0-rc (#599) 2024-09-26 16:36:02 -07:00
stylecop.json Add console app (#77) 2020-01-21 14:13:46 -08:00
version.json Add MSBuild support for controlling --verbosity, --configuration, --platform and project file arguments to slngen.exe (#609) 2024-10-04 16:07:41 -07:00

README.md

SlnGen

Build Status

Overview

SlnGen is a Visual Studio solution file generator. Visual Studio solutions generally do not scale well for large project trees. They are scoped views of a set of projects. Enterprise-level builds use custom logic like traversal to convey how they should be built by a hosted build environment. Maintaining Visual Studio solutions becomes hard because you have to keep them in sync with the other build logic. Instead, SlnGen reads the project references of a given project to create a Visual Studio solution on demand. For example, you can run it against a unit test project and be presented with a Visual Studio solution containing the unit test project and all of its project references. You can also run SlnGen against a traversal project in a rooted folder to open a Visual Studio solution containing that view of your project tree.

NuGet package NuGet downloads

To install SlnGen, run the following command:

dotnet tool install --global Microsoft.VisualStudio.SlnGen.Tool --add-source https://api.nuget.org/v3/index.json --ignore-failed-sources

Once installed, .NET Core will add slngen to your PATH so you can run it from any command window:

slngen --help

More documentation is available at https://microsoft.github.io/slngen/.

Getting Started - MSBuild Target

NuGet package NuGet downloads

The MSBuild target must be installed as a NuGet package and restored. This can slow down the process so a .NET Core tool might be preferable.

Install the package to an individual project (not recommended):

 Install-Package Microsoft.VisualStudio.SlnGen

Or add it your Directory.Build.props:

<ItemGroup>
  <PackageReference Include="Microsoft.VisualStudio.SlnGen" Version="<Latest Version>" />
</ItemGroup>

Generate and open a Visual Studio solution with MSBuild:

> MSBuild /Restore /t:SlnGen

You can also create a DOSKEY alias as a shortcut

> doskey slngen=msbuild /nologo /v:m /t:slngen

More documentation is available at https://microsoft.github.io/slngen/.

Contributing

This project has adopted the Microsoft Open Source Code of Conduct. For more information see the Code of Conduct FAQ or contact opencode@microsoft.com with any additional questions or comments.