Skip to content

Commit

Permalink
[CI] Address problems with cygwin (#4832)
Browse files Browse the repository at this point in the history
  • Loading branch information
abravalheri authored Feb 17, 2025
2 parents a3cc40f + 9d6ade8 commit ba24375
Showing 1 changed file with 9 additions and 3 deletions.
12 changes: 9 additions & 3 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,7 @@ jobs:
packages: >-
python${{ matrix.python }},
python${{ matrix.python }}-devel,
python${{ matrix.python }}-tox,
python${{ matrix.python }}-pip,
gcc-core,
git,
- name: Record the currently selected Python version
Expand All @@ -193,11 +193,17 @@ jobs:
run: |
python -c 'import platform; print("python-version=" + platform.python_version())' >> ${GITHUB_OUTPUT}
shell: C:\cygwin\bin\env.exe CYGWIN_NOWINPATH=1 CHERE_INVOKING=1 C:\cygwin\bin\bash.exe -leo pipefail -o igncr {0}
- name: Install tox using pip
shell: C:\cygwin\bin\env.exe CYGWIN_NOWINPATH=1 CHERE_INVOKING=1 C:\cygwin\bin\bash.exe -leo pipefail -o igncr {0}
run: |
# Workaround for https://github.com/pypa/setuptools/issues/4831
python -m pip install tox
- name: Run tests
shell: C:\cygwin\bin\env.exe CYGWIN_NOWINPATH=1 CHERE_INVOKING=1 C:\cygwin\bin\bash.exe -leo pipefail -o igncr {0}
run: |
git config --global --add safe.directory "$(cygpath -u "$GITHUB_WORKSPACE")" # workaround for #3408
tox
git config --global --add safe.directory "$(cygpath -u "${{ github.workspace }}")" # workaround for #3408
echo "$(cygpath -u "${{ github.workspace }}")" # for debugging purposes
python -m tox
- name: Create coverage report
if: hashFiles('.coverage') != '' # Rudimentary `file.exists()`
run: |
Expand Down

0 comments on commit ba24375

Please sign in to comment.