mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-20 04:38:00 +00:00
make development version reference GIT not SVN
Signed-off-by: Jamin W. Collins <jamin.collins@gmail.com>
This commit is contained in:
@@ -30,19 +30,19 @@ public class BuildInfo {
|
||||
/**
|
||||
* Get the current version of Forge.
|
||||
*
|
||||
* @return a String representing the version specifier, or "SVN" if unknown.
|
||||
* @return a String representing the version specifier, or "GIT" if unknown.
|
||||
*/
|
||||
public static final String getVersionString() {
|
||||
String version = BuildInfo.class.getPackage().getImplementationVersion();
|
||||
if (StringUtils.isEmpty(version)) {
|
||||
return "SVN";
|
||||
return "GIT";
|
||||
}
|
||||
return version;
|
||||
}
|
||||
|
||||
public static boolean isDevelopmentVersion() {
|
||||
String forgeVersion = getVersionString();
|
||||
return StringUtils.containsIgnoreCase(forgeVersion, "svn") ||
|
||||
return StringUtils.containsIgnoreCase(forgeVersion, "git") ||
|
||||
StringUtils.containsIgnoreCase(forgeVersion, "snapshot");
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user