Skip to content

Commit 517189b

Browse files
committed
use pwsh for windows
1 parent 381946a commit 517189b

File tree

1 file changed

+13
-3
lines changed

1 file changed

+13
-3
lines changed

.github/workflows/build-template.yaml

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ jobs:
7373
run: |
7474
python -m pip install --upgrade pip setuptools pyinstaller
7575
curl -sSL https://install.python-poetry.org | python3 - --version ${{ env.POETRY_VERSION }}
76-
echo "C:\Users\runneradmin\AppData\Roaming\Python\Scripts" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append
76+
echo "C:\Users\runneradmin\AppData\Roaming\Python\Scripts" | Out-File -FilePath "$env:GITHUB_PATH" -Encoding utf8 -Append
7777
7878
poetry config virtualenvs.create false
7979
poetry install --no-root
@@ -142,15 +142,25 @@ jobs:
142142
ls dist/
143143
144144
# Optional: Run tests
145-
- name: Run tests
146-
if: ${{ !inputs.is-release }}
145+
- name: Run tests(Unix)
146+
if: ${{ !inputs.is-release }} && matrix.os != 'windows-latest'
147147
shell: bash
148148
env:
149149
# Add your test environment variables here
150150
OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }}
151151
run: |
152152
poetry run pytest -m "not llm"
153153
154+
# Optional: Run tests
155+
- name: Run tests(Windows)
156+
if: ${{ !inputs.is-release }} && matrix.os == 'windows-latest'
157+
shell: pwsh
158+
env:
159+
# Add your test environment variables here
160+
OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }}
161+
run: |
162+
poetry run pytest -m "not llm"
163+
154164
# Test the built binary
155165
- name: Test binary (Unix)
156166
if: matrix.os != 'windows-latest'

0 commit comments

Comments
 (0)