smaller fixes during final v5 tests
This commit is contained in:
parent
cb66840407
commit
5fa0dbb059
@ -330,7 +330,7 @@ I also created a nice little command line tool called [mmon][mmon-github-url] (m
|
|||||||
| | hardware | X | X | X | X | | hardware specific UUID |
|
| | hardware | X | X | X | X | | hardware specific UUID |
|
||||||
| | macs | X | X | X | X | | MAC addresses |
|
| | macs | X | X | X | X | | MAC addresses |
|
||||||
| si.versions(apps, cb) | {...} | X | X | X | X | X | version information (kernel, ssl, node, ...)<br />apps param is optional for detecting<br />only specific apps/libs<br />(string, comma separated) |
|
| si.versions(apps, cb) | {...} | X | X | X | X | X | version information (kernel, ssl, node, ...)<br />apps param is optional for detecting<br />only specific apps/libs<br />(string, comma separated) |
|
||||||
| si.shell(cb) | : string | X | X | X | | | standard shell |
|
| si.shell(cb) | : string | X | X | X | X | | standard shell |
|
||||||
| si.users(cb) | [{...}] | X | X | X | X | X | array of users online |
|
| si.users(cb) | [{...}] | X | X | X | X | X | array of users online |
|
||||||
| | [0].user | X | X | X | X | X | user name |
|
| | [0].user | X | X | X | X | X | user name |
|
||||||
| | [0].tty | X | X | X | X | X | terminal |
|
| | [0].tty | X | X | X | X | X | terminal |
|
||||||
|
|||||||
@ -246,7 +246,7 @@ si.osInfo().then(data => console.log(data));</code></pre class="example">
|
|||||||
<td>X</td>
|
<td>X</td>
|
||||||
<td>X</td>
|
<td>X</td>
|
||||||
<td>X</td>
|
<td>X</td>
|
||||||
<td></td>
|
<td>X</td>
|
||||||
<td></td>
|
<td></td>
|
||||||
<td>standard shell</td>
|
<td>standard shell</td>
|
||||||
</tr>
|
</tr>
|
||||||
|
|||||||
@ -113,7 +113,6 @@ function parseWindowsAudio(lines) {
|
|||||||
result.default = null;
|
result.default = null;
|
||||||
result.in = null;
|
result.in = null;
|
||||||
result.out = null;
|
result.out = null;
|
||||||
result.interfaceType = null;
|
|
||||||
result.status = status;
|
result.status = status;
|
||||||
|
|
||||||
return result;
|
return result;
|
||||||
|
|||||||
@ -108,9 +108,9 @@ function bluetoothDevices(callback) {
|
|||||||
}
|
}
|
||||||
// determine "connected" with hcitool con
|
// determine "connected" with hcitool con
|
||||||
try {
|
try {
|
||||||
const hdicon = execSync('hditool con').toString().toLowerCase();
|
const hdicon = execSync('hcitool con').toString().toLowerCase();
|
||||||
for (let i = 0; i < result.length; i++) {
|
for (let i = 0; i < result.length; i++) {
|
||||||
if (result[i].macAddr1 && result[i].macAddr1.length > 10 && hdicon.indexOf(result[i].macAddr1) >= 0) {
|
if (result[i].macDevice && result[i].macDevice.length > 10 && hdicon.indexOf(result[i].macDevice.toLowerCase()) >= 0) {
|
||||||
result[i].connected = true;
|
result[i].connected = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1028,7 +1028,7 @@ function diskLayout(callback) {
|
|||||||
const status = util.getValue(lines, 'Status', '=').trim().toLowerCase();
|
const status = util.getValue(lines, 'Status', '=').trim().toLowerCase();
|
||||||
if (size) {
|
if (size) {
|
||||||
result.push({
|
result.push({
|
||||||
device: '',
|
device: util.getValue(lines, 'PNPDeviceId', '='),
|
||||||
type: device.indexOf('SSD') > -1 ? 'SSD' : 'HD', // just a starting point ... better: MSFT_PhysicalDisk - Media Type ... see below
|
type: device.indexOf('SSD') > -1 ? 'SSD' : 'HD', // just a starting point ... better: MSFT_PhysicalDisk - Media Type ... see below
|
||||||
name: util.getValue(lines, 'Caption', '='),
|
name: util.getValue(lines, 'Caption', '='),
|
||||||
vendor: util.getValue(lines, 'Manufacturer', '='),
|
vendor: util.getValue(lines, 'Manufacturer', '='),
|
||||||
|
|||||||
@ -353,7 +353,7 @@ function isUefiLinux() {
|
|||||||
if (!err) {
|
if (!err) {
|
||||||
resolve(true);
|
resolve(true);
|
||||||
} else {
|
} else {
|
||||||
exec('dmesg | grep -E "EFI v|UEFI"', function (error, stdout) {
|
exec('dmesg | grep -E "EFI v"', function (error, stdout) {
|
||||||
if (!error) {
|
if (!error) {
|
||||||
const lines = stdout.toString().split('\n');
|
const lines = stdout.toString().split('\n');
|
||||||
resolve(lines.length > 0);
|
resolve(lines.length > 0);
|
||||||
@ -941,7 +941,7 @@ function shell(callback) {
|
|||||||
return new Promise((resolve) => {
|
return new Promise((resolve) => {
|
||||||
process.nextTick(() => {
|
process.nextTick(() => {
|
||||||
if (_windows) {
|
if (_windows) {
|
||||||
resolve(null);
|
resolve('cmd');
|
||||||
}
|
}
|
||||||
|
|
||||||
let result = '';
|
let result = '';
|
||||||
|
|||||||
@ -1002,7 +1002,7 @@ function processLoad(proc, callback) {
|
|||||||
|
|
||||||
let listPos = -1;
|
let listPos = -1;
|
||||||
for (let j = 0; j < result.length; j++) {
|
for (let j = 0; j < result.length; j++) {
|
||||||
if (result[j].pid === resultProcess.pid || result[j].pids.indexOf(resultProcess.pid) >= 0) { listPos === j; }
|
if (result[j].pid === resultProcess.pid || result[j].pids.indexOf(resultProcess.pid) >= 0) { listPos = j; }
|
||||||
}
|
}
|
||||||
if (listPos >= 0) {
|
if (listPos >= 0) {
|
||||||
result[listPos].cpu += resultProcess.cpuu + resultProcess.cpus;
|
result[listPos].cpu += resultProcess.cpuu + resultProcess.cpus;
|
||||||
|
|||||||
@ -616,7 +616,7 @@ function getFilesInPath(source) {
|
|||||||
let files = dirs
|
let files = dirs
|
||||||
.map(function (dir) { return getFilesRecursively(dir); })
|
.map(function (dir) { return getFilesRecursively(dir); })
|
||||||
.reduce(function (a, b) { return a.concat(b); }, []);
|
.reduce(function (a, b) { return a.concat(b); }, []);
|
||||||
return files.concat(getFiles(path));
|
return files.concat(getFiles(source));
|
||||||
}
|
}
|
||||||
|
|
||||||
if (fs.existsSync(source)) {
|
if (fs.existsSync(source)) {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user