Skip to content

Commit 5671259

Browse files
committed
Attempt to make it work on Windows
1 parent fffe019 commit 5671259

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

analyze-project/action.yml

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,9 +58,15 @@ runs:
5858
working-directory: ${{ inputs.project-directory }}
5959
shell: bash
6060
- name: Add virtualenv to the path for pyright-action
61-
run: echo "$(poetry env info --path)/bin" >> $GITHUB_PATH
62-
working-directory: ${{ inputs.project-directory }}
6361
shell: bash
62+
run: |
63+
VENV_PATH="$(poetry env info --path)"
64+
if [[ "$RUNNER_OS" == "Windows" ]]; then
65+
echo "$VENV_PATH/Scripts" >> $GITHUB_PATH
66+
else
67+
echo "$VENV_PATH/bin" >> $GITHUB_PATH
68+
fi
69+
working-directory: ${{ inputs.project-directory }}
6470
- name: Pyright static analysis
6571
uses: jakebailey/pyright-action@b5d50e5cde6547546a5c4ac92e416a8c2c1a1dfe # v2.3.2
6672
with:

0 commit comments

Comments
 (0)