Skip to content

Commit 6e04ef4

Browse files
Refactor PowerShell installation: update curl command to fail silently on errors for improved reliability in version resolution.
1 parent 0d5c320 commit 6e04ef4

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

action.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ runs:
3333
case "${REQUESTED_VERSION:-}" in
3434
[Ll][Aa][Tt][Ee][Ss][Tt])
3535
REQUESTED_VERSION=$(
36-
curl -s https://api.github.com/repos/PowerShell/PowerShell/releases/latest |
36+
curl -sf https://api.github.com/repos/PowerShell/PowerShell/releases/latest |
3737
grep '"tag_name"' | head -n1 |
3838
sed -E 's/.*"v?([^"]+)".*/\1/'
3939
)
@@ -96,7 +96,7 @@ runs:
9696
# Only resolve to latest version if explicitly set to 'latest'
9797
if [[ "$REQ_VER_LOWER" == "latest" ]]; then
9898
REQUESTED_VERSION=$(
99-
curl -s https://api.github.com/repos/PowerShell/PowerShell/releases/latest |
99+
curl -sf https://api.github.com/repos/PowerShell/PowerShell/releases/latest |
100100
grep '"tag_name"' | head -n1 |
101101
sed -E 's/.*"v?([^"]+)".*/\1/'
102102
)

0 commit comments

Comments
 (0)