Skip to content

Commit d4c6a65

Browse files
committed
fix spelling and make OS detection robust
1 parent b72d11b commit d4c6a65

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

action.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -348,7 +348,7 @@ runs:
348348
}
349349
350350
print $"\n(ansi purple)Installing uv version ($env.UV_VERSION)(ansi reset)"
351-
let is_windows = (sys host | get 'name') == 'Windows'
351+
let is_windows = (version | get "build_os") | str starts-with "windows"
352352
let uv_installer_url = if $is_windows {
353353
$"https://astral.sh/uv/($env.UV_VERSION)/install.ps1"
354354
} else {
@@ -386,7 +386,7 @@ runs:
386386
} catch {
387387
print "Version is not an integer"
388388
if not ($version_str | path exists) {
389-
print "::error title=Invalid version input::Version must be a blank sting, an integer, or a valid path"
389+
print "::error title=Invalid version input::Version must be a blank string, an integer, or a valid path"
390390
exit 1
391391
} else {
392392
print $"(ansi yellow)Using custom clang tools installation at path: ($version_str)(ansi reset)"
@@ -417,7 +417,7 @@ runs:
417417
or (
418418
($version <= 9)
419419
and ($tool | str ends-with "format")
420-
and not ((sys host | get 'long_os_version') | str starts-with "Linux")
420+
and not ((version | get "build_os") | str starts-with "linux")
421421
)
422422
) {
423423
[clang-tools --tool $tool --install $version]

0 commit comments

Comments
 (0)