Skip to content

Commit a5d6b45

Browse files
committed
四平台构建测试
1 parent 00110bd commit a5d6b45

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

.github/workflows/multi-platform-build.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -123,19 +123,19 @@ jobs:
123123
retention-days: 30
124124

125125
- name: Login to Anaconda with API token
126-
if: steps.should_build.outputs.should_build == 'true' && (github.event.inputs.upload_to_anaconda == 'true' || github.ref == 'refs/heads/main')
126+
if: steps.should_build.outputs.should_build == 'true' && (github.event.inputs.upload_to_anaconda == 'true' || (github.ref == 'refs/heads/main' && github.event_name != 'pull_request'))
127127
run: |
128128
anaconda login --token ${{ secrets.ANACONDA_API_TOKEN }}
129129
130130
- name: Upload to Anaconda.org (unilab organization)
131-
if: steps.should_build.outputs.should_build == 'true' && (github.event.inputs.upload_to_anaconda == 'true' || github.ref == 'refs/heads/main')
131+
if: steps.should_build.outputs.should_build == 'true' && (github.event.inputs.upload_to_anaconda == 'true' || (github.ref == 'refs/heads/main' && github.event_name != 'pull_request'))
132132
run: |
133133
for package in $(find ./output -name "*.conda"); do
134134
echo "Uploading $package to unilab organization..."
135135
anaconda upload --user unilab --force "$package"
136136
done
137137
138138
- name: Logout from Anaconda
139-
if: always() && steps.should_build.outputs.should_build == 'true' && (github.event.inputs.upload_to_anaconda == 'true' || github.ref == 'refs/heads/main')
139+
if: always() && steps.should_build.outputs.should_build == 'true' && (github.event.inputs.upload_to_anaconda == 'true' || (github.ref == 'refs/heads/main' && github.event_name != 'pull_request'))
140140
run: |
141141
anaconda logout || true

0 commit comments

Comments
 (0)