systeminformation 5.17.9 → 5.17.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/lib/filesystem.js +9 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -29,7 +29,7 @@
|
|
|
29
29
|
[![MIT license][license-img]][license-url]
|
|
30
30
|
|
|
31
31
|
## The Systeminformation Project
|
|
32
|
-
This is amazing. Started as a small project just for myself, it now has > 15,000 lines of code, > 500 versions published, up to
|
|
32
|
+
This is amazing. Started as a small project just for myself, it now has > 15,000 lines of code, > 500 versions published, up to 6 mio downloads per month, > 140 mio downloads overall. #1 NPM ranking for backend packages. Thank you to all who contributed to this project!
|
|
33
33
|
|
|
34
34
|
## New Version 5.0
|
|
35
35
|
|
package/lib/filesystem.js
CHANGED
|
@@ -382,14 +382,18 @@ function parseBlk(lines) {
|
|
|
382
382
|
|
|
383
383
|
function decodeMdabmData(lines) {
|
|
384
384
|
const raid = util.getValue(lines, 'md_level', '=');
|
|
385
|
+
const label = util.getValue(lines, 'md_name', '='); // <- get label info
|
|
386
|
+
const uuid = util.getValue(lines, 'md_uuid', '='); // <- get uuid info
|
|
385
387
|
const members = [];
|
|
386
388
|
lines.forEach(line => {
|
|
387
|
-
if (line.toLowerCase().startsWith('
|
|
389
|
+
if (line.toLowerCase().startsWith('md_device_dev') && line.toLowerCase().indexOf('/dev/') > 0) {
|
|
388
390
|
members.push(line.split('/dev/')[1]);
|
|
389
391
|
}
|
|
390
392
|
});
|
|
391
393
|
return {
|
|
392
394
|
raid,
|
|
395
|
+
label,
|
|
396
|
+
uuid,
|
|
393
397
|
members
|
|
394
398
|
};
|
|
395
399
|
}
|
|
@@ -402,6 +406,10 @@ function raidMatchLinux(data) {
|
|
|
402
406
|
if (element.type.startsWith('raid')) {
|
|
403
407
|
const lines = execSync(`mdadm --export --detail /dev/${element.name}`).toString().split('\n');
|
|
404
408
|
const mdData = decodeMdabmData(lines);
|
|
409
|
+
|
|
410
|
+
element.label = mdData.label; // <- assign label info
|
|
411
|
+
element.uuid = mdData.uuid; // <- assign uuid info
|
|
412
|
+
|
|
405
413
|
if (mdData.members && mdData.members.length && mdData.raid === element.type) {
|
|
406
414
|
result = result.map(blockdevice => {
|
|
407
415
|
if (blockdevice.fsType === 'linux_raid_member' && mdData.members.indexOf(blockdevice.name) >= 0) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "systeminformation",
|
|
3
|
-
"version": "5.17.
|
|
3
|
+
"version": "5.17.11",
|
|
4
4
|
"description": "Advanced, lightweight system and OS information library",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "Sebastian Hildebrandt <hildebrandt@plus-innovations.com> (https://plus-innovations.com)",
|