refactor(build): expand to all yml (1.1.0-RC1)
This commit is contained in:
parent
ce8f21c268
commit
b394c7ef0c
3 changed files with 4 additions and 9 deletions
|
@ -71,10 +71,7 @@ tasks {
|
||||||
processResources {
|
processResources {
|
||||||
from("src/main/resources")
|
from("src/main/resources")
|
||||||
duplicatesStrategy = DuplicatesStrategy.EXCLUDE
|
duplicatesStrategy = DuplicatesStrategy.EXCLUDE
|
||||||
filesMatching("config.yml") {
|
filesMatching("*.yml") {
|
||||||
expand("version" to version)
|
|
||||||
}
|
|
||||||
filesMatching("plugin.yml") {
|
|
||||||
expand("version" to version)
|
expand("version" to version)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -37,10 +37,8 @@ public class CustomLocale {
|
||||||
final String localeFileName = locale.getCode() + ".yml";
|
final String localeFileName = locale.getCode() + ".yml";
|
||||||
try {
|
try {
|
||||||
final InputStream resource = NickoBukkit.getInstance().getResource(localeFileName);
|
final InputStream resource = NickoBukkit.getInstance().getResource(localeFileName);
|
||||||
if (resource != null) {
|
|
||||||
Files.copy(resource, file.toPath());
|
Files.copy(resource, file.toPath());
|
||||||
resource.close();
|
resource.close();
|
||||||
}
|
|
||||||
} catch (IOException e) {
|
} catch (IOException e) {
|
||||||
logger.severe("Unable to dump Locale: " + locale.getCode() + "!");
|
logger.severe("Unable to dump Locale: " + locale.getCode() + "!");
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
# Nicko ${version} - Config:
|
# Nicko ${version} - Config:
|
||||||
|
|
||||||
# Specifies the configuration version. (Don't change!)
|
# Specifies the configuration version, don't change.
|
||||||
version: "1.0.8"
|
version: "1.0.8"
|
||||||
|
|
||||||
############
|
############
|
||||||
|
|
Loading…
Reference in a new issue