Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enhancement: Synchronize with ergebnis/php-package-template #304

Merged
merged 1 commit into from
Jan 2, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,9 @@ trim_trailing_whitespace = true
[*.json]
indent_size = 2

[*.md]
indent_size = 2

[*.neon]
indent_style = tab

Expand Down
3 changes: 3 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,11 @@
/.gitattributes export-ignore
/.gitignore export-ignore
/.php-cs-fixer.php export-ignore
/.yamllint.yaml export-ignore
/composer-require-checker.json export-ignore
/composer.lock export-ignore
/infection.json export-ignore
/Makefile export-ignore
/psalm-baseline.xml export-ignore
/psalm.xml export-ignore
/rector.php export-ignore
2 changes: 2 additions & 0 deletions .github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
@@ -1 +1,3 @@
# https://docs.github.com/en/repositories/managing-your-repositorys-settings-and-features/customizing-your-repository/about-code-owners#codeowners-file-size

* @ergebnis-bot @localheinz
42 changes: 33 additions & 9 deletions .github/CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ We are using [`yamllint`](https://github.com/adrienverge/yamllint) to enforce co
If you do not have `yamllint` installed yet, run

```sh
$ brew install yamllint
brew install yamllint
```

to install `yamllint`.
Expand All @@ -30,7 +30,7 @@ We are using [`friendsofphp/php-cs-fixer`](https://github.com/FriendsOfPHP/PHP-C
Run

```sh
$ make coding-standards
make coding-standards
```

to automatically fix coding standard violations.
Expand All @@ -42,19 +42,43 @@ We are using [`maglnet/composer-require-checker`](https://github.com/maglnet/Com
Run

```sh
$ make dependency-analysis
make dependency-analysis
```

to run a dependency analysis.

## Refactoring

We are using [`rector/rector`](https://github.com/rectorphp/rector) to automatically refactor code.

Run

```sh
make refactoring
```

to automatically refactor code.

## Security Analysis

We are using [`composer`](https://github.com/composer/composer) to run a security analysis.

Run

```sh
make security-analysis
```

to run a security analysis.

## Static Code Analysis

We are using [`vimeo/psalm`](https://github.com/vimeo/psalm) to statically analyze the code.

Run

```sh
$ make static-code-analysis
make static-code-analysis
```

to run a static code analysis.
Expand All @@ -64,7 +88,7 @@ We are also using the baseline feature of [`vimeo/psalm`](https://psalm.dev/docs
Run

```sh
$ make static-code-analysis-baseline
make static-code-analysis-baseline
```

to regenerate the baseline in [`../psalm-baseline.xml`](../psalm-baseline.xml).
Expand All @@ -78,7 +102,7 @@ We are using [`phpunit/phpunit`](https://github.com/sebastianbergmann/phpunit) t
Run

```sh
$ make tests
make tests
```

to run all the tests.
Expand All @@ -90,7 +114,7 @@ We are using [`infection/infection`](https://github.com/infection/infection) to
Enable `Xdebug` and run

```sh
$ make mutation-tests
make mutation-tests
```

to run mutation tests.
Expand All @@ -100,7 +124,7 @@ to run mutation tests.
Run

```sh
$ make
make
```

to enforce coding standards, run a static code analysis, and run tests!
Expand All @@ -110,7 +134,7 @@ to enforce coding standards, run a static code analysis, and run tests!
:bulb: Run

```sh
$ make help
make help
```

to display a list of available targets with corresponding descriptions.
34 changes: 19 additions & 15 deletions .github/settings.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,21 +13,23 @@ branches:
require_code_owner_reviews: true
required_approving_review_count: 1
required_status_checks:
contexts:
- "Code Coverage (8.0, locked)"
- "Coding Standards (8.0, locked)"
- "Dependency Analysis (8.0, locked)"
- "Mutation Tests (8.0, locked)"
- "Static Code Analysis (8.0, locked)"
- "Tests (8.0, highest)"
- "Tests (8.0, locked)"
- "Tests (8.0, lowest)"
- "Tests (8.1, highest)"
- "Tests (8.1, locked)"
- "Tests (8.1, lowest)"
- "Tests (8.2, highest)"
- "Tests (8.2, locked)"
- "Tests (8.2, lowest)"
checks:
- context: "Code Coverage (8.0, locked)"
- context: "Coding Standards (8.0, locked)"
- context: "Dependency Analysis (8.0, locked)"
- context: "Mutation Tests (8.0, locked)"
- context: "Refactoring (8.0, locked)"
- context: "Security Analysis (8.0, locked)"
- context: "Static Code Analysis (8.0, locked)"
- context: "Tests (8.0, highest)"
- context: "Tests (8.0, locked)"
- context: "Tests (8.0, lowest)"
- context: "Tests (8.1, highest)"
- context: "Tests (8.1, locked)"
- context: "Tests (8.1, lowest)"
- context: "Tests (8.2, highest)"
- context: "Tests (8.2, locked)"
- context: "Tests (8.2, lowest)"
strict: false
restrictions:

Expand Down Expand Up @@ -79,6 +81,8 @@ repository:
default_branch: "main"
delete_branch_on_merge: true
description: ":page_with_curl: Provides a JSON schema validator, building on top of justinrainbow/json-schema."
enable_automated_security_fixes: true
enable_vulnerability_alerts: true
has_downloads: true
has_issues: true
has_pages: false
Expand Down
Loading