Skip to content

Commit 9865bf1

Browse files
committed
[CI/CD](linting_and_testing.yml): Update set-up micromamba.
1 parent c98e72a commit 9865bf1

File tree

1 file changed

+12
-10
lines changed

1 file changed

+12
-10
lines changed

.github/workflows/linting_and_testing.yml

Lines changed: 12 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -42,11 +42,13 @@ jobs:
4242
rm -rf /home/user/.bash_profile /home/user/.conda /home/user/micromamba /home/user/micromamba-bin 2>/dev/null
4343
touch /home/user/.bash_profile
4444
45-
- name: provision-with-micromamba
46-
uses: mamba-org/setup-micromamba@v1
45+
- name: setup-micromamba
46+
uses: mamba-org/setup-micromamba@v2.0.0
4747
with:
4848
generate-run-shell: true
49-
post-cleanup: all
49+
micromamba-version: '2.0.2-2'
50+
post-cleanup: 'all'
51+
init-shell: bash
5052
environment-file: .github/env.yaml
5153
create-args: >-
5254
python=${{ matrix.python-version }}
@@ -57,15 +59,15 @@ jobs:
5759
pip
5860
5961
- name: Install genbadge from pip
60-
shell: micromamba-shell {0} # necessary for conda env to be active
62+
shell: bash -l {0}
6163
run: pip install genbadge[all]
6264

6365
- name: List installed package versions
64-
shell: micromamba-shell {0} # necessary for conda env to be active
66+
shell: bash -l {0}
6567
run: micromamba list
6668

6769
- name: Lint with flake8
68-
shell: micromamba-shell {0} # necessary for conda env to be active
70+
shell: bash -l {0}
6971
run: |
7072
# F Codes: https://flake8.pycqa.org/en/latest/user/error-codes.html
7173
# E Code: https://pycodestyle.pycqa.org/en/latest/intro.html#error-codes
@@ -80,7 +82,7 @@ jobs:
8082
flake8 . --exclude=docs --ignore=C901,E226 --count --exit-zero --max-complexity=10 --max-line-length=9999 --statistics --format=html --htmldir=./reports/flake8/ --tee --output-file=./reports/flake8/flake8stats.txt
8183
8284
- name: Generate Flake8 badge
83-
shell: micromamba-shell {0} # necessary for conda env to be active
85+
shell: bash -l {0}
8486
run: |
8587
genbadge flake8 --name "Flake8" --input-file ./reports/flake8/flake8stats.txt --output-file ./reports/flake8/flake8badge.svg
8688
@@ -91,7 +93,7 @@ jobs:
9193
path: './biobb_common'
9294

9395
- name: Run tests
94-
shell: micromamba-shell {0} # necessary for conda env to be active
96+
shell: bash -l {0}
9597
run: |
9698
# Ignoring docker and singularity tests
9799
export PYTHONPATH=.:./biobb_common:$PYTHONPATH
@@ -103,12 +105,12 @@ jobs:
103105
pytest biobb_structure_utils/test/unitests/ --cov=biobb_structure_utils/ --cov-report=xml --ignore-glob=*container.py --ignore-glob=*docker.py --ignore-glob=*singularity.py --junit-xml=./reports/junit/junit.xml --html=./reports/junit/report.html
104106
105107
- name: Generate Tests badge
106-
shell: micromamba-shell {0} # necessary for conda env to be active
108+
shell: bash -l {0}
107109
run: |
108110
genbadge tests --name "Tests" --input-file ./reports/junit/junit.xml --output-file ./reports/junit/testsbadge.svg
109111
110112
- name: Generate Coverage badge
111-
shell: micromamba-shell {0} # necessary for conda env to be active
113+
shell: bash -l {0}
112114
run: |
113115
# Create directory for flake8 reports
114116
mkdir -p ./reports/coverage

0 commit comments

Comments
 (0)