Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
39 changes: 39 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
# A library commits no composer.lock, so CI resolves the newest versions on
# every run and audits them; Dependabot watches the constraints in
# composer.json and the actions. Minor and patch updates come once a week in
# one pull request per ecosystem; security updates as soon as they are
# published.
version: 2
updates:
- package-ecosystem: composer
directory: /
schedule:
interval: weekly
day: monday
time: '06:00'
timezone: Europe/Sofia
open-pull-requests-limit: 5
versioning-strategy: widen
groups:
composer:
applies-to: version-updates
update-types: [minor, patch]
composer-security:
applies-to: security-updates
patterns: ['*']

- package-ecosystem: github-actions
directory: /
schedule:
interval: weekly
day: monday
time: '06:00'
timezone: Europe/Sofia
open-pull-requests-limit: 5
groups:
actions:
applies-to: version-updates
update-types: [minor, patch]
actions-security:
applies-to: security-updates
patterns: ['*']
19 changes: 15 additions & 4 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,11 @@ on:
permissions:
contents: read

# A newer push to the same branch or pull request replaces a run still in progress.
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

jobs:
tests:
name: PHP ${{ matrix.php }}
Expand All @@ -17,9 +22,9 @@ jobs:
matrix:
php: ['8.3', '8.4', '8.5']
steps:
- uses: actions/checkout@v5
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1

- uses: shivammathur/setup-php@v2
- uses: shivammathur/setup-php@eb7c497e18156a6bbabfef1d3a82760b9eda3962 # 2.40.0
with:
php-version: ${{ matrix.php }}
extensions: bcmath, dom, libxml
Expand All @@ -31,6 +36,12 @@ jobs:
- name: Install dependencies
run: composer update --no-interaction --no-progress --prefer-dist

# The newest versions the constraints allow, checked against the
# advisories: what a new install of this library gets.
- name: Composer audit
if: matrix.php == '8.4'
run: composer audit

- name: Coding standard
if: matrix.php == '8.4'
run: vendor/bin/php-cs-fixer fix --dry-run --diff
Expand All @@ -48,8 +59,8 @@ jobs:
name: Lowest dependencies (PHP 8.3)
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v5
- uses: shivammathur/setup-php@v2
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
- uses: shivammathur/setup-php@eb7c497e18156a6bbabfef1d3a82760b9eda3962 # 2.40.0
with:
php-version: '8.3'
extensions: bcmath, dom, libxml
Expand Down
1 change: 1 addition & 0 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@
"cs": "php-cs-fixer fix --dry-run --diff",
"cs:fix": "php-cs-fixer fix",
"check": [
"@composer audit",
"@cs",
"@analyse",
"@test"
Expand Down
Loading