Skip to content
Get current Linux distro
JavaScript
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.editorconfig
.gitattributes
.gitignore
.travis.yml
cli.js
index.js
license
package.json
readme.md
test.js

readme.md

linux-distro Build Status

Get the current Linux distro

Install

$ npm install --save linux-distro

Usage

const linuxDistro = require('linux-distro');

linuxDistro().then(data => {
	console.log(data);
	/*
	{
		os: 'Ubuntu',
		name: 'Ubuntu 14.04 LTS',
		release: '14.04',
		code: 'trusty'
	}
	*/
});

CLI

$ npm install --global linux-distro
$ linux-distro --help

  Example
    $ linux-distro
    Ubuntu 14.04 LTS (trusty)

License

MIT © Kevin Mårtensson

You can’t perform that action at this time.