buildscript {
    repositories {
        mavenCentral()
    }
    dependencies {
        classpath 'org.springframework.boot:spring-boot-gradle-plugin:3.3.2'
    }
}

plugins {
    id 'java-library'
}

apply plugin: 'org.springframework.boot'

group = 'com.epages'
description = 'Spring Boot Starter for adding a WireMock server to your integration test'

dependencies {
    api 'org.wiremock:wiremock-standalone:3.9.1'

    implementation 'org.springframework.boot:spring-boot-starter-test'
    implementation 'org.springframework.boot:spring-boot-starter'

    compileOnly 'org.springframework.boot:spring-boot-configuration-processor'

    testImplementation 'junit:junit'
    testImplementation 'org.springframework:spring-web'
}

bootJar.enabled = false
jar.enabled = true

publishing {
    publications {
        mavenJava(MavenPublication) {
            from components.java
            artifactId 'wiremock-spring-boot-starter'
            groupId = project.group
            
            pom {
                  name = 'WireMock Spring Boot Starter'
                  description = "A Spring Boot Starter which adds a WireMockServer to your client's ApplicationContext for integration testing."
                  url = 'https://github.com/ePages-de/restdocs-wiremock'
                  licenses {
                      license {
                          name = 'The Apache License, Version 2.0'
                          url = 'http://www.apache.org/licenses/LICENSE-2.0.txt'
                      }
                  }
                  developers {
                      developer {
                          id = 'ePages'
                          name = 'ePages Devs'
                          email = 'info@epages.com'
                      }
                  }
                  scm {
                      connection = 'scm:git:git://github.com:ePages-de/restdocs-wiremock.git'
                      developerConnection = 'scm:git:ssh://github.com:ePages-de/restdocs-wiremock.git'
                      url = 'https://github.com/ePages-de/restdocs-wiremock'
                  }
            }
        }
    }
}

signing {
    sign publishing.publications.mavenJava
    sign configurations.archives
}
