Skip to content

Commit e0990ee

Browse files
committed
add branch and path filters
1 parent fb2924f commit e0990ee

3 files changed

Lines changed: 10 additions & 3 deletions

File tree

.github/workflows/03-triggers.yaml

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,16 @@ name: Triggering Events
33

44
on:
55
### https://docs.github.com/en/actions/writing-workflows/choosing-when-your-workflow-runs/events-that-trigger-workflows#push
6-
# push:
7-
# branches:
8-
# - main
6+
push:
7+
branches:
8+
# Filter patterns cheat sheet:
9+
# https://docs.github.com/en/actions/writing-workflows/workflow-syntax-for-github-actions#filter-pattern-cheat-sheet
10+
- "example-branch/*"
11+
paths:
12+
# include markdown files
13+
- "02-mechanics-core/filters/*.md"
14+
# Exclude txt files
15+
- "!02-mechanics-core/filters/*.txt"
916

1017
### https://docs.github.com/en/actions/writing-workflows/choosing-when-your-workflow-runs/events-that-trigger-workflows#pull_request
1118
# pull_request:

02-mechanics-core/filters/excluded-file.txt

Whitespace-only changes.

02-mechanics-core/filters/included-file.md

Whitespace-only changes.

0 commit comments

Comments
 (0)