Skip to content

Commit

Permalink
Merge pull request #1 from matyo91/github-workflow
Browse files Browse the repository at this point in the history
✨ Add workflow
  • Loading branch information
matyo91 authored Aug 30, 2024
2 parents 06b63a1 + a095cdb commit cd32115
Show file tree
Hide file tree
Showing 25 changed files with 843 additions and 2,141 deletions.
3 changes: 3 additions & 0 deletions .github/FUNDING.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# These are supported funding model platforms

github: [matyo91]
236 changes: 236 additions & 0 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,236 @@
name: Continuous Integration

on:
push:
branches:
- main
pull_request:

jobs:
# infection:
# name: Run Infection
# runs-on: ubuntu-latest
# strategy:
# matrix:
# php: [ '8.3' ]
# steps:
# - name: Init repository
# uses: actions/checkout@v3
#
# - name: Setup PHP
# uses: shivammathur/setup-php@v2
# with:
# php-version: ${{ matrix.php }}
# extensions: xsl, openswoole
# tools: composer
#
# - name: Install dependencies
# run: |
# composer install
# composer install -d tools/infection
#
# - name: Run Infection
# run: (cd tools && infection/vendor/bin/infection --configuration=infection/infection.json)

# phan:
# name: Run Phan
# runs-on: ubuntu-latest
# strategy:
# matrix:
# php: [ '8.3' ]
# steps:
# - name: Init repository
# uses: actions/checkout@v3
#
# - name: Setup PHP
# uses: shivammathur/setup-php@v2
# with:
# php-version: ${{ matrix.php }}
# extensions: xsl, openswoole, ast
# tools: composer
#
# - name: Install dependencies
# run: |
# composer install
# composer install -d tools/phan
#
# - name: Run Phan
# run: (cd tools && phan/vendor/bin/phan --config-file phan/phan.php)

php-cs-fixer:
name: Check and fix coding styles using PHP CS Fixer
runs-on: ubuntu-latest
strategy:
matrix:
php: [ '8.3' ]
steps:
- name: Checkout
uses: actions/checkout@v3

- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
extensions: xsl, openswoole
tools: composer
coverage: none # disable XDebug for tests

- name: Install dependencies
run: |
composer install
composer install -d tools/php-cs-fixer
- name: Check and fix coding styles using PHP CS Fixer
run: (cd tools && php-cs-fixer/vendor/bin/php-cs-fixer fix --config php-cs-fixer/.php-cs-fixer.php --diff --dry-run)

# phpcbf:
# name: Clean code with PHP Code Beautifier and Fixer
# runs-on: ubuntu-latest
# strategy:
# matrix:
# php: [ '8.3' ]
# steps:
# - name: Init repository
# uses: actions/checkout@v3
#
# - name: Setup PHP
# uses: shivammathur/setup-php@v2
# with:
# php-version: ${{ matrix.php }}
# extensions: xsl, openswoole, ast
# tools: composer
#
# - name: Install dependencies
# run: |
# composer install
# composer install -d tools/phpcbf
#
# - name: Clean code with PHP Code Beautifier and Fixer
# run: (cd tools && phpcbf/vendor/bin/phpcbf --standard=phpcbf/phpcs.xml)

# phpcs:
# name: Run PHP Code Sniffer
# runs-on: ubuntu-latest
# strategy:
# matrix:
# php: [ '8.3' ]
# steps:
# - name: Init repository
# uses: actions/checkout@v3
#
# - name: Setup PHP
# uses: shivammathur/setup-php@v2
# with:
# php-version: ${{ matrix.php }}
# extensions: xsl, openswoole, ast
# tools: composer
#
# - name: Install dependencies
# run: |
# composer install
# composer install -d tools/phpcs
#
# - name: Run PHP Code Sniffer
# run: (cd tools && phpcs/vendor/bin/phpcs --standard=phpcs/phpcs.xml)

# phpmd:
# name: Run PHP Mess Detector
# runs-on: ubuntu-latest
# strategy:
# matrix:
# php: [ '8.3' ]
# steps:
# - name: Init repository
# uses: actions/checkout@v3
#
# - name: Setup PHP
# uses: shivammathur/setup-php@v2
# with:
# php-version: ${{ matrix.php }}
# extensions: xsl, openswoole
# tools: composer
#
# - name: Install dependencies
# run: |
# composer install
# composer install -d tools/phpmd
#
# - name: Run PHP Mess Detector
# run: (cd tools && phpmd/vendor/bin/phpmd ../examples/,../src/,../tests/ text phpmd/phpmd.xml)

phpstan:
name: Execute PHPStan analysis
runs-on: ubuntu-latest
strategy:
matrix:
php: [ '8.3' ]
steps:
- name: Checkout
uses: actions/checkout@v3

- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
extensions: xsl, openswoole
tools: composer
coverage: none # disable XDebug for tests

- name: 'Install dependencies'
run: |
composer install
composer install -d tools/phpstan
- name: Execute PHPStan analysis
run: (cd tools && phpstan/vendor/bin/phpstan --configuration=phpstan/phpstan.neon)

phpunit:
name: Launch PHPUnit test suite
runs-on: ubuntu-latest
strategy:
matrix:
php: [ '8.3' ]
steps:
- name: Init repository
uses: actions/checkout@v3

- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
extensions: xsl, openswoole
tools: composer
coverage: none # disable XDebug for tests

- name: Install dependencies
run: |
composer install
composer install -d tools/phpunit
- name: Launch PHPUnit test suite
run: (cd tools && phpunit/vendor/bin/phpunit --configuration phpunit/phpunit.xml)

# psalm:
# name: Run PHP Mess Detector
# runs-on: ubuntu-latest
# strategy:
# matrix:
# php: [ '8.3' ]
# steps:
# - name: Init repository
# uses: actions/checkout@v3
#
# - name: Setup PHP
# uses: shivammathur/setup-php@v2
# with:
# php-version: ${{ matrix.php }}
# extensions: xsl, openswoole
# tools: composer
#
# - name: Install dependencies
# run: |
# composer install
# composer install -d tools/psalm
#
# - name: Run PHP Mess Detector
# run: (cd tools && psalm/vendor/bin/psalm --no-cache --config psalm/psalm.xml)
8 changes: 8 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,14 @@ The recommended way to install it through [Composer](http://getcomposer.org) and
composer require darkwood/flow
```

## Usage

### Run Flow exemples

```
bin/console app:flow-exemples
```

## License

Live Flow is released under the MIT License.
1 change: 0 additions & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,6 @@
}
},
"require-dev": {
"phpunit/phpunit": "^9.5",
"symfony/browser-kit": "7.1.*",
"symfony/css-selector": "7.1.*",
"symfony/debug-bundle": "7.1.*",
Expand Down
Loading

0 comments on commit cd32115

Please sign in to comment.