Skip to content

Commit

Permalink
Remove Version.Parse check from global.json parsing (#2804)
Browse files Browse the repository at this point in the history
refs #2803 - The check seems to break if the version is a pre-release version such as 9.0.100-preview.6.24328.19

The Parse call was added as part of the null change in #2757 but I'm not sure if there was any reason for it other than an attempt at a sanity check.
  • Loading branch information
Numpsy authored Aug 31, 2024
1 parent 2d3420d commit 32ee50e
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
1 change: 1 addition & 0 deletions RELEASE_NOTES.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

## 6.1.1 - 2024-08-19
* BUGFIX: Assembly resolver to pick a found SDK instead of first SDK - https://github.com/fsprojects/FAKE/pull/2797/files
* BUGFIX: Fix issue parsing global.json when using prerelease .NET SDKs, thanks @numpsy - https://github.com/fsprojects/FAKE/issues/2803

## 6.1.0 - 2024-07-27
* BUGFIX: MSBuild.build adds a bad string at the end of properties, thanks @0x53A - https://github.com/fsprojects/FAKE/issues/2738
Expand Down
5 changes: 1 addition & 4 deletions src/app/Fake.DotNet.Cli/DotNet.fs
Original file line number Diff line number Diff line change
Expand Up @@ -69,10 +69,7 @@ module DotNet =

match sdk.Property("version") with
| null -> None
| version ->
let versionValue = version.Value.ToString()
let _ = Version.Parse(versionValue)
Some versionValue
| version -> Some(version.Value.ToString())
with exn ->
failwithf "Could not parse `sdk.version` from global.json at '%s': %s" globalJson.FullName exn.Message

Expand Down

0 comments on commit 32ee50e

Please sign in to comment.