Skip to content

Commit

Permalink
McDeob - add system info printout
Browse files Browse the repository at this point in the history
  • Loading branch information
ShaneBeee committed Oct 2, 2024
1 parent 73ef1fe commit 9b330ec
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/main/java/com/shanebeestudios/mcdeob/McDeob.java
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
public class McDeob {

public static void main(String[] args) {
//Version.initVersions();
Util.printSystemInfo();
if (args.length == 0) {
try {
if (Util.isRunningMacOS()) {
Expand Down
14 changes: 14 additions & 0 deletions src/main/java/com/shanebeestudios/mcdeob/util/Util.java
Original file line number Diff line number Diff line change
Expand Up @@ -127,4 +127,18 @@ public static Jar getInternalJars(Processor processor) {
}
}

public static void printSystemInfo() {
Thread.currentThread().setName("McDeob");
long maxMemory = Runtime.getRuntime().maxMemory();
Logger.info("Memory: %sMB", maxMemory / 1024 / 1024);
String javaVersion = System.getProperty("java.vm.version");
String javaName = System.getProperty("java.vm.name");
String javaVendor = System.getProperty("java.vm.vendor");
Logger.info("Java: %s [%s - %s]", javaVersion, javaVendor, javaName);
String osArch = System.getProperty("os.arch");
String osName = System.getProperty("os.name");
String osVersion = System.getProperty("os.version");
Logger.info("OS: %s [%s - v.%s]", osName,osArch, osVersion);
}

}

0 comments on commit 9b330ec

Please sign in to comment.