Skip to content

Commit 2e0eb6e

Browse files
committed
Fix YAML file extension
1 parent e38e94a commit 2e0eb6e

File tree

4 files changed

+22
-20
lines changed

4 files changed

+22
-20
lines changed

README.md

Lines changed: 19 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88

99
Pdepend Summary Formatter is a tool to show software code quality metrics, measured by
1010
[PHP Depend](https://github.com/pdepend/pdepend) (pdepend),
11-
in console for development and in CI/CD.
11+
in console for development and in CI/CD pipeline.
1212

1313
## Table of contents
1414
<!-- MarkdownTOC levels="1,2,3,4,5,6" autoanchor="true" autolink="true" -->
@@ -35,7 +35,7 @@ composer require --dev pdepend/pdepend:"^2.15"
3535
composer require --dev andrey-tech/pdepend-summary-formatter-php
3636
```
3737

38-
Generate a default config file `pdepend-summary-formatter.yaml.dist` in current working directory:
38+
Generate a default config file `pdepend-summary-formatter.yml.dist` in current working directory:
3939

4040
```shell
4141
./vendor/bin/pdepend-summary-formatter --init
@@ -63,7 +63,7 @@ measured by PHP Depend, in console and write results to specified text file `sum
6363

6464
The command line interface also accepts the following optional arguments:
6565

66-
- `--init` - Will generate a default config file `pdepend-summary-formatter.yaml.dist` in current working directory.
66+
- `--init` - Will generate a default config file `pdepend-summary-formatter.yml.dist` in current working directory.
6767
- `--output-file=` - Write results also to the specified text file.
6868
- `--config-file=` - The filepath to a custom config YAML file.
6969
- `--no-colors` - Disable colors in console.
@@ -72,10 +72,10 @@ An example command line of Pdepend Summary Formatter tool and PHP Depend tool:
7272

7373
```shell
7474
./vendor/bin/pdepend --summary-xml=./var/summary.xml --suffix=php src,tests
75-
./vendor/bin/pdepend-summary-formatter ./var/summary.xml --config-file=./pdepend-sf.yaml --output-file=./var/summary.txt
75+
./vendor/bin/pdepend-summary-formatter ./var/summary.xml --config-file=./pdepend-summary-formatter.yml --output-file=./var/summary.txt
7676
```
7777

78-
An example of output file `summary.txt`:
78+
An example of output text file `summary.txt`:
7979

8080
```text
8181
FILE: src/AndreyTech/Pdepend/Summary/Formatter/Colorizer.php
@@ -112,12 +112,14 @@ from a given code base, these values can be used to measure the quality of a sof
112112
and they help to identify that parts of an application where a refactoring should be applied.
113113

114114
Pdepend Summary Formatter tool shows only part of software metrics, measured by PHP Depend,
115-
and colors them (green, yellow, red) in the console according to boundaries for values,
116-
established in configuration YAML file.
115+
and colors them
116+
(<span style="color: green">green</span>, <span style="color: yellow">yellow</span>, <span style="color: red">red</span>)
117+
in the console according to boundaries for values, defined in configuration YAML file.
117118

118-
This table give a list of the software metrics, shows by Depend Summary Formatter tool
119+
This table give a list of the software metrics, shows by Pdepend Summary Formatter tool
119120
for entire project, classes, traits, methods,
120-
and default values for red boundaries, based on [PHP Mess Detector](https://phpmd.org/) (PHPMD) tool.
121+
and default values for <span style="color: red">red</span> boundaries of software metrics,
122+
based on [PHP Mess Detector](https://phpmd.org/) (PHPMD) tool.
121123

122124
| Metric | Description | Project | Class | Trait | Method |
123125
|--------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---------|-------|-------|--------|
@@ -161,22 +163,22 @@ Note: ✓ - means there are no defined color boundaries for this metric.
161163
## Configuration YAML file
162164

163165
By default Pdepend Summary Formatter search following configuration YAML files is current working directory:
164-
- `pdepend-summary-formatter.yaml`,
165-
- `pdepend-summary-formatter.yaml.dist`.
166+
- `pdepend-summary-formatter.yml`,
167+
- `pdepend-summary-formatter.yml.dist`.
166168

167169
Configuration YAML file allow to set color boundaries for values of software metrics.
168170

169171
Pdepend Summary Formatter tool currently defines three color boundaries:
170172

171-
| Color | Description |
172-
|----------|-------------|
173-
| `green` | Ok |
174-
| `yellow` | Warning |
175-
| `red` | Error |
173+
| Color | Description |
174+
|-------------------------------------------|-------------|
175+
| <span style="color: green">green</span> | Ok |
176+
| <span style="color: yellow">yellow</span> | Warning |
177+
| <span style="color: red">red</span> | Error |
176178

177179
A white value means there are no defined color boundaries for this metric.
178180

179-
> You can also add/set custom colors and options.
181+
> You can also add/set custom colors and styles.
180182
> See [How to Color and Style the Console Output](https://symfony.com/doc/current/console/coloring.html) in Symfony console.
181183
182184
Fragment of default configuration file:

composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "andrey-tech/pdepend-summary-formatter-php",
3-
"description": "Tool to show software code quality metrics, measured by PHP Depend, in console and CI/CD",
3+
"description": "Tool to show software code quality metrics, measured by PHP Depend, in console and CI/CD pipeline",
44
"keywords": [
55
"dev",
66
"pdepend",
File renamed without changes.

src/AndreyTech/Pdepend/Summary/Formatter/Config.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,8 @@
2727

2828
final class Config
2929
{
30-
private const CONFIG_FILE = 'pdepend-summary-formatter.yaml';
31-
private const CONFIG_FILE_DIST = 'pdepend-summary-formatter.yaml.dist';
30+
private const CONFIG_FILE = 'pdepend-summary-formatter.yml';
31+
private const CONFIG_FILE_DIST = 'pdepend-summary-formatter.yml.dist';
3232
private const CONFIG_DIR = __DIR__ . '/../../../../../config';
3333

3434
private ConsoleOutput $consoleOutput;

0 commit comments

Comments
 (0)