Search code examples
mavengrailsjar

How to add a third party jar to Maven central


I have a few jars which I have downloaded and kept in the lib folder of a grails project. Now I need to download third-party jars from maven.

For example JRI.jar, which is a third-party jar, until now I have downloaded and kept in the grails project's lib folder.

<dependency>
  <groupId>org.nuiton.thirdparty</groupId>
  <artifactId>JRI</artifactId>
  <version>0.9-6</version>
</dependency>

I have found this here but I am not using pom.xml to specify. I need to specify it in grails BuildConfig.groovy file.

What is the correct way to do it?


Solution

  • For BuildConfig.groovy you can use the Gradle format: 'org.nuiton.thirdparty:JRI:0.9-6'

    dependencies {
        compile 'org.nuiton.thirdparty:JRI:0.9-6'
    }