Skip to content

Commit 536baed

Browse files
committed
chore: add condition
1 parent 2b94c46 commit 536baed

File tree

1 file changed

+12
-3
lines changed

1 file changed

+12
-3
lines changed

.github/workflows/release-continuous.yml

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,21 @@
1-
name: Publish Any Commit
2-
on: [push, pull_request]
1+
name: Preview Publish
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
pull_request:
8+
types: [opened, synchronize, labeled]
39

410
permissions: {}
511

612
jobs:
713
preview:
14+
if: >
15+
github.repository == 'vitejs/vite-plugin-react' &&
16+
(github.event_name == 'push' ||
17+
(github.event_name == 'pull_request' && contains(github.event.pull_request.labels.*.name, 'trigger: preview')))
818
runs-on: ubuntu-latest
9-
1019
steps:
1120
- name: Checkout code
1221
uses: actions/checkout@v4

0 commit comments

Comments
 (0)