Skip to content

Commit

Permalink
Workaround for Windows (PATH)
Browse files Browse the repository at this point in the history
  • Loading branch information
joanlopez committed Nov 19, 2024
1 parent ee1f19c commit f8db653
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions .github/workflows/xk6.yml
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,13 @@ jobs:
"${{ github.event.pull_request.head.repo.full_name }}" != "${{ github.repository }}" ]; then
export XK6_K6_REPO="github.com/${{ github.event.pull_request.head.repo.full_name }}"
fi
# The following is a workaround for Windows, cause when using 'shell: bash', the PATH is expressed
# with ':' as separator, but Go code, running on a Windows OS, expects ';' as separator.
XPATH="$PATH"
if [[ "${{ matrix.platform }}" == "windows-latest" || "${{ matrix.platform }}" == "windows-2019" ]]; then
XPATH="${PATH//:/;}"
fi
PATH="$XPATH" \
GOPRIVATE="go.k6.io/k6" xk6 build "$COMMIT_ID" \
--output ./k6ext \
--with github.com/grafana/xk6-js-test="$(pwd)/xk6-js-test" \
Expand Down

0 comments on commit f8db653

Please sign in to comment.