Get the OS/Distribution name of the environment you are working on
linux. If you want the distrubtion name, you're out of luck.
This. Simply call:
var getos =
os object conforms to:
os: OS NAMEdist:DIST NAMEcodename:CODENAMErelease:VERSION
os: "linux"dist: "Ubuntu Linux"codename: "precise"release: "12.04"
os.json in this repo. Any distribution that shares a common resource file with another distrubtion is currently untested. These are the arrays of distrubitons with more than 1 member. If you are using one of these distrubtions, please submit an issue letting me know if it works. If it fails, please post the content of the file.
If you have a distrubtion not in
os.json, please identify your resource file and submit it's name and content along with your distrbution/version in an issue.
Thanks for helping make this tool great.
Unit tests stub out the behaviour of the OS files and libraries we depend on to ensure the behaviour of the application is sound. You can run these simply by running
Authors and Contributors
getos has been made possible by these fantastic contributors:
|Benjamin E. Coe||GitHub/bcoe||Twitter/@benjamincoe|