This repository has been archived by the owner on Mar 6, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 5
/
settings.gradle
57 lines (54 loc) · 1.75 KB
/
settings.gradle
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
//import org.gradle.internal.os.OperatingSystem
//
//pluginManagement {
// repositories {
// mavenLocal()
// gradlePluginPortal()
// String frcYear = '2019'
// File frcHome
// if (OperatingSystem.current().isWindows()) {
// String publicFolder = System.getenv('PUBLIC')
// if (publicFolder == null) {
// publicFolder = "C:\\Users\\Public"
// }
// frcHome = new File(publicFolder, "frc${frcYear}")
// } else {
// def userFolder = System.getProperty("user.home")
// frcHome = new File(userFolder, "frc${frcYear}")
// }
// def frcHomeMaven = new File(frcHome, 'maven')
// maven {
// name 'frcHome'
// url frcHomeMaven
// }
// }
//}
//
//include "common", "robot", "display"
import org.gradle.internal.os.OperatingSystem
pluginManagement {
repositories {
mavenLocal()
gradlePluginPortal()
String frcYear = '2020'
File frcHome
if (OperatingSystem.current().isWindows()) {
String publicFolder = System.getenv('PUBLIC')
if (publicFolder == null) {
publicFolder = "C:\\Users\\Public"
}
def homeRoot = new File(publicFolder, "wpilib")
frcHome = new File(homeRoot, frcYear)
} else {
def userFolder = System.getProperty("user.home")
def homeRoot = new File(userFolder, "wpilib")
frcHome = new File(homeRoot, frcYear)
}
def frcHomeMaven = new File(frcHome, 'maven')
maven {
name 'frcHome'
url frcHomeMaven
}
}
}
include "common", "robot"