Initial commit again

This commit is contained in:
Greyscale 2024-04-14 18:50:37 +02:00
parent a36125fdda
commit efcd26fb51
5 changed files with 100 additions and 1 deletions

50
.github/workflows/test.yml vendored Normal file
View file

@ -0,0 +1,50 @@
name: Tests
on:
push:
workflow_dispatch:
pull_request:
concurrency:
group: tests-${{ github.head_ref || github.run_id }}
cancel-in-progress: true
env:
ACTION_TOKEN: ${{ github.token }}
jobs:
phpcsfixer:
name: PHP-CS-Fixer
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: PHP-CS-Fixer
uses: docker://oskarstark/php-cs-fixer-ga
phpunit:
name: PHPUnit
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: php-actions/composer@v6
- uses: php-actions/phpunit@v3
phpstan:
name: PHPStan
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: php-actions/composer@v6
- uses: php-actions/phpstan@v3
with:
path: src/
trunk:
name: Trunk Check Runner
runs-on: ubuntu-latest
permissions:
checks: write # For trunk to post annotations
steps:
- uses: actions/checkout@v3
- uses: trunk-io/trunk-action@v1

3
.gitignore vendored
View file

@ -1,2 +1,3 @@
/vendor/
/.idea
/.idea
/.github/act.secrets

9
.trunk/.gitignore vendored Normal file
View file

@ -0,0 +1,9 @@
*out
*logs
*actions
*notifications
*tools
plugins
user_trunk.yaml
user.yaml
tmp

View file

@ -0,0 +1,7 @@
rules:
quoted-strings:
required: only-when-needed
extra-allowed: ["{|}"]
key-duplicates: {}
octal-values:
forbid-implicit-octal: true

32
.trunk/trunk.yaml Normal file
View file

@ -0,0 +1,32 @@
# This file controls the behavior of Trunk: https://docs.trunk.io/cli
# To learn more about the format of this file, see https://docs.trunk.io/reference/trunk-yaml
version: 0.1
cli:
version: 1.21.0
# Trunk provides extensibility via plugins. (https://docs.trunk.io/plugins)
plugins:
sources:
- id: trunk
ref: v1.4.5
uri: https://github.com/trunk-io/plugins
# Many linters and tools depend on runtimes - configure them here. (https://docs.trunk.io/runtimes)
runtimes:
enabled:
- node@18.12.1
- python@3.10.8
# This is the section where you manage your linters. (https://docs.trunk.io/check/configuration)
lint:
enabled:
- actionlint@1.6.27
- checkov@3.2.60
- git-diff-check
- prettier@3.2.5
- trivy@0.50.1
- trufflehog@3.71.0
- yamllint@1.35.1
actions:
enabled:
- trunk-announce
- trunk-check-pre-push
- trunk-fmt-pre-commit
- trunk-upgrade-available