PHPackages                             sofiakb/os-detector - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. sofiakb/os-detector

ActiveLibrary

sofiakb/os-detector
===================

A library to detect OS

v0.0.2(4y ago)053MITPHP

Since Jul 5Pushed 4y ago1 watchersCompare

[ Source](https://github.com/sofiakb/os-detector)[ Packagist](https://packagist.org/packages/sofiakb/os-detector)[ RSS](/packages/sofiakb-os-detector/feed)WikiDiscussions main Synced today

READMEChangelog (1)Dependencies (1)Versions (3)Used By (0)

[![Contributors](https://camo.githubusercontent.com/da4332abb43dc3fa21ee217fbc1430ceb411296510ceb96f6ddd5712b064f8bb/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f636f6e7472696275746f72732f736f6669616b622f6f732d6465746563746f722e7376673f7374796c653d666f722d7468652d6261646765)](https://github.com/sofiakb/os-detector/graphs/contributors)[![Forks](https://camo.githubusercontent.com/e23d069c08fbe318c8a3cf5db2cc5b3c389bcc27d31c1ece42e253c752548c66/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f666f726b732f736f6669616b622f6f732d6465746563746f722e7376673f7374796c653d666f722d7468652d6261646765)](https://github.com/sofiakb/os-detector/network/members)[![Stargazers](https://camo.githubusercontent.com/3c407ac83031beffd39efb63488e4a911f5e87a061151c7d547cb40a56289c24/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f73746172732f736f6669616b622f6f732d6465746563746f722e7376673f7374796c653d666f722d7468652d6261646765)](https://github.com/sofiakb/os-detector/stargazers)[![Issues](https://camo.githubusercontent.com/9bb88ed17c6f56bc36315a902a0237c1cb5401a1c50fcdbdb94a36594a741d9f/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6973737565732f736f6669616b622f6f732d6465746563746f722e7376673f7374796c653d666f722d7468652d6261646765)](https://github.com/sofiakb/os-detector/issues)[![MIT License](https://camo.githubusercontent.com/442f56c70b4a4b852562393632560ab1da7f1e9784f6d4d84ec448d798b6cedb/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6c6963656e73652f736f6669616b622f6f732d6465746563746f722e7376673f7374796c653d666f722d7468652d6261646765)](https://github.com/sofiakb/os-detector/blob/main/LICENSE)

os-detector
===========

[](#os-detector)

 A PHP Library for detect OS System !

 [Report Bug](https://github.com/sofiakb/os-detector/issues) · [Request Feature](https://github.com/sofiakb/os-detector/issues)

 Table of Contents1. [About the library](#about-the-project)
    - [Built With](#built-with)
2. [Getting Started](#getting-started)
    - [Prerequisites](#prerequisites)
    - [Installation](#installation)
3. [Usage](#usage)
4. [Roadmap](#roadmap)
5. [Contributing](#contributing)
6. [License](#license)
7. [Contact](#contact)
8. [Acknowledgements](#acknowledgements)

About The Library
-----------------

[](#about-the-library)

The library allows to detect os system in PHP project.

### Built With

[](#built-with)

This section should list any major frameworks that you built your project using. Leave any add-ons/plugins for the acknowledgements section. Here are a few examples.

- [PHP](https://php.net)

### Prerequisites

[](#prerequisites)

- php &gt;= 7.4

### Installation

[](#installation)

```
composer require sofiakb/os-detector
```

Usage
-----

[](#usage)

```
use Sofiakb\DetectOS\System;

// Get os with
$os = System::getOS();

// Verify os with
System::isLinux();
System::isMac();
System::isWindows();
```

Roadmap
-------

[](#roadmap)

See the [open issues](https://github.com/sofiakb/os-detector/issues) for a list of proposed features (and known issues).

License
-------

[](#license)

Distributed under the MIT License. See `LICENSE` for more information.

###  Health Score

21

—

LowBetter than 19% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity8

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity42

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 75% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~2 days

Total

2

Last Release

1767d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/83745581?v=4)[sofiakb](/maintainers/sofiakb)[@sofiakb](https://github.com/sofiakb)

---

Top Contributors

[![sowsouf](https://avatars.githubusercontent.com/u/17595186?v=4)](https://github.com/sowsouf "sowsouf (9 commits)")[![sofiakb](https://avatars.githubusercontent.com/u/83745581?v=4)](https://github.com/sofiakb "sofiakb (3 commits)")

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/sofiakb-os-detector/health.svg)

```
[![Health](https://phpackages.com/badges/sofiakb-os-detector/health.svg)](https://phpackages.com/packages/sofiakb-os-detector)
```

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
