-
Notifications
You must be signed in to change notification settings - Fork 1
/
build.gradle
78 lines (71 loc) · 2.18 KB
/
build.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
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
plugins {
id 'java'
id 'idea'
id 'net.minecrell.plugin-yml.bukkit' version '0.3.0'
}
bukkit {
name = 'Stonks'
version = '2.1-' + getGitHash() + ' (' + getGitBranch() + ')'
apiVersion = '1.14'
main = 'dev.tycho.stonks.Stonks'
authors = ['TychoVI', 'Tsarcasm', 'JRoy']
softDepend = ['ChestShop', 'Essentials']
depend = ['PluginLibrary', 'Vault']
commands {
company {
description = 'Main Stonks Command'
aliases = ['stonks', 'comp']
usage = '/company'
}
cc {
description = '/cc'
usage = '/cc'
}
ccr {
description = '/ccr'
usage = '/ccr'
}
}
}
repositories {
mavenCentral()
jcenter()
maven { url 'https://jitpack.io' }
maven { url 'https://repo.aikar.co/content/groups/aikar/' }
maven { url 'https://ci.ender.zone/plugin/repository/everything/' }
maven { url 'https://hub.spigotmc.org/nexus/content/repositories/snapshots' }
maven { url 'https://oss.sonatype.org/content/repositories/snapshots' }
}
dependencies {
compileOnly "org.spigotmc:spigot-api:1.15.2-R0.1-SNAPSHOT"
compileOnly("com.github.MilkBowl:VaultAPI:1.7") {
exclude module: 'bukkit'
}
compileOnly files('libs/ChestShop.jar')
compileOnly("net.ess3:EssentialsX:2.17.0") {
exclude module: 'bukkit'
}
compileOnly "com.github.schlatt-co:PluginLibrary:87bf88cde4"
compileOnly group: 'org.jetbrains', name: 'annotations', version: '18.0.0'
compileOnly 'com.github.WesJD.AnvilGUI:anvilgui:ef71db62ec'
}
compileJava.options.encoding = 'UTF-8'
tasks.withType(JavaCompile) {
options.encoding = 'UTF-8'
}
String getGitHash() {
def output = new ByteArrayOutputStream()
exec {
standardOutput = output // Only the std, not errors as it's not to worry about as long as it's a repo
commandLine 'git', 'rev-parse', '--short', 'HEAD'
}
return output.toString().trim()
}
String getGitBranch() {
def output = new ByteArrayOutputStream()
exec {
standardOutput = output
commandLine 'git', 'rev-parse', '--abbrev-ref', 'HEAD'
}
return output.toString().trim()
}