blob: 0c66254a1e797e3ca0d6a84b6e3904dbe5f791ab [file] [log] [blame]
Brian Silvermanf7f267a2017-02-04 16:16:08 -08001plugins {
2 id 'net.ltgt.errorprone' version '0.0.8'
3 id 'edu.wpi.first.wpilib.versioning.WPILibVersioningPlugin' version '1.6'
4}
5
6// Ensure that the WPILibVersioningPlugin is setup by setting the release type, if releaseType wasn't
7// already specified on the command line
8if (!hasProperty('releaseType')) {
9 WPILibVersion {
10 releaseType = 'dev'
11 }
12}
13
14def enableSimulation = hasProperty('makeSim')
15
16ext.simulationInstallDir = "$rootDir/build/install/simulation"
17
18allprojects {
19 ext.enableSimulation = enableSimulation
20
21 repositories {
22 mavenCentral()
23 }
24
25 ext.ntcoreDep = { lang, classifier, extension = null ->
26 return "edu.wpi.first.wpilib.networktables.$lang:NetworkTables:+:$classifier${extension == null ? '' : '@' + extension}"
27 }
28
29 ext.cscoreDep = { lang, classifier, extension = null ->
30 return "edu.wpi.cscore.$lang:cscore:+:$classifier${extension == null ? '' : '@' + extension}"
31 }
32
33 ext.wpiUtilDep = { classifier ->
34 return "edu.wpi.first.wpilib:wpiutil:+:$classifier@zip"
35 }
36}
37
38subprojects {
39 apply plugin: 'eclipse'
40 apply plugin: 'idea'
41 apply plugin: 'checkstyle'
42
43 checkstyle {
44 toolVersion = "6.18"
45 configFile = new File(rootDir, "styleguide/checkstyle.xml")
46 }
47
48 ext.armBuild = true
49
50 // Disables doclint in java 8.
51 if (JavaVersion.current().isJava8Compatible()) {
52 tasks.withType(Javadoc) {
53 options.addStringOption('Xdoclint:none', '-quiet')
54 }
55 }
56 ext.setupWpilibRepo = { publishing ->
57 publishing.repositories.maven {
58 url = WPILibVersion.mavenLocalUrl
59 }
60 }
61}
62
63apply from: 'cppSettings.gradle'
64
65apply from: 'ni-libraries/ni-libraries.gradle'
66
67task wrapper(type: Wrapper) {
68 gradleVersion = '3.3'
69}