Skip to content

Commit 5612a68

Browse files
committed
Move dev dependency specification to environment.yml
Delete the requirements-dev.txt file, and update the ci_test.yml to install GMT dependencies while setting up mamba.
1 parent 79cd804 commit 5612a68

File tree

4 files changed

+6
-36
lines changed

4 files changed

+6
-36
lines changed

.github/workflows/ci_tests.yaml

+4-15
Original file line numberDiff line numberDiff line change
@@ -79,28 +79,17 @@ jobs:
7979
# fecth all history so that setuptools-scm works
8080
fetch-depth: 0
8181

82-
# Setup Miniconda
83-
- name: Setup Miniconda
82+
# Install Mambaforge with GMT and other conda-forge dependencies
83+
- name: Setup Mambaforge with GMT and required dependencies
8484
uses: conda-incubator/setup-miniconda@2fc91a2ef82dfb50ded2d80e56f83b7039ba5955
8585
with:
8686
python-version: ${{ matrix.python-version }}
87+
environment-file: environment.yml
8788
miniforge-variant: Mambaforge
8889
miniforge-version: latest
90+
mamba-version: "*"
8991
use-mamba: true
9092

91-
# Install GMT and other required dependencies from conda-forge
92-
- name: Install GMT and required dependencies
93-
shell: bash -l {0}
94-
run: |
95-
requirements_file=full-conda-requirements.txt
96-
cat requirements.txt requirements-dev.txt > $requirements_file
97-
cat << EOF >> $requirements_file
98-
gmt=6.1.1
99-
make
100-
codecov
101-
EOF
102-
mamba install --yes --file $requirements_file
103-
10493
# Show installed pkg information for postmortem diagnostic
10594
- name: List installed packages
10695
shell: bash -l {0}

environment.yml

+2-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@ channels:
33
- conda-forge
44
- defaults
55
dependencies:
6-
- python=3.8
76
- pip
87
- gmt=6.1.1
98
- numpy
@@ -13,12 +12,14 @@ dependencies:
1312
- packaging
1413
- black
1514
- blackdoc
15+
- codecov
1616
- coverage[toml]
1717
- docformatter
1818
- flake8
1919
- ipython
2020
- isort>=5
2121
- jupyter
22+
- make
2223
- matplotlib
2324
- nbsphinx
2425
- pylint

requirements-dev.txt

-19
This file was deleted.

requirements.txt

-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
# Requirements for installing with conda
21
numpy
32
pandas
43
xarray

0 commit comments

Comments
 (0)