Skip to content

Commit 5430498

Browse files
Merge pull request #1 from archiprocode/master
Implement an Event mangement system for Silverstripe CMS
2 parents 8f9577b + da0f6d4 commit 5430498

23 files changed

+1743
-0
lines changed

.github/workflows/ci.yml

+49
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
name: CI
2+
3+
on:
4+
push:
5+
pull_request:
6+
workflow_dispatch:
7+
8+
jobs:
9+
ci:
10+
name: CI
11+
uses: silverstripe/gha-ci/.github/workflows/ci.yml@v1
12+
with:
13+
dynamic_matrix: false
14+
extra_jobs: |
15+
- php: '8.1'
16+
db: mysql80
17+
phpunit: true
18+
installer_version: ^4
19+
- php: '8.2'
20+
db: mysql80
21+
phpunit: true
22+
installer_version: ^5
23+
- php: '8.3'
24+
db: mariadb
25+
phpunit: true
26+
installer_version: ^5
27+
28+
coding-standards:
29+
name: Coding Standards
30+
runs-on: ubuntu-latest
31+
32+
steps:
33+
- uses: actions/checkout@v3
34+
35+
- name: Setup PHP
36+
uses: shivammathur/setup-php@v2
37+
with:
38+
php-version: '8.1'
39+
coverage: none
40+
tools: composer:v2, php-cs-fixer
41+
42+
- name: Install dependencies
43+
run: composer install --prefer-dist --no-progress
44+
45+
- name: Check coding standards
46+
run: php-cs-fixer fix --dry-run --diff
47+
48+
- name: Static Analysis
49+
run: vendor/bin/phpstan analyse

.gitignore

+13
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
/vendor/
2+
.phpunit.result.cache
3+
.php-cs-cache
4+
.env
5+
.idea/
6+
.vscode/
7+
*.swp
8+
*.swo
9+
.DS_Store
10+
composer.lock
11+
/public/
12+
.php-cs-fixer.cache
13+
phpstan.cache/

.php-cs-fixer.dist.php

+32
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
<?php
2+
3+
$finder = PhpCsFixer\Finder::create()
4+
->in([
5+
__DIR__ . '/src',
6+
__DIR__ . '/tests',
7+
])
8+
->name('*.php')
9+
->ignoreDotFiles(true)
10+
->ignoreVCS(true);
11+
12+
$config = new PhpCsFixer\Config();
13+
14+
return $config
15+
->setRules([
16+
'@PSR12' => true,
17+
'array_syntax' => ['syntax' => 'short'],
18+
'ordered_imports' => ['sort_algorithm' => 'alpha'],
19+
'no_unused_imports' => true,
20+
'trailing_comma_in_multiline' => true,
21+
'phpdoc_align' => true,
22+
'phpdoc_order' => true,
23+
'phpdoc_separation' => true,
24+
'phpdoc_single_line_var_spacing' => true,
25+
'phpdoc_trim' => true,
26+
'phpdoc_var_without_name' => true,
27+
'return_type_declaration' => ['space_before' => 'none'],
28+
'single_quote' => true,
29+
'ternary_operator_spaces' => true,
30+
'unary_operator_spaces' => true,
31+
])
32+
->setFinder($finder);

0 commit comments

Comments
 (0)