DefinitelyTyped/types/getos/getos-tests.ts
2017-08-08 13:49:06 -07:00

19 lines
303 B
TypeScript

import getos = require('getos');
getos((e, os) => {
if (e) {
return;
}
const thisOs: getos.Os = os;
if (os.os === 'linux') {
let str: string;
let strn: string | undefined;
str = os.dist;
str = os.release;
strn = os.codename;
}
});