Skip to content

Commit d62d507

Browse files
committed
use dedicated build environments in Windows workflow
1 parent 161946e commit d62d507

File tree

2 files changed

+13
-17
lines changed

2 files changed

+13
-17
lines changed

.github/workflows/conda-package-cf.yml

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -155,7 +155,9 @@ jobs:
155155
156156
build_windows:
157157
runs-on: windows-latest
158-
158+
defaults:
159+
run:
160+
shell: cmd /C CALL {0}
159161
strategy:
160162
matrix:
161163
include:
@@ -182,16 +184,15 @@ jobs:
182184

183185
- uses: conda-incubator/setup-miniconda@fc2d68f6413eb2d87b895e92f8584b5b94a10167 # v3.3.0
184186
with:
185-
miniforge-variant: Miniforge3
186187
miniforge-version: latest
187-
auto-activate: true
188-
activate-environment: base
188+
activate-environment: build
189189
channels: conda-forge
190-
conda-remove-defaults: true
191190
python-version: ${{ matrix.python }}
192191

193192
- name: Install conda-build
194-
run: conda install -n base conda-build
193+
run: |
194+
conda install -n base -y conda-build
195+
conda list -n base
195196
196197
- name: Cache conda packages
197198
uses: actions/cache@cdf6c1fa76f9f475f3d7449005a359c84ca0f306 # v5.0.3
@@ -207,7 +208,6 @@ jobs:
207208
208209
- name: Build conda package with NumPy 2.x
209210
run: |
210-
conda activate
211211
conda build --no-test --python ${{ matrix.python }} --numpy ${{ matrix.numpy }} -c conda-forge --override-channels conda-recipe-cf
212212
213213
- name: Store conda paths as envs
@@ -249,7 +249,6 @@ jobs:
249249
with:
250250
miniforge-version: latest
251251
channels: conda-forge
252-
conda-remove-defaults: true
253252
activate-environment: ${{ env.TEST_ENV_NAME }}
254253
python-version: ${{ matrix.python }}
255254

.github/workflows/conda-package.yml

Lines changed: 6 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -155,7 +155,9 @@ jobs:
155155
156156
build_windows:
157157
runs-on: windows-latest
158-
158+
defaults:
159+
run:
160+
shell: cmd /C CALL {0}
159161
strategy:
160162
matrix:
161163
python: ["3.10", "3.11", "3.12", "3.13", "3.14"]
@@ -171,18 +173,15 @@ jobs:
171173

172174
- uses: conda-incubator/setup-miniconda@fc2d68f6413eb2d87b895e92f8584b5b94a10167 # v3.3.0
173175
with:
174-
miniforge-variant: Miniforge3
175176
miniforge-version: latest
176-
auto-activate: true
177-
activate-environment: base
177+
activate-environment: build
178178
channels: conda-forge
179-
conda-remove-defaults: true
180179
python-version: ${{ matrix.python }}
181180

182181
- name: Install conda-build
183182
run: |
184-
conda activate
185-
conda install -n base conda-build
183+
conda install -n base -y conda-build
184+
conda list -n base
186185
187186
- name: Cache conda packages
188187
uses: actions/cache@cdf6c1fa76f9f475f3d7449005a359c84ca0f306 # v5.0.3
@@ -198,7 +197,6 @@ jobs:
198197
199198
- name: Build conda package
200199
run: |
201-
conda activate
202200
conda build --no-test --python ${{ matrix.python }} -c https://software.repos.intel.com/python/conda -c conda-forge --override-channels conda-recipe
203201
204202
- name: Store conda paths as envs
@@ -239,7 +237,6 @@ jobs:
239237
with:
240238
miniforge-version: latest
241239
channels: conda-forge
242-
conda-remove-defaults: true
243240
activate-environment: ${{ env.TEST_ENV_NAME }}
244241
python-version: ${{ matrix.python }}
245242

0 commit comments

Comments
 (0)