Skip to content

Commit c2974a1

Browse files
authored
Merge pull request #8 from Joeri-Abbo/master
Update existing workflows to support laravel-dashboard
2 parents 1f045ec + 8567fb7 commit c2974a1

File tree

5 files changed

+30
-64
lines changed

5 files changed

+30
-64
lines changed

.github/workflows/php-cs-fixer.yml

+9-21
Original file line numberDiff line numberDiff line change
@@ -5,25 +5,13 @@ on: [push]
55
jobs:
66
style:
77
runs-on: ubuntu-latest
8-
98
steps:
10-
- name: Checkout code
11-
uses: actions/checkout@v1
12-
13-
- name: Fix style
14-
uses: docker://oskarstark/php-cs-fixer-ga
15-
with:
16-
args: --config=.php_cs --allow-risky=yes
17-
18-
- name: Extract branch name
19-
shell: bash
20-
run: echo "##[set-output name=branch;]$(echo ${GITHUB_REF#refs/heads/})"
21-
id: extract_branch
22-
23-
- name: Commit changes
24-
uses: stefanzweifel/[email protected]
25-
with:
26-
commit_message: Fix styling
27-
branch: ${{ steps.extract_branch.outputs.branch }}
28-
env:
29-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
9+
- name: Git checkout
10+
uses: actions/checkout@v2
11+
- name: Install Dependencies
12+
run: composer install -q --no-ansi --no-interaction --no-scripts --no-progress --prefer-dist
13+
- name: normalize php
14+
run: php vendor/bin/phpcbf
15+
- uses: stefanzweifel/[email protected]
16+
with:
17+
commit_message: Fix formatting with phpcbf

.github/workflows/run-tests.yml

+4-4
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,11 @@ jobs:
1010
matrix:
1111
os: [ubuntu-latest, windows-latest]
1212
php: [7.4]
13-
laravel: [7.*]
13+
laravel: [8.*]
1414
dependency-version: [prefer-lowest, prefer-stable]
1515
include:
16-
- laravel: 7.*
17-
testbench: 5.*
16+
- laravel: 8.*
17+
testbench: 6.*
1818

1919
name: P${{ matrix.php }} - L${{ matrix.laravel }} - ${{ matrix.dependency-version }} - ${{ matrix.os }}
2020

@@ -38,7 +38,7 @@ jobs:
3838
- name: Install dependencies
3939
run: |
4040
composer require "laravel/framework:${{ matrix.laravel }}" "orchestra/testbench:${{ matrix.testbench }}" --no-interaction --no-update
41-
composer update --${{ matrix.dependency-version }} --prefer-dist --no-interaction --no-suggest
41+
composer update --${{ matrix.dependency-version }} --prefer-dist --no-interaction --no-suggest --ignore-platform-req=ext-fileinfo
4242
4343
- name: Execute tests
4444
run: vendor/bin/phpunit

.php_cs

-38
This file was deleted.

composer.json

+2-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,8 @@
2020
"spatie/laravel-dashboard": "^2.0"
2121
},
2222
"require-dev": {
23-
"phpunit/phpunit": "^9.3"
23+
"phpunit/phpunit": "^9.3",
24+
"squizlabs/php_codesniffer": "^3.6.2"
2425
},
2526
"autoload": {
2627
"psr-4": {

phpcs.xml

+15
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
<?xml version="1.0"?>
2+
<ruleset name="spatie">
3+
4+
<file>src</file>
5+
<file>tests</file>
6+
7+
<rule ref="PSR1" />
8+
<rule ref="PSR2" />
9+
<rule ref="PSR12" />
10+
11+
<rule ref="Generic.Files.LineLength">
12+
<severity>0</severity>
13+
</rule>
14+
15+
</ruleset>

0 commit comments

Comments
 (0)