Skip to content

Commit 99d4e46

Browse files
committed
Initial commit
0 parents  commit 99d4e46

36 files changed

+11114
-0
lines changed

.editorconfig

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
root = true
2+
3+
[*]
4+
charset = utf-8
5+
end_of_line = lf
6+
insert_final_newline = true
7+
indent_style = space
8+
indent_size = 4
9+
trim_trailing_whitespace = true
10+
11+
[*.md]
12+
trim_trailing_whitespace = false
13+
14+
[*.{yml,yaml}]
15+
indent_size = 2
16+
17+
[Makefile]
18+
indent_style = tab

.github/CODE_OF_CONDUCT.md

Lines changed: 128 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,128 @@
1+
# Contributor Covenant Code of Conduct
2+
3+
## Our Pledge
4+
5+
We as members, contributors, and leaders pledge to make participation in our
6+
community a harassment-free experience for everyone, regardless of age, body
7+
size, visible or invisible disability, ethnicity, sex characteristics, gender
8+
identity and expression, level of experience, education, socio-economic status,
9+
nationality, personal appearance, race, religion, or sexual identity
10+
and orientation.
11+
12+
We pledge to act and interact in ways that contribute to an open, welcoming,
13+
diverse, inclusive, and healthy community.
14+
15+
## Our Standards
16+
17+
Examples of behavior that contributes to a positive environment for our
18+
community include:
19+
20+
* Demonstrating empathy and kindness toward other people
21+
* Being respectful of differing opinions, viewpoints, and experiences
22+
* Giving and gracefully accepting constructive feedback
23+
* Accepting responsibility and apologizing to those affected by our mistakes,
24+
and learning from the experience
25+
* Focusing on what is best not just for us as individuals, but for the
26+
overall community
27+
28+
Examples of unacceptable behavior include:
29+
30+
* The use of sexualized language or imagery, and sexual attention or
31+
advances of any kind
32+
* Trolling, insulting or derogatory comments, and personal or political attacks
33+
* Public or private harassment
34+
* Publishing others' private information, such as a physical or email
35+
address, without their explicit permission
36+
* Other conduct which could reasonably be considered inappropriate in a
37+
professional setting
38+
39+
## Enforcement Responsibilities
40+
41+
Community leaders are responsible for clarifying and enforcing our standards of
42+
acceptable behavior and will take appropriate and fair corrective action in
43+
response to any behavior that they deem inappropriate, threatening, offensive,
44+
or harmful.
45+
46+
Community leaders have the right and responsibility to remove, edit, or reject
47+
comments, commits, code, wiki edits, issues, and other contributions that are
48+
not aligned to this Code of Conduct, and will communicate reasons for moderation
49+
decisions when appropriate.
50+
51+
## Scope
52+
53+
This Code of Conduct applies within all community spaces, and also applies when
54+
an individual is officially representing the community in public spaces.
55+
Examples of representing our community include using an official e-mail address,
56+
posting via an official social media account, or acting as an appointed
57+
representative at an online or offline event.
58+
59+
## Enforcement
60+
61+
Instances of abusive, harassing, or otherwise unacceptable behavior may be
62+
reported to the community leaders responsible for enforcement at
63+
the@wayof.dev.
64+
All complaints will be reviewed and investigated promptly and fairly.
65+
66+
All community leaders are obligated to respect the privacy and security of the
67+
reporter of any incident.
68+
69+
## Enforcement Guidelines
70+
71+
Community leaders will follow these Community Impact Guidelines in determining
72+
the consequences for any action they deem in violation of this Code of Conduct:
73+
74+
### 1. Correction
75+
76+
**Community Impact**: Use of inappropriate language or other behavior deemed
77+
unprofessional or unwelcome in the community.
78+
79+
**Consequence**: A private, written warning from community leaders, providing
80+
clarity around the nature of the violation and an explanation of why the
81+
behavior was inappropriate. A public apology may be requested.
82+
83+
### 2. Warning
84+
85+
**Community Impact**: A violation through a single incident or series
86+
of actions.
87+
88+
**Consequence**: A warning with consequences for continued behavior. No
89+
interaction with the people involved, including unsolicited interaction with
90+
those enforcing the Code of Conduct, for a specified period of time. This
91+
includes avoiding interactions in community spaces as well as external channels
92+
like social media. Violating these terms may lead to a temporary or
93+
permanent ban.
94+
95+
### 3. Temporary Ban
96+
97+
**Community Impact**: A serious violation of community standards, including
98+
sustained inappropriate behavior.
99+
100+
**Consequence**: A temporary ban from any sort of interaction or public
101+
communication with the community for a specified period of time. No public or
102+
private interaction with the people involved, including unsolicited interaction
103+
with those enforcing the Code of Conduct, is allowed during this period.
104+
Violating these terms may lead to a permanent ban.
105+
106+
### 4. Permanent Ban
107+
108+
**Community Impact**: Demonstrating a pattern of violation of community
109+
standards, including sustained inappropriate behavior, harassment of an
110+
individual, or aggression toward or disparagement of classes of individuals.
111+
112+
**Consequence**: A permanent ban from any sort of public interaction within
113+
the community.
114+
115+
## Attribution
116+
117+
This Code of Conduct is adapted from the [Contributor Covenant][homepage],
118+
version 2.0, available at
119+
https://www.contributor-covenant.org/version/2/0/code_of_conduct.html.
120+
121+
Community Impact Guidelines were inspired by [Mozilla's code of conduct
122+
enforcement ladder](https://github.com/mozilla/diversity).
123+
124+
[homepage]: https://www.contributor-covenant.org
125+
126+
For answers to common questions about this code of conduct, see the FAQ at
127+
https://www.contributor-covenant.org/faq. Translations are available at
128+
https://www.contributor-covenant.org/translations.

.github/FUNDING.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
3+
github: wayofdev
4+
5+
...

.github/ISSUE_TEMPLATE.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
#### Steps required to reproduce the problem
2+
3+
1.
4+
2.
5+
3.
6+
7+
#### Expected Result
8+
9+
*
10+
11+
#### Actual Result
12+
13+
*

.github/dependabot.yml

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
---
2+
3+
version: 2
4+
updates:
5+
- package-ecosystem: "github-actions"
6+
directory: "/"
7+
schedule:
8+
interval: "daily"
9+
commit-message:
10+
include: "scope"
11+
prefix: "github-actions"
12+
labels:
13+
- "deps"
14+
open-pull-requests-limit: 10
15+
16+
- package-ecosystem: "composer"
17+
directory: "/"
18+
schedule:
19+
interval: "daily"
20+
commit-message:
21+
include: "scope"
22+
prefix: "composer"
23+
labels:
24+
- "deps"
25+
open-pull-requests-limit: 10
26+
versioning-strategy: "increase"
27+
28+
...

.github/workflows/ci.yml

Lines changed: 63 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,63 @@
1+
---
2+
3+
name: ci
4+
5+
on: # yamllint disable-line rule:truthy
6+
push:
7+
branches:
8+
- master
9+
pull_request:
10+
branches:
11+
- master
12+
13+
jobs:
14+
integration:
15+
name: PHP ${{ matrix.php }} - L${{ matrix.laravel }} - ${{ matrix.os }}
16+
runs-on: ${{ matrix.os }}
17+
strategy:
18+
fail-fast: true
19+
matrix:
20+
os: ["ubuntu-22.04"]
21+
php: ["8.1"]
22+
laravel: ["9.*"]
23+
steps:
24+
- name: Check out the codebase
25+
uses: actions/checkout@v3
26+
27+
- name: Setup PHP
28+
uses: shivammathur/setup-php@v2
29+
with:
30+
php-version: ${{ matrix.php }}
31+
extensions: dom, curl, libxml, mbstring, zip, fileinfo
32+
ini-values: error_reporting=E_ALL
33+
tools: composer:v2
34+
coverage: none
35+
36+
- name: Setup problem matchers
37+
run: |
38+
echo "::add-matcher::${{ runner.tool_cache }}/php.json"
39+
echo "::add-matcher::${{ runner.tool_cache }}/phpunit.json"
40+
41+
- name: Load cached dependencies
42+
id: cached-composer-dependencies
43+
uses: actions/cache@v3
44+
with:
45+
path: vendor
46+
key: vendor-${{ runner.os }}-${{ hashFiles('**/composer.lock') }}
47+
48+
- name: Install dependencies
49+
if: steps.cached-composer-dependencies.outputs.cache-hit != 'true'
50+
run: composer install
51+
52+
- name: Run coding standards task
53+
run: make cs-diff
54+
55+
- name: Execute phpunit and pest tests
56+
run: make test
57+
58+
- name: Run static analysis using phpstan
59+
run: make stan
60+
env:
61+
PHPSTAN_OUTPUT_FORMAT: github
62+
63+
...
Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
---
2+
3+
# https://github.com/google-github-actions/release-please-action#release-types-supported
4+
5+
on: # yamllint disable-line rule:truthy
6+
push:
7+
branches:
8+
- master
9+
10+
name: release-please
11+
12+
jobs:
13+
release-please:
14+
runs-on: ubuntu-latest
15+
steps:
16+
- uses: google-github-actions/release-please-action@v3
17+
id: release
18+
with:
19+
token: ${{ secrets.GITHUB_TOKEN }}
20+
release-type: node
21+
package-name: laravel-package-tpl
22+
default-branch: master
23+
changelog-types: |
24+
[
25+
{ "type": "feat", "section": "Features", "hidden": false },
26+
{ "type": "fix", "section": "Bug Fixes", "hidden": false },
27+
{ "type": "perf", "section": "Performance Improvements", "hidden": false },
28+
{ "type": "docs", "section": "Documentation", "hidden": false },
29+
{ "type": "chore", "section": "Miscellaneous", "hidden": false },
30+
{ "type": "style", "section": "Styles", "hidden": true },
31+
{ "type": "revert", "section": "Reverts", "hidden": true },
32+
{ "type": "deps", "section": "Dependencies", "hidden": true },
33+
{ "type": "refactor", "section": "Code Refactoring", "hidden": true },
34+
{ "type": "test", "section": "Tests", "hidden": true },
35+
{ "type": "build", "section": "Build System", "hidden": true },
36+
{ "type": "ci", "section": "Continuous Integration", "hidden": true }
37+
]
38+
39+
...

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
/vendor/
2+
/.build/

.php-cs-fixer.dist.php

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
<?php
2+
3+
declare(strict_types=1);
4+
5+
use WayOfDev\PhpCsFixer\Config\ConfigBuilder;
6+
use WayOfDev\PhpCsFixer\Config\RuleSets\DefaultSet;
7+
8+
require_once 'vendor/autoload.php';
9+
10+
$config = ConfigBuilder::createFromRuleSet(new DefaultSet(['static_lambda' => false]))
11+
->inDir(__DIR__ . '/src')
12+
->inDir(__DIR__ . '/tests')
13+
->addFiles([__FILE__])
14+
->getConfig()
15+
;
16+
17+
$config->setCacheFile(__DIR__ . '/.build/php-cs-fixer/php-cs-fixer.cache');
18+
19+
return $config;

.pre-commit-config.yaml

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
---
2+
3+
repos:
4+
- repo: https://github.com/pre-commit/pre-commit-hooks
5+
rev: v4.3.0
6+
hooks:
7+
- id: trailing-whitespace
8+
- id: end-of-file-fixer
9+
- id: check-added-large-files
10+
- id: fix-encoding-pragma
11+
12+
- repo: https://github.com/commitizen-tools/commitizen
13+
rev: v2.28.0
14+
hooks:
15+
- id: commitizen
16+
stages:
17+
- commit-msg
18+
19+
...

0 commit comments

Comments
 (0)