Skip to content

Commit 3f19246

Browse files
committed
chore(workflows): do not publish wheels in pull requests
1 parent 3023bc9 commit 3f19246

File tree

1 file changed

+11
-3
lines changed

1 file changed

+11
-3
lines changed

.github/workflows/build.yml

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ jobs:
100100
runs-on: ubuntu-latest
101101
needs: [build-sdist, build-wheels]
102102
if: |
103-
github.repository == 'metaopt/TorchOpt' &&
103+
github.repository == 'metaopt/TorchOpt' && github.event_name != 'pull_request' &&
104104
(github.event_name != 'workflow_dispatch' || github.event.inputs.task == 'build-and-publish') &&
105105
(github.event_name != 'push' || startsWith(github.ref, 'refs/tags/'))
106106
timeout-minutes: 15
@@ -123,12 +123,20 @@ jobs:
123123
exit 1
124124
fi
125125
126-
- name: Download built sdist and wheels
126+
- name: Download built sdist
127127
uses: actions/download-artifact@v3
128128
with:
129129
# unpacks default artifact into dist/
130130
# if `name: artifact` is omitted, the action will create extra parent dir
131-
name: artifact
131+
name: sdist
132+
path: dist
133+
134+
- name: Download built wheels
135+
uses: actions/download-artifact@v3
136+
with:
137+
# unpacks default artifact into dist/
138+
# if `name: artifact` is omitted, the action will create extra parent dir
139+
name: wheels
132140
path: dist
133141

134142
- name: Publish to TestPyPI

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy