Skip to content
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

Fix scope of dependencies #78

Merged
merged 1 commit into from
Feb 13, 2025
Merged

Fix scope of dependencies #78

merged 1 commit into from
Feb 13, 2025

Conversation

basil
Copy link
Member

@basil basil commented Feb 12, 2025

While attempting to link oic-auth-plugin against this plugin with

diff --git a/pom.xml b/pom.xml
index 399325c..400161c 100644
--- a/pom.xml
+++ b/pom.xml
@@ -89,6 +89,11 @@
       <groupId>io.jenkins.plugins</groupId>
       <artifactId>commons-text-api</artifactId>
     </dependency>
+    <dependency>
+      <groupId>io.jenkins.plugins</groupId>
+      <artifactId>json-path-api</artifactId>
+    </dependency>
     <dependency>
       <groupId>org.jenkins-ci.plugins</groupId>
       <artifactId>jackson2-api</artifactId>
@@ -175,6 +179,11 @@
           <groupId>commons-text</groupId>
           <artifactId>commons-text</artifactId>
         </exclusion>
+        <exclusion>
+          <!-- consume from json-path-api plugin -->
+          <groupId>net.minidev</groupId>
+          <artifactId>json-smart</artifactId>
+        </exclusion>
         <exclusion>
           <!-- consume from Jenkins core -->
           <groupId>org.slf4j</groupId>

I got compilation errors because the Json-smart dependencies were in runtime scope rather than compile scope. With this PR the problem is solved and I can use this library plugin from consumers that need to link against Json-smart at compile time.

@basil basil added the bug For changelog: Minor bug. Will be listed after features label Feb 12, 2025
@basil basil requested a review from a team as a code owner February 12, 2025 23:16
@jonesbusy
Copy link
Contributor

Thanks!

@jonesbusy jonesbusy merged commit 22a7ffe into jenkinsci:main Feb 13, 2025
16 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug For changelog: Minor bug. Will be listed after features
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants