The client requires PHP >= 7.4.
The recommended way to install ImboClient is with Composer. If you do not have Composer installed you need to do this first:
curl -sS https://getcomposer.org/installer | php
When this is done you can add ImboClient as a dependency to your project:
composer require imbo/imboclient:^3.0
After installation you need to require the autoloader generated by Composer:
Licensed using the MIT license.
Copyright 2011 Christer Edvartsen Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
- ImboClient adheres to the Imbo coding standard. The PHP Coding Standards Fixer tool is used to enforce this.
- The minimum PHP version requirement is
- All changes / new features must include unit tests.
Running checks locally¶
Before pushing code you might want to run the CI checks locally to make sure your pull request does not fail. This can be done by running a composer script after you have installed all dependencies:
# Clone the repository git clone email@example.com:imbo/imboclient-php.git && cd imboclient-php # Install dependencies composer install # Run script that will execute the different checks composer run ci
You can also run the different checks separately:
# Run unit tests ./vendor/bin/phpunit # Run static code analysis ./vendor/bin/psalm # Check coding standard php-cs-fixer fix --dry-run --diff
The last check requires a local installation of PHP Coding Standards Fixer. The first two should be executable after a successful