-
Notifications
You must be signed in to change notification settings - Fork 437
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'phpro:master' into master
- Loading branch information
Showing
28 changed files
with
789 additions
and
31 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
version: 2 | ||
updates: | ||
- package-ecosystem: "github-actions" | ||
directory: "/" | ||
schedule: | ||
interval: "weekly" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
name: 'Dependency Review' | ||
on: [pull_request] | ||
|
||
permissions: | ||
contents: read | ||
|
||
jobs: | ||
dependency-review: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: 'Checkout Repository' | ||
uses: actions/checkout@v3 | ||
- name: 'Dependency Review' | ||
uses: actions/dependency-review-action@v3 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,16 @@ | ||
name: GrumPHP | ||
|
||
on: [push, pull_request] | ||
permissions: | ||
contents: read | ||
|
||
jobs: | ||
run: | ||
runs-on: ${{ matrix.operating-system }} | ||
strategy: | ||
matrix: | ||
operating-system: [ubuntu-latest, macos-latest] #windows-latest currently not working | ||
php-versions: ['7.4', '8.0', '8.1'] | ||
php-versions: ['8.0', '8.1', '8.2'] | ||
composer-options: ['', '--prefer-lowest'] | ||
composer-versions: ['composer:v2'] | ||
fail-fast: false | ||
|
@@ -30,20 +33,22 @@ jobs: | |
id: composercache | ||
run: echo "::set-output name=dir::$(composer config cache-files-dir)" | ||
- name: Cache dependencies | ||
uses: actions/cache@v2 | ||
uses: actions/cache@v3 | ||
with: | ||
path: ${{ steps.composercache.outputs.dir }} | ||
key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.json') }} | ||
restore-keys: ${{ runner.os }}-composer- | ||
- name: Install dependencies | ||
if: matrix.php-versions != '8.2' | ||
run: composer update --prefer-dist --no-progress --no-suggest ${{ matrix.composer-options }} | ||
# - name: Install dependencies (Ignore platform) | ||
# if: matrix.php-versions == '8.1' | ||
# run: composer update --prefer-dist --no-progress --no-suggest ${{ matrix.composer-options }} --ignore-platform-req=php | ||
- name: Install dependencies (Ignore platform) | ||
if: matrix.php-versions == '8.2' | ||
run: composer update --prefer-dist --no-progress --no-suggest ${{ matrix.composer-options }} --ignore-platform-req=php+ | ||
- name: Set git variables | ||
run: | | ||
git config --global user.email "[email protected]" | ||
git config --global user.name "Your Name" | ||
git config --global protocol.file.allow always | ||
- name: Run the tests on Windows | ||
if: runner.os == 'Windows' | ||
run: php vendor/bin/grumphp run --no-interaction --testsuite=windows | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -7,16 +7,17 @@ platform: | |
|
||
#matrix: | ||
# allow_failures: | ||
# - php_version: 8.1 | ||
# - php_version: 8.2 | ||
|
||
environment: | ||
matrix: | ||
# TODO : NOT AVAILABLE YET ! | ||
# - dependencies: highest | ||
# php_version: 8.2 | ||
- dependencies: highest | ||
php_version: 8.1 | ||
- dependencies: highest | ||
php_version: 8.0 | ||
- dependencies: highest | ||
php_version: 7.4 | ||
|
||
project_directory: c:\projects\grumphp | ||
composer_directory: c:\tools\composer | ||
|
@@ -71,6 +72,7 @@ install: | |
- IF %dependencies%==highest composer update --prefer-dist --no-progress --no-scripts --no-suggest --profile | ||
- git config --global user.email "[email protected]" | ||
- git config --global user.name "GrumPHP" | ||
- git config --global protocol.file.allow always | ||
|
||
test_script: | ||
- ps: cd $Env:project_directory | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
# PHPArkitect | ||
|
||
PHPArkitect helps you to keep your PHP codebase coherent and solid, by permitting to add some architectural constraint check to your workflow. | ||
It lives under the `phparkitect` namespace and has following configurable parameters: | ||
|
||
PhpArkitect doesn't support checking only the changed files. | ||
It will always run on the directory specified in your config file. | ||
|
||
## Composer | ||
```bash | ||
composer require --dev phparkitect/phparkitect | ||
``` | ||
|
||
## Config | ||
```yaml | ||
# grumphp.yml | ||
grumphp: | ||
tasks: | ||
phparkitect: | ||
config: ~ | ||
target_php_version: ~ | ||
stop_on_failure: ~ | ||
``` | ||
**config** | ||
*Default: null* | ||
With this parameter you can specify the path your project's configuration file. | ||
By default PHPArkitect will search all rules in phparkitect.php located in the root of your project. | ||
**target_php_version** | ||
*Default: null* | ||
With this parameter, you can specify which PHP version should use the parser. | ||
This can be useful to debug problems and to understand if there are problems with a different PHP version. | ||
**stop_on_failure** | ||
*Default: false* | ||
With this option the process will end immediately after the first violation. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
# Rector | ||
|
||
Rector is a tool to instantly upgrade and automatically refactor your PHP 5.3+ code. | ||
It lives under the `rector` namespace and has following configurable parameters: | ||
|
||
## Composer | ||
```bash | ||
composer require --dev rector/rector | ||
``` | ||
|
||
## Config | ||
```yaml | ||
# grumphp.yml | ||
grumphp: | ||
tasks: | ||
rector: | ||
config: null | ||
triggered_by: ['php'] | ||
ignore_patterns: [] | ||
clear_cache: true | ||
no_diffs: false | ||
``` | ||
**config** | ||
*Default: null* | ||
With this parameter you can specify the path your project's configuration file. When 'null' rector will run with the default file: rector.php | ||
**triggered_by** | ||
*Default: [php]* | ||
This is a list of extensions to be sniffed. | ||
**ignore_patterns** | ||
*Default: []* | ||
This is a list of patterns that will be ignored by Rector. With this option you can skip files like | ||
tests. Leave this option blank to run Rector for every php file/directory specified in your | ||
configuration. | ||
**clear_cache** | ||
*Default: true* | ||
With this parameter you can run Rector without using the cache. | ||
**no_diffs** | ||
*Default: false* | ||
With this parameter you can run Rector without showing file diffs. | ||
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.