Skip to content

Commit e9f8dbe

Browse files
committed
v1.0 changes
1 parent f07777a commit e9f8dbe

28 files changed

+757
-137
lines changed

.gitattributes

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
/.github export-ignore
2+
/tests export-ignore
3+
/phpunit.xml.dist export-ignore
4+
/.gitattributes export-ignore
5+
/.gitignore export-ignore
6+
/.php-cs-fixer.dist.php export-ignore
7+
/psalm.xml export-ignore
8+
9+
*.php diff=php

.gitignore

100755100644
Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1-
vendor/
1+
vendor
22
composer.lock
33
.phpunit.result.cache
4+
.php-cs-fixer.cache
5+
test-coverage-report
6+
phpunit.xml
7+
.php-cs-fixer.php
8+
phpstan.neon

.idea/.gitignore

Lines changed: 8 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.idea/PluginLogger.iml

Lines changed: 91 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.idea/modules.xml

Lines changed: 8 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.idea/php.xml

Lines changed: 107 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.idea/vcs.xml

Lines changed: 6 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.php-cs-fixer.dist.php

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
<?php
2+
3+
if (!file_exists(__DIR__.'/src')) {
4+
exit(0);
5+
}
6+
7+
$finder = (new PhpCsFixer\Finder())
8+
->in(__DIR__.'/src')
9+
->in(__DIR__.'/tests')
10+
;
11+
12+
return (new PhpCsFixer\Config())
13+
->setRules(array(
14+
'@Symfony' => true,
15+
'@Symfony:risky' => true,
16+
'protected_to_private' => false,
17+
'semicolon_after_instruction' => false,
18+
'header_comment' => [
19+
'header' => <<<EOF
20+
This file is part of the Micro framework package.
21+
22+
(c) Stanislau Komar <kost@micro-php.net>
23+
24+
For the full copyright and license information, please view the LICENSE
25+
file that was distributed with this source code.
26+
EOF
27+
]
28+
))
29+
->setRiskyAllowed(true)
30+
->setFinder($finder);

composer.json

Lines changed: 40 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,22 +2,60 @@
22
"name": "micro/plugin-logger-core",
33
"description": "Micro Framework: Logger plugin",
44
"type": "library",
5-
"version": "1.0",
65
"license": "MIT",
76
"autoload": {
87
"psr-4": {
98
"Micro\\Plugin\\Logger\\": "src/"
109
}
1110
},
11+
"autoload-dev": {
12+
"psr-4": {
13+
"Micro\\Plugin\\Logger\\Test\\": "tests/"
14+
}
15+
},
1216
"authors": [
1317
{
1418
"name": "Stanislau.Komar",
1519
"email": "stanislau_komar@epam.com"
1620
}
1721
],
1822
"require": {
23+
"micro/kernel-boot-configuration": "^1",
24+
"micro/kernel-boot-dependency": "^1",
1925
"micro/kernel": "^1",
20-
"php": ">=8.0",
2126
"psr/log": "^1|^2|^3"
27+
},
28+
"require-dev": {
29+
"ergebnis/composer-normalize": "^2.29",
30+
"friendsofphp/php-cs-fixer": "^3.13",
31+
"phpstan/phpstan": "^1.9",
32+
"phpunit/php-code-coverage": "^9.2",
33+
"phpunit/phpunit": "^9.5",
34+
"vimeo/psalm": "^5.2"
35+
},
36+
"config": {
37+
"allow-plugins": {
38+
"ergebnis/composer-normalize": true
39+
},
40+
"sort-packages": true
41+
},
42+
"scripts": {
43+
"coverage": "XDEBUG_MODE=coverage ./vendor/bin/phpunit --coverage-text",
44+
"php-cs-fix": "PHP_CS_FIXER_IGNORE_ENV=1 ./vendor/bin/php-cs-fixer fix --verbose --using-cache=no",
45+
"php-cs-try": "./vendor/bin/php-cs-fixer fix --verbose --dry-run --using-cache=no",
46+
"phpstan": "./vendor/bin/phpstan analyze --no-progress",
47+
"phpunit": "./vendor/bin/phpunit",
48+
"psalm": "./vendor/bin/psalm --no-progress --show-info=true",
49+
"statics": [
50+
"@phpstan",
51+
"@psalm",
52+
"@php-cs-try"
53+
],
54+
"test": [
55+
"@statics",
56+
"composer validate --strict",
57+
"composer normalize",
58+
"@coverage"
59+
]
2260
}
2361
}

phpstan.neon.dist

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
parameters:
2+
level: 7
3+
paths:
4+
- src

0 commit comments

Comments
 (0)