.gitlab-ci.yml configuration to spectific branch

I’m following the git flow brancing approach, now I need to start the CI only when the branch name start like “feature/” I read about the CI config file flags [only / excepts] but it works for JOBs and I need to put it in a branch level.
Someone knows how I can do it?

Hello,

Check this example, maybe it can help you:

publish-dev:
  stage: publish
  script:
    - echo 'Subiendo archivo'
  only:
    - dev@namespace/project

Regards,

Well… thanks for your reply.
For ‘only’ statement I’m using regExp… I didn’t understand yet this pattern dev@namespace/projetc
only:
- /^feature.*/

Try this

- /^feature.*/@yourgroup/yourproject