Hello All,
We are just getting into pipelines and I've been trying to configure a pipeline to run a maven spotless plugin goal for all PRs on a specific branch without success.
pipelines:
pull-requests:
<INSERT_BRANCH_NAME_HERE>:
- step:
name: Spotless Check
image: maven:3.6.3
caches:
- maven
script:
mvn spotless:check
condition:
changesets:
includePaths:
- <INERT_DIRECTORY_HERE>/**
The bitbucket-pipelines.yml is in the root of the repository (e.g. a repository named central), INSERT_BRANCH_NAME_HERE would be the target branch the PR is being merged into (e.g. a branch named release/v1.0) and INSERT_DIRECTORY_HERE would be a directory the pipeline is limited to (e.g. a directory called support).
If I create a PR from "release/v1.0-TICKET_NUMBER" into "release/v1.0" which contains a modification to "support/src/Helper.java" I would have expected it to trigger a pipeline build, but that isn't the case. If I trigger the pipeline manually the build fails or succeeds correctly (depending on the formatting of the change). The manual build is also associated with the PR (seen on the right hand side of the bitbucket PR).
Any suggestions on debugging a pipeline triggering issue as such?
Thanks,
MM