systeminformation 5.33.14 → 5.33.15

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.
Files changed (2) hide show
  1. package/lib/util.js +39 -7
  2. package/package.json +1 -1
package/lib/util.js CHANGED
@@ -95,7 +95,7 @@ const stringStartWith = new String().startsWith;
95
95
  const mathMin = Math.min;
96
96
 
97
97
  function isFunction(functionToCheck) {
98
- let getType = {};
98
+ const getType = {};
99
99
  return functionToCheck && getType.toString.call(functionToCheck) === '[object Function]';
100
100
  }
101
101
 
@@ -103,7 +103,7 @@ function unique(obj) {
103
103
  const uniques = [];
104
104
  const stringify = {};
105
105
  for (let i = 0; i < obj.length; i++) {
106
- let keys = Object.keys(obj[i]);
106
+ const keys = Object.keys(obj[i]);
107
107
  keys.sort((a, b) => {
108
108
  return a - b;
109
109
  });
@@ -202,7 +202,7 @@ function parseTime(t, pmDesignator) {
202
202
  parts[1] += parts[2];
203
203
  }
204
204
  const p1 = (parts[1] || '').toLowerCase();
205
- let isPM =
205
+ const isPM =
206
206
  p1.indexOf('pm') > -1 ||
207
207
  p1.indexOf('p.m.') > -1 ||
208
208
  p1.indexOf('p. m.') > -1 ||
@@ -670,7 +670,7 @@ function execWin(cmd, opts, callback) {
670
670
  callback = opts;
671
671
  opts = execOptsWin;
672
672
  }
673
- let newCmd = 'chcp 65001 > nul && cmd /C ' + cmd + ' && chcp ' + codepage + ' > nul';
673
+ const newCmd = 'chcp 65001 > nul && cmd /C ' + cmd + ' && chcp ' + codepage + ' > nul';
674
674
  exec(newCmd, opts, (error, stdout) => {
675
675
  callback(error, stdout);
676
676
  });
@@ -1118,7 +1118,7 @@ function decodePiCpuinfo(lines) {
1118
1118
  model,
1119
1119
  serial,
1120
1120
  revisionCode,
1121
- memory: 256 * Math.pow(2, memSizeCode),
1121
+ memory: 256 * 2 ** memSizeCode,
1122
1122
  manufacturer,
1123
1123
  processor,
1124
1124
  type: {}.hasOwnProperty.call(typeList, typeCode) ? typeList[typeCode] : '',
@@ -1237,7 +1237,7 @@ function plistParser(xmlStr) {
1237
1237
  const startStr = '<plist version';
1238
1238
 
1239
1239
  let pos = xmlStr.indexOf(startStr);
1240
- let len = xmlStr.length;
1240
+ const len = xmlStr.length;
1241
1241
  while (xmlStr[pos] !== '>' && pos < len) {
1242
1242
  pos++;
1243
1243
  }
@@ -1246,7 +1246,7 @@ function plistParser(xmlStr) {
1246
1246
  let inTagStart = false;
1247
1247
  let inTagContent = false;
1248
1248
  let inTagEnd = false;
1249
- let metaData = [{ tagStart: '', tagEnd: '', tagContent: '', key: '', data: null }];
1249
+ const metaData = [{ tagStart: '', tagEnd: '', tagContent: '', key: '', data: null }];
1250
1250
  let c = '';
1251
1251
  let cn = xmlStr[pos];
1252
1252
 
@@ -1447,6 +1447,38 @@ function semverCompare(v1, v2) {
1447
1447
 
1448
1448
  function getAppleModel(key) {
1449
1449
  const appleModelIds = [
1450
+ {
1451
+ key: 'Mac18,5',
1452
+ name: 'Mac mini',
1453
+ size: '',
1454
+ processor: 'M6',
1455
+ year: '2026',
1456
+ additional: ''
1457
+ },
1458
+ {
1459
+ key: 'Mac17,16',
1460
+ name: 'Mac mini',
1461
+ size: '',
1462
+ processor: 'M5 Pro',
1463
+ year: '2026',
1464
+ additional: ''
1465
+ },
1466
+ {
1467
+ key: 'Mac17,15',
1468
+ name: 'Mac Studio',
1469
+ size: '',
1470
+ processor: 'M5 Ultra',
1471
+ year: '2026',
1472
+ additional: ''
1473
+ },
1474
+ {
1475
+ key: 'Mac17,14',
1476
+ name: 'Mac Studio',
1477
+ size: '',
1478
+ processor: 'M5 Max',
1479
+ year: '2026',
1480
+ additional: ''
1481
+ },
1450
1482
  {
1451
1483
  key: 'Mac17,9',
1452
1484
  name: 'MacBook Pro',
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "systeminformation",
3
- "version": "5.33.14",
3
+ "version": "5.33.15",
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)",