Only notify for some branches

slack
notifications
circle.yml
2.0

#1

In CircleCI v1, we use the experimental feature “only notify for some branches” on most of our projects;
https://circleci.com/account/notifications

experimental:
  notify:
    branches:
      only:
        - master
        - test

We’d like to have the same feature in v2.0


Build Chat Notifications
Experimental branch notifications from 1.0
#3

Good to know, there is now:

jobs:
      build:
        branches:
          only:
            - circleCI2

but then it doesn’t run at all.
It would be nice to still run but not notify.


Slack notifications on failed builds for specific branches
#4

Is there a way to limit chat notifications in 2.0?
Here’s the docs for 1.0: https://circleci.com/docs/1.0/configuration/#per-branch-notifications


#5

@rohara heya, can you perhaps give a status update on this? Is this something CircleCI is working on?


#6

@driesvints I don’t know where it fall on the roadmap but you can use the 1.0 syntax in your 2.0 config to achieve the same thing today


#7

How would that looks exactly? Would it still say experimental? Will it live under the job? Could you add this to the sample page https://circleci.com/docs/2.0/sample-config/?


#8

I just copied and pasted what I had from Circle CI 1.0 to the bottom of my .yml file and it worked.


#9

I tried using the CircleCI 1.0 syntax in a 2.0 build, but we still got notifications about a workflow failing in a side branch.

Any update on when branch specific notifications might be available in 2.0?


#10

The main issue with 2.0 is it notify on each job in workflow instead of sending just one notification about overall workflow!

We use workflow with 8 jobs, and only one of them is deploy job. As result we get 8 notifications in Slack channel per each deploy, which means we’ll have to switch off notifications until this will be fixed. :frowning:


#11