2017 © Pedro PelĂĄez
 

library php-os-detector

A small utility library that detects the OS the server is running on

image

tivie/php-os-detector

A small utility library that detects the OS the server is running on

  • Saturday, October 21, 2017
  • by Tivie
  • Repository
  • 1 Watchers
  • 6 Stars
  • 229,539 Installations
  • PHP
  • 10 Dependents
  • 0 Suggesters
  • 2 Forks
  • 0 Open issues
  • 4 Versions
  • 26 % Grown

The README.md

PHP OS Detector

Latest Stable Version Total Downloads License, (*1)

A small PHP utility library that detects the OS the server is running on., (*2)

Compatibility

Although only tested in PHP 7, PHP OS Detector should be compatible with PHP 5.3 or greater, (*3)

Installation

You can install it by cloning the git repository or using composer., (*4)

Git clone

git clone https://github.com/tivie/php-os-detector.git

Composer

Add these lines to your composer.json:, (*5)

    {
        "require": {
            "tivie/php-os-detector": "*"
        }
    }

or run the following command:, (*6)

php composer.phar require tivie/php-os-detector

Usage Example

$os = new \Tivie\OS\Detector();
$kernelName = $os->getKernelName();
if ($os->isUnixLike()) {
    echo "I'm using a Unix like system with kernel $kernelName";
} else if ($os->isWindowsLike()) {
    echo "I'm using a Windows like system with kernel $kernelName";
} else {
    echo "I'm using a non-Unix non-Windows system";
}

Contribute

Feel free to contribute by forking or making suggestions., (*7)

Issue tracker: https://github.com/tivie/php-os-detector/issues, (*8)

Source code: https://github.com/tivie/php-os-detector, (*9)

License

Command Library is released under Apache 2.0 license. For more information, please consult the LICENSE file in this repository or http://www.apache.org/licenses/LICENSE-2.0.txt., (*10)

The Versions

21/10 2017

dev-master

9999999-dev http://tivie.github.com/php-os-detector/

A small utility library that detects the OS the server is running on

  Sources   Download

Apache-2.0 Apache 2.0

The Requires

  • php >=5.3.0

 

The Development Requires

by EstevĂŁo Soares dos Santos

detector os detection operating system identification os detection

21/10 2017

1.1.0

1.1.0.0 http://tivie.github.com/php-os-detector/

A small utility library that detects the OS the server is running on

  Sources   Download

Apache 2.0

The Requires

  • php >=5.3.0

 

The Development Requires

by EstevĂŁo Soares dos Santos

detector os detection operating system identification os detection

22/12 2014

dev-develop

dev-develop http://tivie.github.com/php-os-detector/

A small utility library that detects the OS the server is running on

  Sources   Download

Apache 2.0

The Requires

  • php >=5.3.0

 

The Development Requires

by EstevĂŁo Soares dos Santos

detector os detection operating system identification os detection

19/12 2014

1.0.0

1.0.0.0 http://tivie.github.com/php-os-detector/

A small utility library that detects the OS the server is running on

  Sources   Download

Apache 2.0

The Requires

  • php >=5.3.0

 

The Development Requires

by EstevĂŁo Soares dos Santos

detector os detection operating system identification os detection