You've been invited into the Kudos (beta program) private group. Chat with others in the program, or give feedback to Atlassian.
View groupJoin the community to find out what other Atlassian users are discussing, debating and creating.
I wonder if it is possible to echo what were the modified paths between two pull requests using the new feature "changesets"
I have something like that in mind:
- step:
name: step1
condition:
changesets:
- echo changesets
Yes, the information is available by the version control system which is accessible by the git utility. As long as you have it in your build container.
The includePaths directive checks for modified paths.
You can obtain the information by listing modified files between HEAD and the appropriate ancestor which is different depending on the type of the pipeline:
In a pull-request pipeline, all commits are taken into account, and if you provide an
includePath
list of patterns, a step will be executed when at least one commit change matches one of the conditions.
and:
For other types of pipelines, only the last commit is considered.
To show all changed files for the last commit:
git diff --name-only
For the pull request pipeline I don't have one at hand to verify it, the "Build setup" in such a Pipeline should show whether or not the merge is already committed, if so it could be the same or you can diff to the merge base:
git diff --name-only $(git merge-base "${BITBUCKET_PR_DESTINATION_BRANCH}" HEAD)
Use the `--diff-filter` switch to fine-tune which paths are displayed, `--name-status` to show the status of each path and mind path quoting (use `-z` for null-byte separated paths).
Reference:
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
...hey are a part of us, shaping how we interact with the world around us. The same holds true for programming languages when we think about how different kinds of vulnerabilities raise their heads in t...
Connect with like-minded Atlassian users at free events near you!
Find an eventConnect with like-minded Atlassian users at free events near you!
Unfortunately there are no Community Events near you at the moment.
Host an eventYou're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.