Skip to content

Commit a215ae2

Browse files
committed
check if env var there
1 parent 88618f3 commit a215ae2

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

.github/workflows/publish_yak.yml

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ jobs:
2525
echo "TEST_FLAG=--test-server" | Out-File -FilePath $env:GITHUB_ENV -Append
2626
}
2727
else {
28-
echo "TEST_FLAG=''" | Out-File -FilePath $env:GITHUB_ENV -Append
28+
echo "TEST_FLAG=" | Out-File -FilePath $env:GITHUB_ENV -Append
2929
}
3030
3131
- name: Checkout repo
@@ -57,8 +57,9 @@ jobs:
5757
- name: Publish to Yak server (Rhino 7)
5858
shell: pwsh
5959
run: |
60+
$test_flag = if ($Env:TEST_FLAG) { $Env:TEST_FLAG } else { "" }
6061
$file = Get-ChildItem -Path dist\yak_package\*rh7*.yak -File | Select-Object -ExpandProperty Name
61-
invoke publish-yak $Env:TEST_FLAG -y dist\yak_package\$file
62+
invoke publish-yak $test_flag -y dist\yak_package\$file
6263
env:
6364
YAK_TOKEN: ${{ secrets.YAK_DF_TOKEN }}
6465

@@ -73,7 +74,8 @@ jobs:
7374
- name: Publish to Yak server (Rhino 8)
7475
shell: pwsh
7576
run: |
77+
$test_flag = if ($Env:TEST_FLAG) { $Env:TEST_FLAG } else { "" }
7678
$file = Get-ChildItem -Path dist\yak_package\*rh8*.yak -File | Select-Object -ExpandProperty Name
77-
invoke publish-yak $Env:TEST_FLAG -y dist\yak_package\$file
79+
invoke publish-yak $test_flag -y dist\yak_package\$file
7880
env:
7981
YAK_TOKEN: ${{ secrets.YAK_DF_TOKEN }}

0 commit comments

Comments
 (0)