Skip to content

Instantly share code, notes, and snippets.

@jasonnerothin
Created December 17, 2020 05:00
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jasonnerothin/b053ddfe617ad4c5165b9f78af3bd2da to your computer and use it in GitHub Desktop.
Save jasonnerothin/b053ddfe617ad4c5165b9f78af3bd2da to your computer and use it in GitHub Desktop.
OS & Architecture
class arch{
public static void main(String[] args) throws Exception{
String os = System.getProperty("os.name").toLowerCase().replace(" ", "_");
String arch = System.getProperty("os.arch").toLowerCase().replace(" ", "_");
System.out.println("OS: " + os + " arch: " + arch );
}}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment