-
Notifications
You must be signed in to change notification settings - Fork 55
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[JENKINS-56321] Scan detached plugins to get proper group id #116
[JENKINS-56321] Scan detached plugins to get proper group id #116
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
m = Pattern.compile("WEB-INF/(?:optional-)?plugins/([^/.]+)[.][hj]pi").matcher(name); | ||
// We should also scan detached plugins to make sure we get the proper groupId for detached not using the | ||
// default org.jenkins-ci one | ||
m = Pattern.compile("WEB-INF/(?:(optional-|detached-))?plugins/([^/.]+)[.][hj]pi").matcher(name); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess the -
char could be moved as below:
m = Pattern.compile("WEB-INF/(?:(optional-|detached-))?plugins/([^/.]+)[.][hj]pi").matcher(name); | |
m = Pattern.compile("WEB-INF/(?:(optional|detached)-)?plugins/([^/.]+)[.][hj]pi").matcher(name); |
Although, It's not a blocker from my PoV
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
By the way, is -
character a special character or only when between []
?
This change seems to have had the perhaps unexpected effect of making it so that if you just pass |
I will see. If I stop using CWP as in jenkinsci/custom-war-packager#108 then I think I do not care about this anyway since I could just make the WAR contain exactly what I need. |
JENKINS-56321
Detached plugins are added with default group id, this makes
jaxb
to be added with the wrong group id. Given that detached are always embedded into the war it makes sense to also scan group ids for detached plugins as is done for embedded ones. As a result, any detached plugin with a group id different fromorg.jenkins-ci.plugins
(like 'jaxb
) is going to be properly added