Skip to content

Commit fe07643

Browse files
author
Andrey Helldar
committed
Added GitHub Actions rules
1 parent c367d29 commit fe07643

File tree

4 files changed

+97
-0
lines changed

4 files changed

+97
-0
lines changed

.github/workflows/laravel-8.yml

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
name: "Laravel 8"
2+
3+
on: [ push ]
4+
5+
jobs:
6+
build:
7+
runs-on: ubuntu-latest
8+
9+
strategy:
10+
fail-fast: true
11+
matrix:
12+
php: [ "8.0", "8.1" ]
13+
laravel: [ "8.0" ]
14+
15+
name: PHP ${{ matrix.php }}
16+
17+
steps:
18+
- name: Checkout code
19+
uses: actions/checkout@v3
20+
21+
- name: Setup PHP
22+
uses: shivammathur/setup-php@v2
23+
with:
24+
php-version: ${{ matrix.php }}
25+
extensions: curl, mbstring, zip, pcntl, pdo, pdo_sqlite, iconv
26+
coverage: none
27+
28+
- name: Install dependencies
29+
run: composer require --dev laravel/framework:^${{ matrix.laravel }}
30+
31+
- name: Execute tests
32+
run: sudo vendor/bin/phpunit --colors=always

.github/workflows/laravel-9.yml

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
name: "Laravel 9"
2+
3+
on: [ push ]
4+
5+
jobs:
6+
build:
7+
runs-on: ubuntu-latest
8+
9+
strategy:
10+
fail-fast: true
11+
matrix:
12+
php: [ "8.0", "8.1" ]
13+
laravel: [ "9.0" ]
14+
15+
name: PHP ${{ matrix.php }}
16+
17+
steps:
18+
- name: Checkout code
19+
uses: actions/checkout@v3
20+
21+
- name: Setup PHP
22+
uses: shivammathur/setup-php@v2
23+
with:
24+
php-version: ${{ matrix.php }}
25+
extensions: curl, mbstring, zip, pcntl, pdo, pdo_sqlite, iconv
26+
coverage: none
27+
28+
- name: Install dependencies
29+
run: composer require --dev laravel/framework:^${{ matrix.laravel }}
30+
31+
- name: Execute tests
32+
run: sudo vendor/bin/phpunit --colors=always

.github/workflows/lint-check.yml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
name: "Code-Style Check"
2+
3+
on: [ push, pull_request ]
4+
5+
jobs:
6+
check:
7+
runs-on: ubuntu-latest
8+
9+
steps:
10+
- name: Checkout code
11+
uses: actions/checkout@v3
12+
13+
- name: Checking PHP Syntax
14+
uses: TheDragonCode/[email protected]

.github/workflows/lint-fixer.yml

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
name: "Code-Style Fixer"
2+
3+
on:
4+
push:
5+
branches: [ main ]
6+
7+
jobs:
8+
fix:
9+
runs-on: ubuntu-latest
10+
11+
steps:
12+
- name: Checkout code
13+
uses: actions/checkout@v3
14+
15+
- name: Checking PHP Syntax
16+
uses: TheDragonCode/[email protected]
17+
with:
18+
github_token: ${{ secrets.COMPOSER_TOKEN }}
19+
fix: true

0 commit comments

Comments
 (0)