Skip to content

Commit

Permalink
osInfo() improved logofile detection
Browse files Browse the repository at this point in the history
  • Loading branch information
sebhildebrandt committed Dec 29, 2024
1 parent d8a499e commit 1a5ff39
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 3 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,7 @@ For major (breaking) changes - **version 4, 3 and 2** - see end of page.

| Version | Date | Comment |
| ------- | ---------- | --------------------------------------------------------------------------------------------------- |
| 5.23.24 | 2024-12-29 | `osInfo()` improved logofile detection |
| 5.23.23 | 2024-12-25 | `bluetoothDevices()` added parsing vendor ID (macOS) |
| 5.23.22 | 2024-12-25 | `osInfo()` fix manufacturer Apple Silicon (macOS) |
| 5.23.21 | 2024-12-24 | `osInfo()` fix fqdn |
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.23.24</th>
<td>2024-12-29</td>
<td><span class="code">osInfo()</span> improved logo file detection</td>
</tr>
<tr>
<th scope="row">5.23.23</th>
<td>2024-12-25</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.23.23</span></div>
<div class="version">New Version: <span id="version">5.23.24</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 @@ -204,7 +204,7 @@
</div>
<div class="row number-section">
<div class="col-xl-4 col-lg-4 col-md-4 col-12">
<div class="numbers">17,135</div>
<div class="numbers">18,271</div>
<div class="title">Lines of code</div>
</div>
<div class="col-xl-4 col-lg-4 col-md-4 col-12">
Expand Down
11 changes: 10 additions & 1 deletion lib/osinfo.js
Original file line number Diff line number Diff line change
Expand Up @@ -76,12 +76,15 @@ function getLogoFile(distro) {
if (_windows) {
result = 'windows';
}
else if (distro.indexOf('mac os') !== -1) {
else if (distro.indexOf('mac os') !== -1 || distro.indexOf('macos') !== -1) {
result = 'apple';
}
else if (distro.indexOf('arch') !== -1) {
result = 'arch';
}
else if (distro.indexOf('cachy') !== -1) {
result = 'cachy';
}
else if (distro.indexOf('centos') !== -1) {
result = 'centos';
}
Expand All @@ -97,6 +100,9 @@ function getLogoFile(distro) {
else if (distro.indexOf('elementary') !== -1) {
result = 'elementary';
}
else if (distro.indexOf('endeavour') !== -1) {
result = 'endeavour';
}
else if (distro.indexOf('fedora') !== -1) {
result = 'fedora';
}
Expand Down Expand Up @@ -133,6 +139,9 @@ function getLogoFile(distro) {
else if (distro.indexOf('puppy') !== -1) {
result = 'puppy';
}
else if (distro.indexOf('popos') !== -1) {
result = 'popos';
}
else if (distro.indexOf('raspbian') !== -1) {
result = 'raspbian';
}
Expand Down

0 comments on commit 1a5ff39

Please sign in to comment.