Skip to content

Commit

Permalink
Full support for PHP 8.0 now added. Bumping minimum supported PHP ver…
Browse files Browse the repository at this point in the history
…sions to 7.3. PHPUnit updated and tests refactored to work with v9.
  • Loading branch information
allebb committed Dec 23, 2020
1 parent 93a529b commit 05eebcc
Show file tree
Hide file tree
Showing 14 changed files with 1,111 additions and 341 deletions.
22 changes: 3 additions & 19 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ jobs:
strategy:
fail-fast: false
matrix:
php-versions: [ '7.2', '7.3', '7.4' ]
php-versions: [ '7.3', '7.4', '8.0' ]

steps:
- name: Checkout
Expand All @@ -27,25 +27,8 @@ jobs:
id: composer-cache
run: echo "::set-output name=dir::$(composer config cache-files-dir)"

#- name: Cache composer dependencies
# uses: actions/cache@v2
# with:
# path: ${{ steps.composer-cache.outputs.dir }}
# # Use composer.json for key, if composer.lock is not committed.
# # key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.json') }}
# key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }}
# restore-keys: ${{ runner.os }}-composer-

- name: Install Composer dependencies
run: composer install --no-suggest --no-progress --prefer-dist --optimize-autoloader

#- name: PHPUnit Tests
# uses: php-actions/phpunit@v1
# with:
# bootstrap: vendor/autoload.php
# configuration: phpunit.xml
# args: --coverage-text
# memory_limit: 256M
run: composer install --no-progress --prefer-dist --optimize-autoloader

- name: PHPUnit Tests
run: vendor/bin/phpunit --coverage-clover=coverage.xml
Expand All @@ -66,4 +49,5 @@ jobs:

# Uploading reports for analysis
- name: Uploading code coverage to scrutinize
continue-on-error: true
run: php ocular.phar code-coverage:upload --format=php-clover coverage.xml
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,5 @@
/report
.idea
.DS_Store
Thumbs.db
Thumbs.db
.phpunit.result.cache
12 changes: 10 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,9 @@ A super-lightweight package for speeding up development of PHP console (CLI) app
Requirements
------------

This library requires PHP 7.2+
This library is unit tested against PHP 7.3, 7.4 and 8.0!

If you need to use an older version of PHP, you should instead install the 2.x version of this library (see below for details).

License
-------
Expand All @@ -23,10 +25,16 @@ This client library is released under the MIT license, a [copy of the license](h
Setup
-----

To install the package into your project (assuming you are using the Composer package manager) you can simply execute the following command from your terminal in the root of your project folder:
To install the latest version of this package into your project (assuming you are using the Composer package manager) you can simply execute the following command from your terminal in the root of your project folder:

```composer require ballen/clip```

**If you need to use an older version of PHP, version 1.x.x supports PHP 5.6, 7.0, 7.1 and 7.2, you can install this version using Composer with this command instead:**

```shell
composer require ballen/clip ^1.0
```

Support
-------

Expand Down
6 changes: 3 additions & 3 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,11 @@
"issues": "https://github.com/bobsta63/clip/issues"
},
"require": {
"php": ">=7.2.0",
"ballen/collection": "^1.0"
"php": ">=7.3.0",
"ballen/collection": "^2.0"
},
"require-dev": {
"phpunit/phpunit": "4.8.*"
"phpunit/phpunit": "^9.0"
},
"suggest": {
"ext-posix": "Enables execution as super user (root) checking."
Expand Down
Loading

0 comments on commit 05eebcc

Please sign in to comment.