When I have the following in my pipelines file, there is an error when the pipeline runs or if I try to run it:
tags: # Pipelines that will be triggered when a tag is pushed
'*.*.*':
- step: *publish-package
with the error
But it works with:
tags: # Pipelines that will be triggered when a tag is pushed
'*.*.*':
- step:
script:
- echo "TAGS"
The documentation
https://support.atlassian.com/bitbucket-cloud/docs/step-options/#The-Step-property is confusing because it insists that the script property is required, yet it works perfectly without for some pipeline:
branches: # Pipelines that run automatically on a commit to a specific branch, can also be triggered manually
'**': # This runs as default on all branches
- step: *build-and-test
What's going on?
After many hours of banging my head against the wall, I finally got to the bottom of this.
Turns out that one of the script lines for the publish-package step was
- git commit -m "Next Snapshot: ${PACKAGE_VERSION}"
Take careful note of the ':' within the delimited string - that was the offending character in the file. Once I removed the ':' all was well.
Nice bug.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.