Skip to content

Commit

Permalink
bluetooth() improved parsing, macOS Sonoma detection
Browse files Browse the repository at this point in the history
  • Loading branch information
sebhildebrandt committed Aug 4, 2023
1 parent 7c0c245 commit 83c01d2
Show file tree
Hide file tree
Showing 6 changed files with 12 additions and 4 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,7 @@ For major (breaking) changes - **version 4, 3 and 2** - see end of page.

| Version | Date | Comment |
| ------- | ---------- | --------------------------------------------------------------------------------------------------- |
| 5.18.11 | 2023-08-04 | `bluetooth()` improved parsing, macOS Sonoma detection |
| 5.18.10 | 2023-07-28 | `cpu()` fixed cache sizes, extended sockets (windows) |
| 5.18.9 | 2023-07-26 | `fsSize()` fixed missing rw property (windows) |
| 5.18.8 | 2023-07-25 | `cpu()` added AMD ZEN 4 base frequencies |
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
[![MIT license][license-img]][license-url]

## The Systeminformation Project
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!
This is amazing. Started as a small project just for myself, it now has > 15,000 lines of code, > 600 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!

## New Version 5.0

Expand Down
5 changes: 5 additions & 0 deletions docs/history.html
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,11 @@ <h3>Full version history</h3>
</tr>
</thead>
<tbody>
<tr>
<th scope="row">5.18.11</th>
<td>2023-08-04</td>
<td><span class="code">bluetooth()</span> improved parsing</td>
</tr>
<tr>
<th scope="row">5.18.10</th>
<td>2023-07-28</td>
Expand Down
4 changes: 2 additions & 2 deletions docs/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,7 @@
<img class="logo" src="assets/logo.png" alt="logo">
<div class="title">systeminformation</div>
<div class="subtitle"><span id="typed"></span>&nbsp;</div>
<div class="version">New Version: <span id="version">5.18.10</span></div>
<div class="version">New Version: <span id="version">5.18.11</span></div>
<button class="btn btn-light" onclick="location.href='https://github.com/sebhildebrandt/systeminformation'">View on Github <i class=" fab fa-github"></i></button>
</div>
<div class="down">
Expand Down Expand Up @@ -212,7 +212,7 @@
<div class="title">Downloads last month</div>
</div>
<div class="col-xl-4 col-lg-4 col-md-4 col-12">
<div class="numbers">634</div>
<div class="numbers">636</div>
<div class="title">Dependents</div>
</div>
</div>
Expand Down
2 changes: 2 additions & 0 deletions lib/bluetooth.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ function parseBluetoothType(str) {

if (str.indexOf('keyboard') >= 0) { result = 'Keyboard'; }
if (str.indexOf('mouse') >= 0) { result = 'Mouse'; }
if (str.indexOf('trackpad') >= 0) { result = 'Trackpad'; }
if (str.indexOf('speaker') >= 0) { result = 'Speaker'; }
if (str.indexOf('headset') >= 0) { result = 'Headset'; }
if (str.indexOf('phone') >= 0) { result = 'Phone'; }
Expand All @@ -55,6 +56,7 @@ function parseBluetoothManufacturer(str) {
if (str.indexOf('imac') >= 0) { result = 'Apple'; }
if (str.indexOf('iphone') >= 0) { result = 'Apple'; }
if (str.indexOf('magic mouse') >= 0) { result = 'Apple'; }
if (str.indexOf('magic track') >= 0) { result = 'Apple'; }
if (str.indexOf('macbook') >= 0) { result = 'Apple'; }
// to be continued ...

Expand Down
2 changes: 1 addition & 1 deletion lib/osinfo.js
Original file line number Diff line number Diff line change
Expand Up @@ -271,7 +271,7 @@ function osInfo(callback) {
exec('sysctl kern.ostype kern.osrelease kern.osrevision kern.hostuuid machdep.bootmethod kern.geom.confxml', function (error, stdout) {
let lines = stdout.toString().split('\n');
const distro = util.getValue(lines, 'kern.ostype');
const logofile = util.getValue(lines, 'kern.ostype');
const logofile = util.getLogoFile(distro);
const release = util.getValue(lines, 'kern.osrelease').split('-')[0];
const serial = util.getValue(lines, 'kern.uuid');
const bootmethod = util.getValue(lines, 'machdep.bootmethod');
Expand Down

0 comments on commit 83c01d2

Please sign in to comment.