Allow filters at the workflow level for pr-triggered builds
complete
K
Kev Lee Wright
With a scheduled trigger, it's possible to specify a filter just one for multiple jobs. With a PR-trigger, there's no place in the config where this might go.
Probably easiest to achieve by adding pr as a trigger type in addition to schedule, and allowing multiple triggers in a block.
e.g.
workflows:
version: 2.1
my_flow:
triggers:
- schedule:
cron: "0 0 *"
filters:
branches:
only:
- master
- pr:
filters:
branches:
only:
- master
jobs:
.
.
.
CCI-I-804
Salil Subbakrishna
complete
Hi all, we just released a new logical operator, "matches" (https://circleci.com/docs/2.0/configuration-reference/#using-when-in-workflows) that returns true/false if a value (say the pipeline value for the branch or tag) matches a given regex. This can be used in the "when" at the workflow level to exclude workflows if the branch/tag does not match a pattern. While this doesn't use the "filters" tag, it is functionally equivalent and similar syntax.