Versioning and support of framework?
Herve-M opened this issue · comments
Little question related to dotnet-format and framework version: should we use specific version of dotnet-format related to major version of framework?
Like:
- .NET Core 3.1 should use 3.3.x
- .NET 5 should use 5.1.x
- .NET 6 should use 6.4.x
- etc.
Edit:
If it would be the case, 4.1.X is for which framework?
I would not try and match versions in this way. The version of dotnet-format which ships in your .NET SDK should be able to load your SDK projects regardless of which tfm you target.
If you are having issues with projects loading, please open an issue with details.
The version of dotnet-format which ships in your .NET SDK should be able to load your SDK projects regardless of which tfm you target.
Sadly, for project using global.json
over legacy/eol LTS like .NET 3.1 it requires to install a global version using dnceng feeds which is problematics in CI env. where multiple TFM projects works ex: .NET 3.1, .NET 6, .NET 7; and for .NET 6 and onwards the matching of version is enforced by global.json
file.
This would mean to that our script / task need to detect the current version of .NET over the working-dir and adapt the exec. target? Like dotnet format
for .NET 6 / 7/ 8 and dotnet-format
for .NET 3.1 and lower.
Otherwise, is the latest 8.x version capable to work over EOL/Legacy .NET Core and .NET Framework 4.8? If yes, this could simplify a lot.