-
Improvement
-
Resolution: Unresolved
-
Minor
-
None
I want to use the Bitbucket branch source in a multibranch pipeline, but only build commits that involve a change to certain paths. As I understand, this could be accomplished by writing a BranchBuildStrategy plugin, but such a plugin would need to use the changesSince() method, which is unimplemented in BitbucketSCMFileSystem.
If anyone knows of another way to accomplish this, please let me know.
- is related to
-
JENKINS-75410 make BitbucketSCMSource extends AbstractGitSCMSource
-
- Open
-
Hi, I faced the same problem recently. I try to integrate a monorepo with many Jenkinsfile (~30) and for basic branch I could use this plugin https://plugins.jenkins.io/multibranch-build-strategy-extension/ to include build by region.
But for PR it doesn't work, the problem is that the build strategy extension used code that try to cast the BitbucketSCMSource to AbstractGitSCMSource that throw an exception.
After digging in the code I think it's best to extends AbstractGitSCMSource instead of SCMSource for BitbucketSCMSource, we then need to implement just one method getRemote() that should return the correct url for git clone regarding the current context.
WDYT ?