-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
This PR was squashed before being merged into the 2.0-dev branch. Discussion ---------- | Q | A | ------------- | --- | Bug fix? | no | New feature? | yes | BC breaks? | no | Deprecations? | no | Fixed tickets | | License | MIT Drop support for PHP 7, and modernize the codebase. Commits ------- 1d30586 Clean-up old files 6961f85 Drop support for PHP 7 c4ace14 Modernize readme a6e7640 Add GitHub workflow
- Loading branch information
Showing
28 changed files
with
488 additions
and
323 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 |
---|---|---|
@@ -1,14 +1,14 @@ | ||
* text=auto | ||
|
||
# Always use LF | ||
core.autocrlf=lf | ||
|
||
.editorconfig | ||
.editorconfig export-ignore | ||
.gitattributes export-ignore | ||
.gitignore export-ignore | ||
.php_cs export-ignore | ||
.scrutinizer.yml export-ignore | ||
.travis.yml export-ignore | ||
.github export-ignore | ||
phpspec.yml export-ignore | ||
/spec export-ignore | ||
.php-cs-fixer.dist.php export-ignore | ||
CODE_OF_CONDUCT.md export-ignore | ||
Makefile export-ignore | ||
phpunit.xml.dist export-ignore | ||
phpstan.neon export-ignore | ||
phpstan-baseline.neon export-ignore | ||
tests/ export-ignore |
This file was deleted.
Oops, something went wrong.
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,20 @@ | ||
--- | ||
name: "\U0001F41B Bug Report" | ||
about: Report errors and problems | ||
title: "[bug] " | ||
labels: Potential Bug | ||
assignees: '' | ||
|
||
--- | ||
|
||
**Description** | ||
<!-- A clear and concise description of the problem. --> | ||
|
||
**How to reproduce** | ||
<!-- Code and/or config needed to reproduce the problem. --> | ||
|
||
**Possible Solution** | ||
<!--- Optional: only if you have suggestions on a fix/reason for the bug --> | ||
|
||
**Additional context** | ||
<!-- Optional: any other context about the problem: log messages, screenshots, etc. --> |
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,15 @@ | ||
--- | ||
name: "\U0001F680 Feature Request" | ||
about: "I have a suggestion (and may want to implement it \U0001F642)!" | ||
title: "[Feature] " | ||
labels: Feature | ||
assignees: '' | ||
|
||
--- | ||
|
||
**Description** | ||
<!-- A clear and concise description of the new feature. --> | ||
|
||
**Example** | ||
<!-- A simple example of the new feature in action (include PHP code, YAML config, etc.) | ||
If the new feature changes an existing feature, include a simple before/after comparison. --> |
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,13 @@ | ||
--- | ||
name: 👩🏫 Support Question | ||
about: Questions about using this library | ||
labels: Question / Support | ||
|
||
--- | ||
|
||
**Description** | ||
<!-- A clear and concise description of the problem. Also include what you tried, and any code | ||
snippets if you have them. | ||
Please be patient, it may take some to get a response. Thanks. | ||
--> |
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: ⛔ Security Issue | ||
about: Report security issues and problems (PLEASE DON'T DISCLOSE SECURITY-RELATED ISSUES PUBLICLY) | ||
|
||
--- | ||
|
||
⚠ PLEASE DON'T DISCLOSE SECURITY-RELATED ISSUES PUBLICLY, SEE BELOW. | ||
|
||
If you have found a security issue in this project, please send the details to | ||
security [at] rollerscapes.net and don't disclose it publicly until we can provide a | ||
fix for it. | ||
|
||
**Note:** Please don't blindly send reports about automated tools, make sure the | ||
reported issue is in fact exploitable. Thanks. |
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,157 @@ | ||
name: 'CI' | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
pull_request: | ||
branches: | ||
- main | ||
|
||
jobs: | ||
cs-fixer: | ||
name: 'PHP CS Fixer' | ||
|
||
runs-on: 'ubuntu-latest' | ||
|
||
strategy: | ||
matrix: | ||
php-version: | ||
- '8.2' | ||
|
||
steps: | ||
- | ||
name: 'Check out' | ||
uses: 'actions/checkout@v4' | ||
|
||
- | ||
name: 'Set up PHP' | ||
uses: 'shivammathur/setup-php@v2' | ||
with: | ||
php-version: '${{ matrix.php-version }}' | ||
coverage: 'none' | ||
|
||
- | ||
name: 'Get Composer cache directory' | ||
id: 'composer-cache' | ||
run: 'echo "cache_dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT' | ||
|
||
- | ||
name: 'Cache dependencies' | ||
uses: 'actions/cache@v3' | ||
with: | ||
path: '${{ steps.composer-cache.outputs.cache_dir }}' | ||
key: "php-${{ matrix.php-version }}-composer-locked-${{ hashFiles('composer.lock') }}" | ||
restore-keys: 'php-${{ matrix.php-version }}-composer-locked-' | ||
|
||
- | ||
name: 'Install dependencies' | ||
run: 'composer install --no-progress' | ||
|
||
- | ||
name: 'Check the code style' | ||
run: 'make cs' | ||
|
||
phpstan: | ||
name: 'PhpStan' | ||
|
||
runs-on: 'ubuntu-latest' | ||
|
||
strategy: | ||
matrix: | ||
php-version: | ||
- '8.2' | ||
|
||
steps: | ||
- | ||
name: 'Check out' | ||
uses: 'actions/checkout@v4' | ||
|
||
- | ||
name: 'Set up PHP' | ||
uses: 'shivammathur/setup-php@v2' | ||
with: | ||
php-version: '${{ matrix.php-version }}' | ||
coverage: 'none' | ||
|
||
- | ||
name: 'Get Composer cache directory' | ||
id: 'composer-cache' | ||
run: 'echo "cache_dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT' | ||
|
||
- | ||
name: 'Cache dependencies' | ||
uses: 'actions/cache@v3' | ||
with: | ||
path: '${{ steps.composer-cache.outputs.cache_dir }}' | ||
key: "php-${{ matrix.php-version }}-composer-locked-${{ hashFiles('composer.lock') }}" | ||
restore-keys: 'php-${{ matrix.php-version }}-composer-locked-' | ||
|
||
- | ||
name: 'Install dependencies' | ||
run: 'composer install --no-progress' | ||
|
||
- | ||
name: 'Run PhpStan' | ||
run: 'vendor/bin/phpstan analyze --no-progress' | ||
|
||
tests: | ||
name: 'PHPUnit' | ||
|
||
runs-on: 'ubuntu-latest' | ||
|
||
strategy: | ||
matrix: | ||
include: | ||
- | ||
php-version: '8.1' | ||
composer-options: '--prefer-stable' | ||
symfony-version: '6.3' | ||
- | ||
php-version: '8.2' | ||
composer-options: '--prefer-stable' | ||
symfony-version: '^6.4' | ||
|
||
- | ||
php-version: '8.2' | ||
composer-options: '--prefer-stable' | ||
symfony-version: '^7.0' | ||
|
||
steps: | ||
- | ||
name: 'Check out' | ||
uses: 'actions/checkout@v4' | ||
|
||
- | ||
name: 'Set up PHP' | ||
uses: 'shivammathur/setup-php@v2' | ||
with: | ||
php-version: '${{ matrix.php-version }}' | ||
coverage: 'none' | ||
|
||
- | ||
name: 'Get Composer cache directory' | ||
id: 'composer-cache' | ||
run: 'echo "cache_dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT' | ||
|
||
- | ||
name: 'Cache dependencies' | ||
uses: 'actions/cache@v3' | ||
with: | ||
path: '${{ steps.composer-cache.outputs.cache_dir }}' | ||
key: "php-${{ matrix.php-version }}-composer-locked-${{ hashFiles('composer.lock') }}" | ||
restore-keys: 'php-${{ matrix.php-version }}-composer-locked-' | ||
|
||
- | ||
name: 'Install dependencies' | ||
env: | ||
COMPOSER_OPTIONS: '${{ matrix.composer-options }}' | ||
SYMFONY_REQUIRE: '${{ matrix.symfony-version }}' | ||
run: | | ||
composer global config --no-plugins allow-plugins.symfony/flex true | ||
composer global require --no-progress --no-scripts --no-plugins symfony/flex | ||
composer update --no-progress $COMPOSER_OPTIONS | ||
- | ||
name: 'Run tests' | ||
run: make phpunit |
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,4 +1,9 @@ | ||
/composer.lock | ||
*.phar | ||
composer.lock | ||
/vendor/ | ||
.php_cs.cache | ||
|
||
phpunit.xml | ||
.phpunit.result.cache | ||
.phpunit.cache/ | ||
.phpunit | ||
|
||
.php-cs-fixer.cache |
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,30 @@ | ||
<?php | ||
|
||
$header = <<<EOF | ||
This file is part of the Rollerworks UriEncoder package. | ||
(c) Sebastiaan Stok <[email protected]> | ||
This source file is subject to the MIT license that is bundled | ||
with this source code in the file LICENSE. | ||
EOF; | ||
|
||
/** @var \Symfony\Component\Finder\Finder $finder */ | ||
$finder = PhpCsFixer\Finder::create(); | ||
$finder | ||
->in([ | ||
__DIR__ . '/src', | ||
__DIR__ . '/tests', | ||
]); | ||
|
||
$config = new PhpCsFixer\Config(); | ||
$config | ||
->setRiskyAllowed(true) | ||
->setRules( | ||
array_merge( | ||
require __DIR__ . '/vendor/rollerscapes/standards/php-cs-fixer-rules.php', | ||
['header_comment' => ['header' => $header]]) | ||
) | ||
->setFinder($finder); | ||
|
||
return $config; |
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.