Skip to content

Commit 0b52e5b

Browse files
committed
init
0 parents  commit 0b52e5b

19 files changed

+11061
-0
lines changed

.gitignore

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
vendor/
2+
coverage/
3+
phpunit.xml
4+
.phpunit.cache
5+
.phpcs-cache
6+
phpstan.neon

LICENSE

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
The MIT License (MIT)
2+
3+
Copyright (c) 2020 Daniel Badura & David Badura
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.

Makefile

Lines changed: 73 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,73 @@
1+
help: ## shows this help
2+
@awk 'BEGIN {FS = ":.*?## "} /^[a-zA-Z_\-\.]+:.*?## / {printf "\033[36m%-30s\033[0m %s\n", $$1, $$2}' $(MAKEFILE_LIST)
3+
4+
vendor: composer.lock
5+
composer install
6+
7+
.PHONY: phpcs-check
8+
phpcs-check: vendor ## run phpcs
9+
vendor/bin/phpcs
10+
11+
.PHONY: phpcs-fix
12+
cs: vendor ## run phpcs fixer
13+
vendor/bin/phpcbf
14+
15+
.PHONY: phpstan
16+
phpstan: vendor ## run phpstan static code analyser
17+
vendor/bin/phpstan analyse
18+
19+
.PHONY: phpstan-baseline
20+
phpstan-baseline: vendor ## run phpstan static code analyser
21+
vendor/bin/phpstan analyse --generate-baseline
22+
23+
.PHONY: psalm
24+
psalm: vendor ## run psalm static code analyser
25+
vendor/bin/psalm
26+
27+
.PHONY: psalm-baseline
28+
psalm-baseline: vendor ## run psalm static code analyser
29+
vendor/bin/psalm --update-baseline --set-baseline=baseline.xml
30+
31+
32+
.PHONY: phpunit
33+
phpunit: vendor ## run phpunit tests
34+
XDEBUG_MODE=coverage vendor/bin/phpunit
35+
36+
.PHONY: static
37+
static: psalm phpstan phpcs-check ## run static analyser
38+
39+
test: phpunit ## run tests
40+
41+
.PHONY: dev
42+
dev: static test ## run dev tools
43+
44+
.PHONY: docs
45+
docs: mkdocs ## run mkdocs
46+
cd docs && python3 -m mkdocs serve
47+
48+
.PHONY: mkdocs
49+
mkdocs: ## run mkdocs
50+
cd docs && pip3 install -r requirements.txt
51+
52+
.PHONY: docs-extract-php
53+
docs-extract-php:
54+
bin/docs-extract-php-code
55+
56+
.PHONY: docs-inject-php
57+
docs-inject-php:
58+
bin/docs-inject-php-code
59+
60+
.PHONY: docs-format
61+
docs-format: docs-phpcs docs-inject-php
62+
63+
.PHONY: docs-php-lint
64+
docs-php-lint: docs-extract-php
65+
php -l docs_php/*.php
66+
67+
.PHONY: docs-phpcs
68+
docs-phpcs: docs-extract-php
69+
vendor/bin/phpcbf docs_php --exclude=SlevomatCodingStandard.TypeHints.DeclareStrictTypes || true
70+
71+
.PHONY: docs-psalm
72+
docs-psalm: docs-extract-php
73+
vendor/bin/psalm --config=psalm_docs.xml

README.md

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
[![Type Coverage](https://shepherd.dev/github/patchlevel/event-sourcing-bundle/coverage.svg)](https://shepherd.dev/github/patchlevel/event-sourcing-bundle)
2+
[![Latest Stable Version](https://poser.pugx.org/patchlevel/event-sourcing-bundle/v)](//packagist.org/packages/patchlevel/event-sourcing-bundle)
3+
[![License](https://poser.pugx.org/patchlevel/event-sourcing-bundle/license)](//packagist.org/packages/patchlevel/event-sourcing-bundle)
4+
5+
# Event-Sourcing-Bundle
6+
7+
An event sourcing bundle, complete with all the essential features,
8+
powered by the reliable Doctrine ecosystem and focused on developer experience.
9+
This bundle is a [symfony](https://symfony.com/) integration
10+
for [event-sourcing](https://github.com/patchlevel/event-sourcing) library.
11+
12+
## Features
13+
14+
* Everything is included in the package for event sourcing
15+
* Based on [doctrine dbal](https://github.com/doctrine/dbal) and their ecosystem
16+
* Developer experience oriented and fully typed
17+
* Automatic [snapshot](https://patchlevel.github.io/event-sourcing-docs/latest/snapshots/)-system to boost your performance
18+
* [Split](https://patchlevel.github.io/event-sourcing-docs/latest/split_stream/) big aggregates into multiple streams
19+
* Versioned and managed lifecycle of [subscriptions](https://patchlevel.github.io/event-sourcing-docs/latest/subscription/) like projections and processors
20+
* Safe usage of [Personal Data](https://patchlevel.github.io/event-sourcing-docs/latest/personal_data/) with crypto-shredding
21+
* Smooth [upcasting](https://patchlevel.github.io/event-sourcing-docs/latest/upcasting/) of old events
22+
* Simple setup with [scheme management](https://patchlevel.github.io/event-sourcing-docs/latest/store/) and [doctrine migration](https://patchlevel.github.io/event-sourcing-docs/latest/store/)
23+
* Built in [cli commands](https://patchlevel.github.io/event-sourcing-docs/latest/cli/) with [symfony](https://symfony.com/)
24+
* and much more...
25+
26+
## Installation
27+
28+
```bash
29+
composer require patchlevel/event-sourcing-bundle
30+
```
31+
32+
> [!WARNING]
33+
> If you don't use the symfony flex recipe for this bundle, you need to follow
34+
this [installation documentation](https://patchlevel.github.io/event-sourcing-bundle-docs/latest/installation/).
35+
36+
## Documentation
37+
38+
* [Bundle Documentation](https://patchlevel.github.io/event-sourcing-bundle-docs/latest/)
39+
* [Library Documentation](https://patchlevel.github.io/event-sourcing-docs/latest)
40+
* [Related Blog](https://patchlevel.de/blog)
41+
42+
## Integration
43+
44+
* [Psalm](https://github.com/patchlevel/event-sourcing-psalm-plugin)
45+
46+
## Sponsors
47+
48+
[<img src="https://github.com/patchlevel/event-sourcing/assets/470138/d00b7459-23b7-431b-80b4-93cfc1b66216" alt="blackfire" width="200">](https://www.blackfire.io)

baseline.xml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<files psalm-version="5.12.0@f90118cdeacd0088e7215e64c0c99ceca819e176">
3+
</files>

composer.json

Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
{
2+
"name": "patchlevel/laravel-event-sourcing",
3+
"license": "MIT",
4+
"description": "laravel package for patchlevel/event-sourcing",
5+
"keywords": [
6+
"event-sourcing"
7+
],
8+
"homepage": "https://github.com/patchlevel/laravel-event-sourcing",
9+
"authors": [
10+
{
11+
"name": "Daniel Badura",
12+
"email": "daniel.badura@patchlevel.de"
13+
},
14+
{
15+
"name": "David Badura",
16+
"email": "david.badura@patchlevel.de"
17+
}
18+
],
19+
"require": {
20+
"php": "~8.1.0 || ~8.2.0 || ~8.3.0",
21+
"patchlevel/event-sourcing": "3.5.x-dev",
22+
"illuminate/contracts": "^9.28|^10.0|^11.0"
23+
},
24+
"require-dev": {
25+
"ext-pdo_sqlite": "*"
26+
},
27+
"config": {
28+
"preferred-install": {
29+
"*": "dist"
30+
},
31+
"sort-packages": true,
32+
"allow-plugins": {
33+
"composer/package-versions-deprecated": true,
34+
"dealerdirect/phpcodesniffer-composer-installer": true,
35+
"infection/extension-installer": true
36+
}
37+
},
38+
"autoload": {
39+
"psr-4": {
40+
"Patchlevel\\LaravelEventSourcing\\": "src/"
41+
}
42+
},
43+
"autoload-dev": {
44+
"psr-4": {
45+
"Patchlevel\\LaravelEventSourcing\\Tests\\": "tests/"
46+
}
47+
},
48+
"prefer-stable": true,
49+
"extra": {
50+
"laravel": {
51+
"providers": [
52+
"Patchlevel\\LaravelEventSourcing\\EventSourcingServiceProvider"
53+
]
54+
}
55+
}
56+
}

0 commit comments

Comments
 (0)