5

I am going to implement shapefile uploading from a webform, and ingestion into PostGIS.

One problem I am having is that my project is using Gradle for dependency management.

I am unfamiliar with Gradle and have no idea how to find the right string to get the jars into my project.

3

GeoTools doesn't seem to exist in maven Central (http://mvnrepository.com/) so you would have to add a repository configuration to your build:

repositories {
   maven {
     url "http://download.osgeo.org/webdav/geotools/"
   }
 }

The syntax for the dependencies is something like:

compile group: 'org.geotools', name: 'gt-shapefile', version: '11-SNAPSHOT'
0
1

Update for 2021:

repositories {
    maven {
        url "https://repo.osgeo.org/repository/release/"
    }
}

dependencies {
    implementation group: 'org.geotools', name: 'gt-shapefile', version: '25.0'
}

Maven info here: https://mvnrepository.com/artifact/org.geotools/gt-shapefile?repo=osgeo-release

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.