diff --git a/CHANGELOG.md b/CHANGELOG.md index 0ec5560..af4164b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -30,6 +30,7 @@ For major (breaking) changes - version 3 and 2 see end of page. | Version | Date | Comment | | -------------- | -------------- | -------- | +| 4.22.4 | 2020-03-01 | `versions()` added dotnet, typings fix | | 4.22.3 | 2020-02-20 | `memLayout()` code cleanup | | 4.22.2 | 2020-02-19 | `memLayout()` raspberry PI mem voltage fix | | 4.22.1 | 2020-02-17 | `memLayout()` raspberry PI support | diff --git a/README.md b/README.md index 5f6d603..056f262 100644 --- a/README.md +++ b/README.md @@ -30,7 +30,7 @@ [![Sponsoring][sponsor-badge]][sponsor-url] [![MIT license][license-img]][license-url] -This is amazing. Started as a small project just for myself, it now has > 9,000 lines of code, > 250 versions published, up to 1 mio downloads per month, > 5 mio downloads overall. Thank you to all who contributed to this project! +This is amazing. Started as a small project just for myself, it now has > 9,000 lines of code, > 300 versions published, up to 1 mio downloads per month, > 6 mio downloads overall. Thank you to all who contributed to this project! ## New Version 4.0 diff --git a/docs/history.html b/docs/history.html index 8e360dc..a64a456 100644 --- a/docs/history.html +++ b/docs/history.html @@ -83,6 +83,11 @@ + + 4.22.4 + 2020-03-01 + versions() added dotnet, fix typings + 4.22.3 2020-02-20 diff --git a/docs/index.html b/docs/index.html index 420e5b2..681ca3b 100644 --- a/docs/index.html +++ b/docs/index.html @@ -168,7 +168,7 @@
systeminformation
-
Current Version: 4.22.3
+
Current Version: 4.22.4
@@ -207,7 +207,7 @@
Downloads last month
-
248
+
249
Dependends
diff --git a/lib/index.d.ts b/lib/index.d.ts index 15fe936..1b79512 100644 --- a/lib/index.d.ts +++ b/lib/index.d.ts @@ -83,9 +83,9 @@ export namespace Systeminformation { } interface CpuCurrentSpeedData { - min: string; - max: string; - avg: string; + min: number; + max: number; + avg: number; cores: number[]; } @@ -243,6 +243,7 @@ export namespace Systeminformation { java: string; gcc: string; virtualbox: string; + dotnet: string; } interface UserData { diff --git a/lib/osinfo.js b/lib/osinfo.js index 45b6625..63e1ae9 100644 --- a/lib/osinfo.js +++ b/lib/osinfo.js @@ -384,11 +384,12 @@ function versions(callback) { pip3: '', java: '', gcc: '', - virtualbox: '' + virtualbox: '', + dotnet: '' }; let functionProcessed = (function () { - let totalFunctions = 25; + let totalFunctions = 26; return function () { if (--totalFunctions === 0) { if (callback) { @@ -694,6 +695,13 @@ function versions(callback) { } functionProcessed(); }); + exec('dotnet --version 2>&1', function (error, stdout) { + if (!error) { + const dotnet = stdout.toString().split('\n')[0] || ''; + result.dotnet = dotnet.trim(); + } + functionProcessed(); + }); } catch (e) { if (callback) { callback(result); } resolve(result);