Skip to content

Commit c398d5e

Browse files
authored
Add Dependabot and improve build pipeline (#23)
* Add dependabot config * Update actions/cache and simplify variable usage in build
1 parent d237909 commit c398d5e

File tree

2 files changed

+28
-2
lines changed

2 files changed

+28
-2
lines changed

.github/dependabot.yml

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
version: 2
2+
3+
updates:
4+
- package-ecosystem: "composer"
5+
directory: "/"
6+
allow:
7+
- dependency-type: "development"
8+
schedule:
9+
interval: "daily"
10+
time: "05:00"
11+
timezone: "Europe/Vienna"
12+
labels:
13+
- "composer dependencies"
14+
15+
- package-ecosystem: "github-actions"
16+
directory: "/"
17+
schedule:
18+
interval: "weekly"
19+
day: "monday"
20+
time: "05:00"
21+
timezone: "Europe/Vienna"
22+
labels:
23+
- "github actions"

.github/workflows/tests.yml

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,9 @@ jobs:
1616
strategy:
1717
matrix:
1818
php-version: ['7.4', '8.0', '8.1']
19+
include:
20+
- php-version: '8.1'
21+
run-sonarqube-analysis: true
1922

2023
steps:
2124
- uses: actions/checkout@v2
@@ -41,7 +44,7 @@ jobs:
4144
echo "::set-output name=dir::$(composer config cache-files-dir)"
4245
4346
- name: Cache Composer dependencies
44-
uses: actions/cache@v2
47+
uses: actions/cache@v3
4548
with:
4649
path: ${{ steps.composer-cache.outputs.dir }}
4750
key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }}
@@ -55,7 +58,7 @@ jobs:
5558

5659
- name: Run SonarQube analysis
5760
uses: sonarsource/sonarcloud-github-action@master
58-
if: matrix.php-version == '8.1'
61+
if: matrix.run-sonarqube-analysis
5962
env:
6063
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
6164
SONAR_TOKEN: ${{ secrets.SONARCLOUD_TOKEN }}

0 commit comments

Comments
 (0)