Uploaded image for project: 'Bitbucket Cloud'
  1. Bitbucket Cloud
  2. BCLOUD-17730

Skip specific types of pipelines based on commit message

    XMLWordPrintable

Details

    • Our product teams collect and evaluate feedback from a number of different sources. To learn more about how we use customer feedback in the planning process, check out our new feature policy.

    Description

      I'm aware of the [skip ci] tag, which is super useful, but there are some cases where a little more control is required. For example, let's say I don't want to trigger a branches pipeline but I do want to be able to trigger a tags pipeline, it would be nice if I could just add something like [skip branches] in the commit message, that way branches pipelines are not triggered but everything else is.

      Practical example:

      #!python
      
      pipelines:
        branches:
          master:
            - step:
                script:
      			- echo "Auto version up"
      			- echo "Commit and push with [skip branches] in message" # Avoid endless loop
      
        tags:
          external/**:
            - step:
                script:
      			- echo "Create build"
      

      In the example above I want to automatically version up my application every time a new change is pushed to master and I want to create a build every time a commit in master is tagged as external/**.

      Attachments

        Activity

          People

            Unassigned Unassigned
            4e43d8e3ed87 Alejandro Cotilla
            Votes:
            10 Vote for this issue
            Watchers:
            7 Start watching this issue

            Dates

              Created:
              Updated: