Skip to content
Snippets Groups Projects
Select Git revision
  • develop default protected
  • master protected
  • kristin_optim_test
  • 3.9.0
  • 3.8.0
  • 3.7.0
  • 3.6.0
  • 3.5.0
  • 3.4.1
  • 3.4.0
  • 3.3.3
  • 3.3.2
  • 3.3.0
  • 3.2.14
  • 3.2.13
  • 3.2.12
16 results

build.gradle

  • Code owners
    Assign users and groups as approvers for specific file changes. Learn more.
    build.gradle 2.49 KiB
    apply plugin: 'application'
    apply plugin: 'java'
    apply plugin: 'eclipse'
    apply plugin: 'maven-publish'
    apply plugin: 'signing'
    
    allprojects {
      project.group = 'de.hhu.stups'
      project.version = '3.3.1'
      project.ext.isSnapshot = project.version.endsWith("-SNAPSHOT")
    
      ext."signing.secretKeyRingFile" = rootProject.file("secring.gpg").absolutePath
    }
    
    wrapper {
      gradleVersion = "7.2"
    }
    
    repositories {
      mavenCentral()
    }
    
    java {
      sourceCompatibility = JavaVersion.VERSION_1_7
      targetCompatibility = JavaVersion.VERSION_1_7
    
      withSourcesJar()
      withJavadocJar()
    }
    
    application {
      mainClass = "org.sablecc.sablecc.SableCC"
    }
    
    processResources {
      inputs.property("project.version", project.version)
      filesMatching("org/sablecc/sablecc/build.properties") {
        expand(version: project.version)
      }
    }
    
    jar {
      manifest {
        attributes([
          'Main-Class': application.mainClass.get(),
          'Automatic-Module-Name': 'org.sablecc.sablecc',
        ])
      }
    }
    
    publishing {
      publications {
        mavenJava(MavenPublication) {
          from components.java
    
          pom {
            name = 'SableCC - Stups fork'
            description = 'This version of SableCC enriches the abstract syntax tree with information about tokens.'
            url = 'https://gitlab.cs.uni-duesseldorf.de/general/stups/sablecc-stups'
    
            licenses {
              license {
                name = 'GNU Lesser General Public License, Version 2.1'
                url = 'http://www.gnu.org/licenses/lgpl-2.1.html'
              }
            }
    
            scm {
              connection = 'scm:git:https://gitlab.cs.uni-duesseldorf.de/general/stups/sablecc-stups.git'
              developerConnection = 'scm:git:git@gitlab.cs.uni-duesseldorf.de:general/stups/sablecc-stups.git'
              url = 'https://gitlab.cs.uni-duesseldorf.de/general/stups/sablecc-stups'
            }
    
            developers {
              developer {
                id = 'bendisposto'
                name = 'Jens Bendisposto'
                email = 'jens@bendisposto.de'
              }
            }
          }
        }
      }
    
      repositories {
        maven {
          final releasesRepoUrl = "https://oss.sonatype.org/service/local/staging/deploy/maven2"
          final snapshotsRepoUrl = "https://oss.sonatype.org/content/repositories/snapshots"
          url isSnapshot ? snapshotsRepoUrl : releasesRepoUrl
          if (project.hasProperty('ossrhUsername') && project.hasProperty('ossrhPassword')) {
            credentials {
              username project.ossrhUsername
              password project.ossrhPassword
            }
          }
        }
      }
    }
    
    signing {
      sign publishing.publications.mavenJava
    }