systeminformation 5.17.11 → 5.17.13
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/index.d.ts +5 -4
- package/lib/osinfo.js +19 -15
- 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 6 mio downloads per month, >
|
|
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, > 150 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/index.d.ts
CHANGED
|
@@ -492,6 +492,7 @@ export namespace Systeminformation {
|
|
|
492
492
|
interface NetworkInterfacesData {
|
|
493
493
|
iface: string;
|
|
494
494
|
ifaceName: string;
|
|
495
|
+
default: boolean;
|
|
495
496
|
ip4: string;
|
|
496
497
|
ip4subnet: string;
|
|
497
498
|
ip6: string;
|
|
@@ -924,14 +925,14 @@ export namespace Systeminformation {
|
|
|
924
925
|
v8: string;
|
|
925
926
|
cpuCurrentSpeed: CpuCurrentSpeedData;
|
|
926
927
|
users: UserData[];
|
|
927
|
-
processes: ProcessesData;
|
|
928
|
+
processes: ProcessesData[];
|
|
928
929
|
currentLoad: CurrentLoadData;
|
|
929
930
|
cpuTemperature: CpuTemperatureData;
|
|
930
|
-
networkStats: NetworkStatsData;
|
|
931
|
-
networkConnections: NetworkConnectionsData;
|
|
931
|
+
networkStats: NetworkStatsData[];
|
|
932
|
+
networkConnections: NetworkConnectionsData[];
|
|
932
933
|
mem: MemData;
|
|
933
934
|
battery: BatteryData;
|
|
934
|
-
services: ServicesData;
|
|
935
|
+
services: ServicesData[];
|
|
935
936
|
fsSize: FsSizeData;
|
|
936
937
|
fsStats: FsStatsData;
|
|
937
938
|
disksIO: DisksIoData;
|
package/lib/osinfo.js
CHANGED
|
@@ -1047,25 +1047,29 @@ function shell(callback) {
|
|
|
1047
1047
|
exports.shell = shell;
|
|
1048
1048
|
|
|
1049
1049
|
function getUniqueMacAdresses() {
|
|
1050
|
-
const ifaces = os.networkInterfaces();
|
|
1051
1050
|
let macs = [];
|
|
1052
|
-
|
|
1053
|
-
|
|
1054
|
-
|
|
1055
|
-
|
|
1056
|
-
|
|
1057
|
-
if (
|
|
1058
|
-
|
|
1051
|
+
try {
|
|
1052
|
+
const ifaces = os.networkInterfaces();
|
|
1053
|
+
for (let dev in ifaces) {
|
|
1054
|
+
if ({}.hasOwnProperty.call(ifaces, dev)) {
|
|
1055
|
+
ifaces[dev].forEach(function (details) {
|
|
1056
|
+
if (details && details.mac && details.mac !== '00:00:00:00:00:00') {
|
|
1057
|
+
const mac = details.mac.toLowerCase();
|
|
1058
|
+
if (macs.indexOf(mac) === -1) {
|
|
1059
|
+
macs.push(mac);
|
|
1060
|
+
}
|
|
1059
1061
|
}
|
|
1060
|
-
}
|
|
1061
|
-
}
|
|
1062
|
+
});
|
|
1063
|
+
}
|
|
1062
1064
|
}
|
|
1065
|
+
macs = macs.sort(function (a, b) {
|
|
1066
|
+
if (a < b) { return -1; }
|
|
1067
|
+
if (a > b) { return 1; }
|
|
1068
|
+
return 0;
|
|
1069
|
+
});
|
|
1070
|
+
} catch (e) {
|
|
1071
|
+
macs.push('00:00:00:00:00:00');
|
|
1063
1072
|
}
|
|
1064
|
-
macs = macs.sort(function (a, b) {
|
|
1065
|
-
if (a < b) { return -1; }
|
|
1066
|
-
if (a > b) { return 1; }
|
|
1067
|
-
return 0;
|
|
1068
|
-
});
|
|
1069
1073
|
return macs;
|
|
1070
1074
|
}
|
|
1071
1075
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "systeminformation",
|
|
3
|
-
"version": "5.17.
|
|
3
|
+
"version": "5.17.13",
|
|
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)",
|