@@ -23,54 +23,65 @@ jobs:
23
23
24
24
- name : Checkout flopy repo
25
25
uses : actions/checkout@v4
26
-
27
- - name : Setup Python
28
- uses : astral-sh/setup-uv@v6
29
26
with :
30
- cache-dependency-glob : " **/pyproject.toml"
31
-
32
- - name : Install FloPy
33
- run : uv sync --all-extras
27
+ path : flopy
34
28
35
- - name : Install other dependencies from GitHub
36
- run : uv pip install -r etc/requirements.mf6.txt
29
+ - name : Checkout MODFLOW 6
30
+ uses : actions/checkout@v4
31
+ with :
32
+ repository : MODFLOW-ORG/modflow6
33
+ path : modflow6
37
34
38
35
- name : Setup GNU Fortran
39
36
uses : fortran-lang/setup-fortran@v1
40
37
with :
41
38
compiler : gcc
42
39
version : 13
43
40
44
- - name : Checkout MODFLOW 6
45
- uses : actions/checkout@v4
41
+ - name : Setup pixi
42
+ uses :
prefix-dev/[email protected]
46
43
with :
47
- repository : MODFLOW-ORG/modflow6
48
- path : modflow6
44
+ pixi-version : v0.41.4
45
+ manifest- path : modflow6/pixi.toml
49
46
50
- - name : Build and install MF6
47
+ - name : Install dependencies
51
48
working-directory : modflow6
52
49
run : |
53
- uv run meson setup builddir --buildtype=debugoptimized --prefix=$(pwd) --libdir=bin
54
- uv run meson install -C builddir
55
- uv run meson test --verbose --no-rebuild -C builddir
50
+ pixi run install
51
+ pixi run pip install coverage pytest-cov
56
52
57
- - name : Update package classes
58
- working-directory : modflow6/autotest
59
- run : uv run update_flopy.py
53
+ - name : Install FloPy
54
+ working-directory : flopy
55
+ run : |
56
+ pixi run --manifest-path=../modflow6/pixi.toml pip install --no-deps -e .
57
+ pixi run --manifest-path=../modflow6/pixi.toml python -m flopy.mf6.utils.generate_classes --dfnpath ../modflow6/doc/mf6io/mf6ivar/dfn
58
+
59
+ - name : Build MF6
60
+ working-directory : modflow6
61
+ run : |
62
+ pixi run meson setup builddir --buildtype=debugoptimized --prefix=$(pwd) --libdir=bin
63
+ pixi run meson install -C builddir
64
+ pixi run meson test --verbose --no-rebuild -C builddir
65
+
66
+ - name : Build mf5to6 converter
67
+ working-directory : modflow6/utils/mf5to6
68
+ run : |
69
+ pixi run meson setup builddir --prefix=$(pwd)/../../ --libdir=bin
70
+ pixi run meson install -C builddir
60
71
61
72
- name : Install executables
62
73
working-directory : modflow6/autotest
63
74
env :
64
75
GITHUB_TOKEN : ${{ github.token }}
65
- run : uv run pytest -v --durations=0 get_exes.py
76
+ run : pixi run pytest -v --durations=0 get_exes.py
66
77
67
78
- name : Run tests
68
79
working-directory : modflow6/autotest
69
- run : uv run pytest -v --cov=flopy --cov-report=xml --cov-append --durations=0 -n auto -m "not repo and not regression"
80
+ run : pixi run pytest -v --cov=flopy --cov-report=xml --cov-append --durations=0 -n auto -m "not repo and not regression"
70
81
71
82
- name : Print coverage report before upload
72
83
working-directory : ./modflow6/autotest
73
- run : uv run coverage report
84
+ run : pixi run coverage report
74
85
75
86
- name : Upload coverage to Codecov
76
87
if :
86
97
run :
87
98
shell : bash
88
99
steps :
89
-
100
+
90
101
- name : Checkout flopy repo
91
102
uses : actions/checkout@v4
103
+ with :
104
+ path : flopy
92
105
93
106
- name : Checkout MODFLOW 6
94
107
uses : actions/checkout@v4
@@ -102,38 +115,39 @@ jobs:
102
115
repository : MODFLOW-ORG/modflow6-examples
103
116
path : modflow6-examples
104
117
105
- - name : Setup Python
106
- uses : astral-sh/setup-uv@v6
107
- with :
108
- cache-dependency-glob : " **/pyproject.toml"
109
-
110
- - name : Install FloPy
111
- run : uv sync --all-extras
112
-
113
- - name : Install other dependencies from modflow6-examples and GitHub
114
- run : uv pip install -r etc/requirements.mf6.txt -r modflow6-examples/etc/requirements.pip.txt
115
-
116
118
- name : Setup GNU Fortran
117
119
uses : fortran-lang/setup-fortran@v1
118
120
with :
119
121
compiler : gcc
120
122
version : 13
121
123
124
+ - name : Setup pixi
125
+ uses :
prefix-dev/[email protected]
126
+ with :
127
+ pixi-version : v0.41.4
128
+ manifest-path : modflow6/pixi.toml
129
+
130
+ - name : Install dependencies
131
+ working-directory : modflow6
132
+ run : pixi run install
133
+
134
+ - name : Install FloPy
135
+ working-directory : flopy
136
+ run : |
137
+ pixi run --manifest-path=../modflow6/pixi.toml pip install --no-deps -e .
138
+ pixi run --manifest-path=../modflow6/pixi.toml python -m flopy.mf6.utils.generate_classes --dfnpath ../modflow6/doc/mf6io/mf6ivar/dfn
139
+
122
140
- name : Install executables
123
141
uses : modflowpy/install-modflow-action@v1
124
142
125
143
- name : Build and install MF6
126
144
working-directory : modflow6
127
145
run : |
128
- uv run meson setup builddir --buildtype=debugoptimized --prefix=$(pwd) --libdir=bin
129
- uv run meson install -C builddir
130
- uv run meson test --verbose --no-rebuild -C builddir
146
+ pixi run meson setup builddir --buildtype=debugoptimized --prefix=$(pwd) --libdir=bin
147
+ pixi run meson install -C builddir
148
+ pixi run meson test --verbose --no-rebuild -C builddir
131
149
cp bin/* ~/.local/bin/modflow/
132
150
133
- - name : Update package classes
134
- working-directory : modflow6/autotest
135
- run : uv run update_flopy.py
136
-
137
151
- name : Test MF6 examples
138
152
working-directory : modflow6-examples/autotest
139
- run : uv run pytest -v -n=auto --durations=0 test_scripts.py
153
+ run : pixi run --manifest-path=../../modflow6/pixi.toml pytest -v -n=auto --durations=0 test_scripts.py
0 commit comments