buildscript { repositories { jcenter() } dependencies { classpath 'com.github.jengelman.gradle.plugins:shadow:5.2.0' } } plugins { id 'java' id "com.github.spotbugs" version "4.2.4" apply false } allprojects { apply plugin: "com.github.spotbugs" group 'com.velocitypowered' version '2.0.0-SNAPSHOT' ext { // dependency versions adventureVersion = '4.5.0' junitVersion = '5.7.0' slf4jVersion = '1.7.30' log4jVersion = '2.13.3' nettyVersion = '4.1.59.Final' guavaVersion = '30.0-jre' checkerFrameworkVersion = '3.6.1' configurateVersion = '4.0.0-SNAPSHOT' getCurrentShortRevision = { new ByteArrayOutputStream().withStream { os -> exec { executable = "git" args = ["rev-parse", "HEAD"] standardOutput = os } return os.toString().trim().substring(0, 8) } } } java { sourceCompatibility = JavaVersion.VERSION_11 targetCompatibility = JavaVersion.VERSION_11 } repositories { mavenLocal() mavenCentral() // for kyoripowered dependencies maven { url 'https://oss.sonatype.org/content/groups/public/' } // Velocity repo maven { url "https://nexus.velocitypowered.com/repository/maven-public/" } } test { reports { junitXml.enabled = true } } tasks.withType(com.github.spotbugs.snom.SpotBugsTask) { reports { html { enabled = true destination = file("$buildDir/reports/spotbugs/main/spotbugs.html") stylesheet = 'fancy-hist.xsl' } } } }