-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(init): This is where it all begins...
chore(readme): Add badges
- Loading branch information
Kacper Pruszynski
committed
Mar 10, 2024
0 parents
commit f249027
Showing
38 changed files
with
12,234 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
name: Coverage | ||
|
||
on: | ||
push: | ||
branches: | ||
- master | ||
|
||
jobs: | ||
coverage: | ||
name: "Generate code coverage" | ||
runs-on: ubuntu-latest | ||
permissions: | ||
contents: write | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
- name: Setup PHP | ||
uses: shivammathur/setup-php@v2 | ||
with: | ||
php-version: 8.2 | ||
- name: Build package | ||
run: composer install --no-interaction --no-progress | ||
- name: PHPUnit | ||
run: ./vendor/bin/phpunit tests --coverage-clover clover.xml | ||
- name: Generate Badge | ||
uses: timkrase/phpunit-coverage-badge@v1.2.1 | ||
with: | ||
coverage_badge_path: output/coverage.svg | ||
push_badge: false | ||
|
||
- name: Push Badge | ||
uses: peaceiris/actions-gh-pages@v3 | ||
with: | ||
publish_dir: ./output | ||
publish_branch: image-data | ||
github_token: ${{ secrets.GITHUB_TOKEN }} | ||
user_name: 'github-actions[bot]' | ||
user_email: 'github-actions[bot]@users.noreply.github.com' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
name: Quality Check | ||
|
||
on: | ||
pull_request: | ||
branches: | ||
- '**' | ||
push: | ||
branches: | ||
- master | ||
|
||
jobs: | ||
checks: | ||
name: "Pass code along quality checks" | ||
strategy: | ||
matrix: | ||
version: | ||
- '8.1' | ||
- '8.2' | ||
- '8.3' | ||
os: | ||
- ubuntu-latest | ||
- windows-latest | ||
runs-on: ${{ matrix.os }} | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
- name: Setup PHP | ||
uses: shivammathur/setup-php@v2 | ||
with: | ||
php-version: ${{ matrix.version }} | ||
extensions: fileinfo | ||
- name: Build package | ||
run: composer install --no-interaction --no-progress | ||
- name: Code Style Linter | ||
run: ./vendor/bin/phpcs --standard=phpcs.xml --colors -sp | ||
- name: PHPStan | ||
run: ./vendor/bin/phpstan analyse --no-progress --configuration=phpstan.neon | ||
- name: PHPUnit | ||
run: ./vendor/bin/phpunit tests |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
name: Release | ||
|
||
on: | ||
workflow_run: | ||
workflows: ["Quality Check"] | ||
types: [completed] | ||
branches: | ||
- 'master' | ||
|
||
|
||
jobs: | ||
release: | ||
if: ${{ github.event.workflow_run.conclusion == 'success' }} | ||
runs-on: ubuntu-latest | ||
permissions: | ||
contents: write | ||
name: "Release new package version" | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
- name: Publish Tag | ||
id: semantic | ||
uses: cycjimmy/semantic-release-action@v4 | ||
with: | ||
extra_plugins: | | ||
@semantic-release/commit-analyzer | ||
@semantic-release/release-notes-generator | ||
@semantic-release/changelog | ||
@semantic-release/git | ||
env: | ||
GITHUB_TOKEN: ${{ github.token }} | ||
- name: Publish release | ||
if: steps.semantic.outputs.new_release_published == 'true' | ||
uses: ncipollo/release-action@v1 | ||
with: | ||
name: ${{ steps.semantic.outputs.new_release_version }} | ||
body: ${{ steps.semantic.outputs.new_release_notes }} | ||
tag: ${{ steps.semantic.outputs.new_release_git_tag }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
.DS_Store | ||
vendor | ||
.phpcs.cache | ||
.phpunit.cache | ||
clover.xml |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Oops, something went wrong.