Skip to content

Commit 9f166e3

Browse files
committed
Add wheels upload to anaconda
1 parent 511241f commit 9f166e3

File tree

1 file changed

+16
-1
lines changed

1 file changed

+16
-1
lines changed

.github/workflows/conda-package.yml

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,9 @@ jobs:
6363
run: conda config --remove channels defaults
6464

6565
- name: Store conda paths as envs
66-
run: echo "CONDA_BLD=$CONDA_PREFIX/conda-bld/${{ runner.os == 'Linux' && 'linux' || 'win' }}-64/" | tr "\\" '/' >> $GITHUB_ENV
66+
run: |
67+
echo "CONDA_BLD=$CONDA_PREFIX/conda-bld/${{ runner.os == 'Linux' && 'linux' || 'win' }}-64/" | tr "\\" '/' >> $GITHUB_ENV
68+
echo "WHEELS_OUTPUT_FOLDER=$GITHUB_WORKSPACE${{ runner.os == 'Linux' && '/' || '\\' }}" >> $GITHUB_ENV
6769
6870
# boa is an extention to conda so we can use mamba resolver in conda build
6971
- name: Install conda-build
@@ -78,6 +80,11 @@ jobs:
7880
name: ${{ env.PACKAGE_NAME }} ${{ runner.os }} Python ${{ matrix.python }}
7981
path: ${{ env.CONDA_BLD }}${{ env.PACKAGE_NAME }}-*.tar.bz2
8082

83+
- name: Upload wheels artifact
84+
uses: actions/upload-artifact@v3
85+
with:
86+
name: ${{ env.PACKAGE_NAME }} ${{ runner.os }} Wheels Python ${{ matrix.python }}
87+
path: ${{ env.WHEELS_OUTPUT_FOLDER }}${{ env.PACKAGE_NAME }}-*.whl
8188

8289
test:
8390
name: Test ['${{ matrix.os }}', python='${{ matrix.python }}']
@@ -217,6 +224,11 @@ jobs:
217224
with:
218225
name: ${{ env.PACKAGE_NAME }} ${{ runner.os }} Python ${{ matrix.python }}
219226

227+
- name: Download wheels artifact
228+
uses: actions/download-artifact@v3
229+
with:
230+
name: ${{ env.PACKAGE_NAME }} ${{ runner.os }} Wheels Python ${{ matrix.python }}
231+
220232
- name: Setup miniconda
221233
uses: conda-incubator/setup-miniconda@v2
222234
with:
@@ -233,3 +245,6 @@ jobs:
233245

234246
- name: Upload
235247
run: anaconda --token ${{ secrets.ANACONDA_TOKEN }} upload --user dppy --label dev ${{ env.PACKAGE_NAME }}-*.tar.bz2
248+
249+
- name: Upload Wheels
250+
run: anaconda --token ${{ secrets.ANACONDA_TOKEN }} upload --user dppy --label dev ${{ env.PACKAGE_NAME }}-*.whl

0 commit comments

Comments
 (0)