Skip to content

Commit e610a0c

Browse files
committed
ci: Deploy only on push to master
The deploy workflow used `on: push` with `branches: []`, which GitHub treats as no filter — so it ran on pushes to every branch (including PR branches). Restrict it to the master branch so it deploys only on merge.
1 parent 1fe0682 commit e610a0c

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

.github/workflows/nextjs.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,9 @@
55
name: Deploy Next.js site to Pages
66

77
on:
8-
# Runs on pushes targeting the default branch
8+
# Runs on pushes targeting the default branch (i.e. on merge to master)
99
push:
10-
branches: []
10+
branches: ["master"]
1111

1212
# Allows you to run this workflow manually from the Actions tab
1313
workflow_dispatch:

0 commit comments

Comments
 (0)