mirror of
https://github.com/GeyserMC/Geyser.git
synced 2024-08-14 23:57:35 +00:00
merge upstream
This commit is contained in:
parent
40c67ca23c
commit
25d8f8a0e4
3 changed files with 6 additions and 5 deletions
|
|
@ -75,7 +75,7 @@ tasks.processResources {
|
|||
expand(
|
||||
"branch" to info.branch,
|
||||
"buildNumber" to info.buildNumber,
|
||||
"projectVersion" to project.version,
|
||||
"projectVersion" to info.version,
|
||||
"commit" to info.commit,
|
||||
"commitAbbrev" to info.commitAbbrev,
|
||||
"commitMessage" to info.commitMessage,
|
||||
|
|
@ -95,13 +95,13 @@ sourceSets {
|
|||
property("branch", info.branch)
|
||||
property("commit", info.commit)
|
||||
property("repository", info.repository)
|
||||
property("devVersion", info.isDev)
|
||||
property("devVersion", info.isDev.toString())
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
fun Project.buildNumber(): Int =
|
||||
fun buildNumber(): Int =
|
||||
(System.getenv("BUILD_NUMBER"))?.let { Integer.parseInt(it) } ?: -1
|
||||
|
||||
fun isDevBuild(branch: String, repository: String): Boolean {
|
||||
|
|
|
|||
|
|
@ -34,4 +34,6 @@ public class BuildData {
|
|||
public static final String BRANCH = "{{ branch }}";
|
||||
public static final String COMMIT = "{{ commit }}";
|
||||
public static final String REPOSITORY = "{{ repository }}";
|
||||
|
||||
public static final String DEV = "{{ devVersion }}";
|
||||
}
|
||||
|
|
|
|||
|
|
@ -123,8 +123,7 @@ public class GeyserImpl implements GeyserApi {
|
|||
public static final String COMMIT = BuildData.COMMIT;
|
||||
public static final String REPOSITORY = BuildData.REPOSITORY;
|
||||
|
||||
@SuppressWarnings("ConstantValue")
|
||||
public static final boolean IS_DEV = Boolean.parseBoolean("${dev}");
|
||||
public static final boolean IS_DEV = Boolean.parseBoolean(BuildData.DEV);
|
||||
|
||||
/**
|
||||
* Oauth client ID for Microsoft authentication
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue