PrismLauncher/libraries/javacheck/JavaCheck.java

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

20 lines
535 B
Java
Raw Permalink Normal View History

2022-06-12 16:29:39 +01:00
public final class JavaCheck {
private static final String[] CHECKED_PROPERTIES = new String[] {"os.arch", "java.version", "java.vendor"};
2022-06-12 16:29:39 +01:00
public static void main(String[] args) {
int returnCode = 0;
for (String key : CHECKED_PROPERTIES) {
2013-12-11 03:54:39 +00:00
String property = System.getProperty(key);
2022-06-12 16:29:39 +01:00
if (property != null) {
2013-12-11 03:54:39 +00:00
System.out.println(key + "=" + property);
2022-06-12 16:29:39 +01:00
} else {
returnCode = 1;
2013-12-11 03:54:39 +00:00
}
}
2022-06-12 16:29:39 +01:00
System.exit(returnCode);
}
}