Reputation: 139
I want to use an sql parsing library from github:
The page says, that the following Maven
tags are needed in pom.xml
to import it.
<repositories>
<repository>
<id>jsqlparser-snapshots</id>
<snapshots>
<enabled>true</enabled>
</snapshots>
<url>https://oss.sonatype.org/content/groups/public/</url>
</repository>
</repositories>
<dependency>
<groupId>com.github.jsqlparser</groupId>
<artifactId>jsqlparser</artifactId>
<version>1.1</version>
</dependency>
However, I am using gradle. So the dependency
section in the above pom.xml
would transform into gradle.build
more or less like that:
dependencies {
compile("com.github.jsqlparser:jsqlparser:1.1")
}
But I don't know how to transform the content of repository
tag, particulary snapshot
and url
.
Upvotes: 2
Views: 833
Reputation: 38734
Do you really want to use snapshot builds, which is latest development version that might break stuff inadvertently? If not, you read the instructions wrongly. You can simply use mavenCentral()
or jcenter()
as Gradle repository for your build to get the latest released version of that library.
If you really want the snapshot versions, you use maven { url 'https://oss.sonatype.org/content/groups/public' }
and use x.y-SNAPSHOT
in the version, or something like x.+
for the latest available version, including snapshot versions. You don't need to specially enable snapshot version usage with Gradle.
Upvotes: 1