Skip to content

Commit

Permalink
Merge 2.x into 3.x
Browse files Browse the repository at this point in the history
  • Loading branch information
SonataCI committed Mar 29, 2022
2 parents c2ecae3 + 4d71257 commit 668e114
Show file tree
Hide file tree
Showing 9 changed files with 46 additions and 29 deletions.
7 changes: 3 additions & 4 deletions .github/workflows/documentation.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:

steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v3

- name: Set up Python 3.7
uses: actions/setup-python@v2
Expand All @@ -32,10 +32,9 @@ jobs:
run: python -c "import sys; print(sys.version)"

- name: Cache pip
uses: actions/cache@v2
uses: actions/cache@v3
with:
path: ~/.cache/pip

key: ${{ runner.os }}-pip-${{ hashFiles('docs/requirements.txt') }}
restore-keys: ${{ runner.os }}-pip-

Expand All @@ -52,7 +51,7 @@ jobs:

steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v3

- name: Run DOCtor-RST
uses: docker://oskarstark/doctor-rst
Expand Down
28 changes: 14 additions & 14 deletions .github/workflows/lint.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,16 +21,21 @@ jobs:

steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v3

- name: Install PHP with extensions
uses: shivammathur/setup-php@v2
with:
php-version: '8.1'
coverage: none
tools: composer:v2, php-cs-fixer:3
env:
COMPOSER_TOKEN: ${{ secrets.GITHUB_TOKEN }}
tools: composer:v2
extensions: mongodb

- name: Install Composer dependencies (highest)
uses: ramsey/composer-install@v2
with:
dependency-versions: highest
composer-options: --prefer-dist --prefer-stable

- name: Lint PHP files
run: make lint-php
Expand All @@ -42,7 +47,7 @@ jobs:

steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v3

- name: Install PHP with extensions
uses: shivammathur/setup-php@v2
Expand All @@ -63,15 +68,10 @@ jobs:

steps:
- name: Checkout
uses: actions/checkout@v2

- name: Install Ruby 2.6
uses: actions/setup-ruby@v1
with:
ruby-version: '2.6'
uses: actions/checkout@v3

- name: Install required gem
run: gem install yaml-lint
- name: Install yamllint
run: sudo apt-get install yamllint

- name: Lint files
run: make lint-yaml
Expand All @@ -83,7 +83,7 @@ jobs:

steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v3

- name: Install required dependencies
run: sudo apt-get update && sudo apt-get install libxml2-utils
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/qa.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:

steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v3

- name: Install PHP with extensions
uses: shivammathur/setup-php@v2
Expand All @@ -46,7 +46,7 @@ jobs:

steps:
- name: Checkout code
uses: actions/checkout@v2
uses: actions/checkout@v3

- name: Install PHP with extensions
uses: shivammathur/setup-php@v2
Expand Down
10 changes: 6 additions & 4 deletions .github/workflows/stale.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,18 +10,20 @@ on:
schedule:
- cron: 0 9-18 * * *

permissions:
issues: write
pull-requests: write

jobs:
stale:
runs-on: ubuntu-latest

steps:
- name: Close stale issues and pull requests
uses: actions/stale@v1.1.0
uses: actions/stale@v5
with:
days-before-close: 7
days-before-stale: 180
repo-token: ${{ secrets.GITHUB_TOKEN }}
exempt-issue-label: keep
exempt-issue-labels: keep
stale-issue-label: stale
stale-issue-message: >
This issue has been automatically marked as stale because it has not had
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ jobs:

steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v3

- name: Install PHP with extensions
uses: shivammathur/setup-php@v2
Expand Down
11 changes: 11 additions & 0 deletions .php-cs-fixer.dist.php
Original file line number Diff line number Diff line change
@@ -1,5 +1,16 @@
<?php

declare(strict_types=1);

/*
* This file is part of the Sonata Project package.
*
* (c) Thomas Rabaix <thomas.rabaix@sonata-project.org>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/

/*
* DO NOT EDIT THIS FILE!
*
Expand Down
4 changes: 2 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -44,14 +44,14 @@ lint-xliff:
.PHONY: lint-xliff

lint-php:
php-cs-fixer fix --ansi --verbose --diff --dry-run
vendor/bin/php-cs-fixer fix --ansi --verbose --diff --dry-run
.PHONY: lint-php

cs-fix: cs-fix-php cs-fix-xml cs-fix-xliff cs-fix-composer
.PHONY: cs-fix

cs-fix-php:
php-cs-fixer fix --verbose
vendor/bin/php-cs-fixer fix --verbose
.PHONY: cs-fix-php

cs-fix-xml:
Expand Down
5 changes: 5 additions & 0 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@
"doctrine/dbal": "^2.13 || ^3.0",
"doctrine/mongodb-odm": "^2.0",
"doctrine/orm": "^2.9",
"friendsofphp/php-cs-fixer": "^3.4",
"matthiasnoback/symfony-config-test": "^4.2",
"matthiasnoback/symfony-dependency-injection-test": "^4.0",
"phpoffice/phpspreadsheet": "^1.0",
Expand Down Expand Up @@ -72,6 +73,10 @@
}
},
"config": {
"allow-plugins": {
"composer/package-versions-deprecated": true,
"phpstan/extension-installer": true
},
"sort-packages": true
}
}
4 changes: 2 additions & 2 deletions tests/bootstrap.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,14 @@
* file that was distributed with this source code.
*/

use Doctrine\Deprecations\Deprecation;

/*
* DO NOT EDIT THIS FILE!
*
* It's auto-generated by sonata-project/dev-kit package.
*/

use Doctrine\Deprecations\Deprecation;

/*
* fix encoding issue while running text on different host with different locale configuration
*/
Expand Down

0 comments on commit 668e114

Please sign in to comment.