[FIX] use a specific shell in different step #11
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CI | |
on: | |
push: | |
branches: [main, develop, release/*] | |
pull_request: | |
branches: [main, develop, release/*] | |
jobs: | |
full-install-CI: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Setup Conda | |
uses: conda-incubator/setup-miniconda@v3 | |
with: | |
activate-environment: pyrosys | |
- name: Build | |
shell: bash -el {0} | |
env: | |
WORKSPACE: ${{ github.workspace }} | |
run: | | |
.ci/autosetup.sh | |
- name: Run Ruff Check | |
shell: bash -el {0} | |
run: | | |
echo "Activating conda environment for Ruff Check" | |
source activate pyrosys | |
mkdir -p reports | |
ruff check src --fix --output-format=junit --output-file=reports/ruff-lint.xml | |
- name: Publish Ruff Results | |
uses: dorny/test-reporter@v1 | |
if: success() || failure() | |
with: | |
name: Ruff Tests | |
path: reports/ruff-lint.xml | |
reporter: java-junit | |
- name: Run Ruff Format | |
shell: bash -el {0} | |
run: | | |
echo "Activating conda environment for Ruff Format" | |
source activate pyrosys | |
ruff format . --diff | |
- name: Run Mypy | |
continue-on-error: true | |
shell: bash -el {0} | |
run: | | |
echo "Activating conda environment for Mypy" | |
source activate pyrosys | |
mkdir -p reports | |
mypy src tests > reports/mypy.log | |
- name: Upload Mypy Results | |
uses: actions/upload-artifact@v4 | |
with: | |
name: mypy-results | |
path: reports/mypy.log | |
- name: Run Tests | |
shell: bash -el {0} | |
run: | | |
echo "Activating conda environment for Tests" | |
source activate pyrosys | |
mkdir -p reports | |
pytest --junit-xml=reports/unittest.xml ./tests | |
- name: Publish Test Results | |
uses: dorny/test-reporter@v1 | |
if: success() || failure() | |
with: | |
name: Pytest Tests | |
path: reports/unittest.xml | |
reporter: java-junit |