Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
kilip committed Aug 18, 2024
1 parent 4702eb9 commit 5982ec6
Show file tree
Hide file tree
Showing 3 changed files with 119 additions and 1 deletion.
92 changes: 92 additions & 0 deletions .commitlintrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,92 @@
{
"defaultIgnores": true,
"extends": "@commitlint/config-conventional",
"rules": {
"scope-enum": [
2,
"always",
[
"symfony",
"doctrine",
"github",
"pwa",
"api",
"ci",
"deps",
"docker-image",
"github-action"
]
],
"scope-empty": [
0
],
"body-leading-blank": [
1,
"always"
],
"body-max-line-length": [
2,
"always",
100
],
"footer-leading-blank": [
1,
"always"
],
"footer-max-line-length": [
2,
"always",
100
],
"header-max-length": [
2,
"always",
100
],
"subject-case": [
2,
"never",
[
"sentence-case",
"start-case",
"pascal-case",
"upper-case"
]
],
"subject-empty": [
2,
"never"
],
"subject-full-stop": [
2,
"never",
"."
],
"type-case": [
2,
"always",
"lower-case"
],
"type-empty": [
2,
"never"
],
"type-enum": [
2,
"always",
[
"build",
"chore",
"ci",
"docs",
"feat",
"fix",
"perf",
"refactor",
"revert",
"style",
"test"
]
]
}
}
2 changes: 1 addition & 1 deletion .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ on:
jobs:
static:
name: Static Check
uses: kilip/gh-common/.github/workflows/php-lint.yaml@main
uses: kilip/gh-php-common/.github/workflows/static-check.yaml@main
with:
php_version: 8.3
secrets: inherit
26 changes: 26 additions & 0 deletions .php-cs-fixer.dist.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
<?php

$header = <<<'HEADER'
This file is part of the Crank project.
(c) Anthonius Munthi <[email protected]>
For the full copyright and license information, please view the LICENSE
file that was distributed with this source code.
HEADER;

$finder = (new PhpCsFixer\Finder())
->in(__DIR__)
->exclude('var')
;

return (new PhpCsFixer\Config())
->setRules([
'@Symfony' => true,
'header_comment' => [
'header' => $header,
'location' => 'after_open',
],
])
->setFinder($finder)
;

0 comments on commit 5982ec6

Please sign in to comment.