Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
- Skip Netlify deploy previews for `sec/*`, `outreach/*`, `ops/*` and `automation/*` bot branches as well (#426).
2 changes: 1 addition & 1 deletion netlify.toml
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@
# quota (#419). Production builds of main are unaffected: this rule only
# applies in the deploy-preview context. exit 0 = skip, exit 1 = build.
[context.deploy-preview]
ignore = "case \"${HEAD:-$BRANCH}\" in arch/*|scanner/*|quality/*|hive/*|dependabot/*) exit 0;; *) exit 1;; esac"
ignore = "case \"${HEAD:-$BRANCH}\" in arch/*|scanner/*|quality/*|sec/*|outreach/*|ops/*|automation/*|hive/*|dependabot/*) exit 0;; *) exit 1;; esac"

# Enable branch deploys for documentation versioning
# Version branches follow the pattern: docs/{version}
Expand Down
5 changes: 5 additions & 0 deletions src/__tests__/netlify-deploy-preview-ignore.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,10 @@ describe("netlify.toml [context.deploy-preview] ignore", () => {
"arch/docs",
"scanner/fix-419",
"quality/test-netlify-ignore",
"sec/fix-markdown-it-15-0-3",
"outreach/docs-issue-forms",
"ops/runbook-healthz-field",
"automation/meeting-recordings-refresh",
"hive/forward-merge",
"dependabot/npm_and_yarn/next-16.4.1",
])("skips the preview for bot branch %s", head => {
Expand All @@ -81,6 +85,7 @@ describe("netlify.toml [context.deploy-preview] ignore", () => {
// the patterns are anchored to the start of the branch name.
"feat/scanner/dashboard",
"myquality/notes",
"myops/notes",
])("builds the preview for non-bot branch %s", head => {
expect(runIgnore(ignore!, { HEAD: head, BRANCH: head })).toBe(BUILD);
});
Expand Down
Loading