Skip to content

Commit

Permalink
Support Laravel 8 and PHP 8 (#113)
Browse files Browse the repository at this point in the history
  • Loading branch information
GrahamCampbell committed Oct 12, 2020
1 parent 6a45190 commit bbebb53
Show file tree
Hide file tree
Showing 3 changed files with 56 additions and 27 deletions.
47 changes: 38 additions & 9 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,25 @@ jobs:

strategy:
matrix:
php: ['7.1', '7.2', '7.3', '7.4']
laravel: ['5.5', '5.6', '5.7', '5.8', '6', '7']
php: ['7.1', '7.2', '7.3', '7.4', '8.0']
laravel: ['5.5', '5.6', '5.7', '5.8', '6', '7', '8']
exclude:
- php: '7.1'
laravel: '6'
- php: '7.1'
laravel: '7'
- php: '7.1'
laravel: '8'
- php: '7.2'
laravel: '8'
- php: '8.0'
laravel: '5.5'
- php: '8.0'
laravel: '5.6'
- php: '8.0'
laravel: '5.7'
- php: '8.0'
laravel: '5.8'

steps:
- name: Checkout Code
Expand All @@ -39,55 +51,72 @@ jobs:
with:
timeout_minutes: 5
max_attempts: 5
command: composer require "laravel/framework:5.5.*" "phpunit/phpunit:^6.5" --no-update --no-interaction
command: composer require "laravel/framework:5.5.*" "phpunit/phpunit:^6.5.14" --no-update --no-interaction
if: "matrix.laravel == '5.5'"

- name: Select Laravel 5.6
uses: nick-invision/retry@v1
with:
timeout_minutes: 5
max_attempts: 5
command: composer require "laravel/framework:5.6.*" "phpunit/phpunit:^7.5" --no-update --no-interaction
command: composer require "laravel/framework:5.6.*" "phpunit/phpunit:^7.5.20" --no-update --no-interaction
if: "matrix.laravel == '5.6'"

- name: Select Laravel 5.7
uses: nick-invision/retry@v1
with:
timeout_minutes: 5
max_attempts: 5
command: composer require "laravel/framework:5.7.*" "phpunit/phpunit:^7.5" --no-update --no-interaction
command: composer require "laravel/framework:5.7.*" "phpunit/phpunit:^7.5.20" --no-update --no-interaction
if: "matrix.laravel == '5.7'"

- name: Select Laravel 5.8
uses: nick-invision/retry@v1
with:
timeout_minutes: 5
max_attempts: 5
command: composer require "laravel/framework:5.8.*" "phpunit/phpunit:^7.5|^8.5" --no-update --no-interaction
command: composer require "laravel/framework:5.8.*" "phpunit/phpunit:^7.5.20|^8.5.8" --no-update --no-interaction
if: "matrix.laravel == '5.8'"

- name: Select Laravel 6
uses: nick-invision/retry@v1
with:
timeout_minutes: 5
max_attempts: 5
command: composer require "laravel/framework:6.*" "phpunit/phpunit:^8.5|^9.0" --no-update --no-interaction
command: composer require "laravel/framework:6.*" "phpunit/phpunit:^8.5.8|^9.3.7" --no-update --no-interaction
if: "matrix.laravel == '6'"

- name: Select Laravel 7
uses: nick-invision/retry@v1
with:
timeout_minutes: 5
max_attempts: 5
command: composer require "laravel/framework:7.*" "phpunit/phpunit:^8.5|^9.0" --no-update --no-interaction
command: composer require "laravel/framework:7.*" "phpunit/phpunit:^8.5.8|^9.3.7" --no-update --no-interaction
if: "matrix.laravel == '7'"

- name: Install Dependencies
- name: Select Laravel 8
uses: nick-invision/retry@v1
with:
timeout_minutes: 5
max_attempts: 5
command: composer require "laravel/framework:8.*" "phpunit/phpunit:^9.3.7" --no-update --no-interaction
if: "matrix.laravel == '8'"

- name: Install PHP 7 Dependencies
uses: nick-invision/retry@v1
with:
timeout_minutes: 5
max_attempts: 5
command: composer update --no-interaction --no-progress
if: "matrix.php < 8"

- name: Install PHP 8 Dependencies
uses: nick-invision/retry@v1
with:
timeout_minutes: 5
max_attempts: 5
command: composer update --no-interaction --no-progress --ignore-platform-req=php
if: "matrix.php >= 8"

- name: Execute PHPUnit
run: vendor/bin/phpunit
16 changes: 8 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,14 +23,14 @@ This package automatically decorates objects bound to views during the view rend

## Installing

Laravel Auto Presenter requires [PHP](https://php.net) 7.1-7.4 and supports Laravel 5.5-7. If you need support for older Laravel or PHP versions, please choose an older version of Laravel Auto Presenter.
Laravel Auto Presenter requires [PHP](https://php.net) 7.1-8.0 and supports Laravel 5.5-8. If you need support for older Laravel or PHP versions, please choose an older version of Laravel Auto Presenter.

| Auto Presenter | L5.1 | L5.2 | L5.3 | L5.4 | L5.5 | L5.6 | L5.7 | L5.8 | L6 | L7 |
|----------------|--------------------|--------------------|--------------------|--------------------|--------------------|--------------------|--------------------|--------------------|--------------------|--------------------|
| 4.3 | :white_check_mark: | :white_check_mark: | :white_check_mark: | :x: | :x: | :x: | :x: | :x: | :x: | :x: |
| 5.0 | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :x: | :x: | :x: | :x: | :x: | :x: |
| 6.2 | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :x: | :x: | :x: | :x: | :x: |
| 7.4 | :x: | :x: | :x: | :x: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: |
| Auto Presenter | L5.1 | L5.2 | L5.3 | L5.4 | L5.5 | L5.6 | L5.7 | L5.8 | L6 | L7 | L8 |
|----------------|--------------------|--------------------|--------------------|--------------------|--------------------|--------------------|--------------------|--------------------|--------------------|--------------------|--------------------|
| 4.3 | :white_check_mark: | :white_check_mark: | :white_check_mark: | :x: | :x: | :x: | :x: | :x: | :x: | :x: | :x: |
| 5.0 | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :x: | :x: | :x: | :x: | :x: | :x: | :x: |
| 6.2 | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :x: | :x: | :x: | :x: | :x: | :x: |
| 7.5 | :x: | :x: | :x: | :x: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: |

To get the latest version, simply require the project using [Composer](https://getcomposer.org):

Expand All @@ -53,7 +53,7 @@ You can also optionally alias our facade:

In Laravel Auto Presenter 7, note that:

* Laravel 5.5-7 are supported now. Use V6 if you need L5.1-5.4.
* Laravel 5.5-8 are supported now. Use V6 if you need L5.1-5.4.
* Our new minimum PHP version requirement is 7.1.3, up from 7.0.0.

### Version 5 to 6
Expand Down
20 changes: 10 additions & 10 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,19 +14,19 @@
}
],
"require": {
"php": "^7.1.3",
"illuminate/container": "^5.5|^6.0|^7.0",
"illuminate/contracts": "^5.5|^6.0|^7.0",
"illuminate/events": "^5.5|^6.0|^7.0",
"illuminate/pagination": "^5.5|^6.0|^7.0",
"illuminate/support": "^5.5|^6.0|^7.0",
"illuminate/view": "^5.5|^6.0|^7.0"
"php": "^7.1.3 || ^8.0",
"illuminate/container": "^5.5 || ^6.0 || ^7.0 || ^8.0",
"illuminate/contracts": "^5.5 || ^6.0 || ^7.0 || ^8.0",
"illuminate/events": "^5.5 || ^6.0 || ^7.0 || ^8.0",
"illuminate/pagination": "^5.5 || ^6.0 || ^7.0 || ^8.0",
"illuminate/support": "^5.5 || ^6.0 || ^7.0 || ^8.0",
"illuminate/view": "^5.5 || ^6.0 || ^7.0 || ^8.0"
},
"require-dev": {
"graham-campbell/analyzer": "^2.4",
"graham-campbell/analyzer": "^2.4 || ^3.0",
"graham-campbell/testbench": "^5.4",
"mockery/mockery": "^1.3.1",
"phpunit/phpunit": "^6.5|^7.5|^8.4|^9.0"
"phpunit/phpunit": "^6.5.14 || ^7.5.20 || ^8.5.8 || ^9.3.7"
},
"autoload": {
"psr-4": {
Expand All @@ -43,7 +43,7 @@
},
"extra": {
"branch-alias": {
"dev-master": "7.4-dev"
"dev-master": "7.5-dev"
},
"laravel": {
"providers": [
Expand Down

0 comments on commit bbebb53

Please sign in to comment.