Skip to content

Commit a2cce42

Browse files
committed
inspect deploy job before doing the release
1 parent 030bef9 commit a2cce42

File tree

1 file changed

+41
-2
lines changed

1 file changed

+41
-2
lines changed

.github/workflows/test-and-deploy.yml

Lines changed: 41 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,7 @@ jobs:
110110
pytest GPy/testing
111111
112112
build-windows:
113-
if: github.event_name == 'release'
113+
# if: github.event_name == 'release'
114114
strategy:
115115
matrix:
116116
os: [windows-latest]
@@ -143,7 +143,7 @@ jobs:
143143
path: dist
144144

145145
build-macos:
146-
if: github.event_name == 'release'
146+
# if: github.event_name == 'release'
147147
strategy:
148148
matrix:
149149
os: [macos-latest]
@@ -243,6 +243,45 @@ jobs:
243243
# name: dist-artifacts-manylinux-${{ matrix.python }}
244244
# path: dist/*
245245

246+
deploy-test:
247+
runs-on: ubuntu-latest
248+
needs: [test-windows, test-linux, test-macos, build-linux, build-windows, build-macos]
249+
# if: github.event_name == 'release'
250+
steps:
251+
- name: Checkout
252+
uses: actions/checkout@v4
253+
254+
- name: Setup python
255+
uses: actions/setup-python@v4
256+
with:
257+
python-version: '3.9'
258+
259+
- name: Install twine
260+
run: |
261+
pip install --upgrade pip
262+
pip install twine
263+
264+
- name: Download all artifacts to a specific directory
265+
uses: actions/download-artifact@v3
266+
with:
267+
path: dist
268+
269+
- name: Create dist directory
270+
run: mkdir -p dist
271+
272+
- name: Move files from subdirectories
273+
run: |
274+
for subdirectory in dist/*/; do
275+
dir_name=$(basename "$subdirectory")
276+
mv "$subdirectory"* dist/
277+
rm -r "$subdirectory"
278+
echo "Moved files from '$dir_name' to 'dist/'"
279+
done
280+
281+
- name: Inspect wheel files
282+
run: |
283+
ls -R dist
284+
246285
deploy:
247286
runs-on: ubuntu-latest
248287
needs: [test-windows, test-linux, test-macos, build-linux, build-windows, build-macos]

0 commit comments

Comments
 (0)