Skip to content

Commit

Permalink
Fix travis build error
Browse files Browse the repository at this point in the history
  • Loading branch information
patrick-choe committed Oct 27, 2020
1 parent 5e2488b commit 27384a6
Showing 1 changed file with 14 additions and 11 deletions.
25 changes: 14 additions & 11 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -96,18 +96,20 @@ tasks {
create<Copy>("distJar") {
from(shadowJar)

val fileName = "${project.name.capitalize()}.jar"
val pluginsDir = "W:\\Servers\\1.16.3\\plugins"
val updateDir = "$pluginsDir\\update"
if (System.getProperty("os.name").startsWith("Windows")) {
val fileName = "${project.name.capitalize()}.jar"
val pluginsDir = "W:\\Servers\\1.16.3\\plugins"
val updateDir = "$pluginsDir\\update"

rename {
fileName
}
rename {
fileName
}

if (file("$pluginsDir\\$fileName").exists()) {
into(updateDir)
} else {
into(pluginsDir)
if (file("$pluginsDir\\$fileName").exists()) {
into(updateDir)
} else {
into(pluginsDir)
}
}
}
}
Expand Down Expand Up @@ -177,4 +179,5 @@ try {
sign(tasks["sourcesJar"], tasks["dokkaJar"], tasks["shadowJar"])
sign(publishing.publications["twipe"])
}
} catch (ignored: MissingPropertyException) {}
} catch (ignored: MissingPropertyException) {
}

0 comments on commit 27384a6

Please sign in to comment.