Skip to content
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
7 changes: 7 additions & 0 deletions .docker/php/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,13 @@ RUN apk update && apk add \
RUN ln -s /usr/share/zoneinfo/Europe/Paris /etc/localtime \
&& sed -i "s/^;date.timezone =.*/date.timezone = Europe\/Paris/" $PHP_INI_DIR/php.ini

# pcov, to measure the coverage as the CI (built from its tarball: PECL downloads are unreliable)
RUN apk add --no-cache --virtual .build-deps $PHPIZE_DEPS linux-headers \
&& curl -sSL https://github.com/krakjoe/pcov/archive/refs/tags/v1.0.12.tar.gz | tar xz -C /tmp \
&& cd /tmp/pcov-1.0.12 && phpize && ./configure && make -j"$(nproc)" && make install \
&& docker-php-ext-enable pcov \
&& cd / && rm -rf /tmp/pcov-1.0.12 && apk del .build-deps

COPY --from=composer:2 /usr/bin/composer /usr/bin/composer

RUN usermod -u $UID www-data \
Expand Down
1 change: 1 addition & 0 deletions .github/ISSUE_TEMPLATE/bug.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@ Tested on `main` (`<commit>`), cleverage/process-bundle x.y, PHP x.y, Symfony x.

* Documentation updates
- [ ] Reference
- [ ] Cookbooks
- [ ] Changelog
* [ ] Unit tests

Expand Down
7 changes: 7 additions & 0 deletions .github/ISSUE_TEMPLATE/config.yml
Original file line number Diff line number Diff line change
@@ -1 +1,8 @@
blank_issues_enabled: true
contact_links:
- name: Security vulnerability
url: https://github.com/cleverage/flysystem-process-bundle/security/advisories/new
about: Report a security vulnerability privately, never in a public issue.
- name: Documentation
url: https://github.com/cleverage/flysystem-process-bundle/blob/main/docs/index.md
about: How to install and use the bundle.
1 change: 1 addition & 0 deletions .github/ISSUE_TEMPLATE/issue.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ assignees: ''

* Documentation updates
- [ ] Reference
- [ ] Cookbooks
- [ ] Changelog
* [ ] Unit tests

Expand Down
1 change: 1 addition & 0 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@

* Documentation updates
- [ ] Reference
- [ ] Cookbooks
- [ ] Changelog
* [ ] Unit tests

Expand Down
8 changes: 4 additions & 4 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
# See https://docs.github.com/en/code-security/dependabot/working-with-dependabot/keeping-your-actions-up-to-date-with-dependabot
version: 2
updates:
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "weekly"
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "weekly"
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,5 @@
.phpunit.result.cache
.phpunit.cache
.php-cs-fixer.cache
/.php-cs-fixer.php
coverage-report
2 changes: 1 addition & 1 deletion .php-cs-fixer.dist.php
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
return (new PhpCsFixer\Config())
->setRules([
'@PHP8x2Migration' => true,
'@PHPUnit7x5Migration:risky' => true,
'@PHPUnit10x0Migration:risky' => true,
'@Symfony' => true,
'@Symfony:risky' => true,
'protected_to_private' => false,
Expand Down
12 changes: 7 additions & 5 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,11 +50,13 @@ configured accordingly.

## Deprecations notices

When a feature should be deprecated, or when you have a breaking change for a future version, please :
When a feature should be deprecated, or when you have a breaking change for a future version, please:
* [Fill an issue](https://github.com/cleverage/flysystem-process-bundle/issues/new)
* Add TODO comments with the following format: `@TODO deprecated v2.0`
* Trigger a deprecation error: `@trigger_error('This feature will be deprecated in v2.0', E_USER_DEPRECATED);`
* Trigger a deprecation notice with `trigger_deprecation('cleverage/flysystem-process-bundle', '<version>', '...')`
(`symfony/deprecation-contracts`), `<version>` being the next minor version, and add a `@deprecated` tag stating
the version of the removal (the next major version)
* Describe the deprecation in the CHANGELOG and in `UPGRADE.md`

You can check which deprecation notice is triggered in tests
The tests fail on any deprecation notice (`failOnDeprecation` in `phpunit.xml.dist`):
* `make bash`
* `SYMFONY_DEPRECATIONS_HELPER=0 ./vendor/bin/phpunit`
* `vendor/bin/phpunit`
10 changes: 6 additions & 4 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,22 +1,24 @@
.ONESHELL:
SHELL := /bin/bash

.PHONY: start upd up stop down build ps bash logs quality phpstan php-cs-fixer rector tests phpunit

DOCKER_RUN_PHP = docker compose -f .docker/compose.yaml run --rm php "bash" "-c"
DOCKER_COMPOSE = docker compose -f .docker/compose.yaml

start: upd #[Global] Start application

src/vendor: #[Composer] install dependencies
vendor: composer.json #[Composer] Install dependencies (again when composer.json changes)
$(DOCKER_RUN_PHP) "composer install --no-interaction"

upd: #[Docker] Start containers detached
touch .docker/.env
make src/vendor
$(MAKE) vendor
$(DOCKER_COMPOSE) up --remove-orphans --detach

up: #[Docker] Start containers
touch .docker/.env
make src/vendor
$(MAKE) vendor
$(DOCKER_COMPOSE) up --remove-orphans

stop: #[Docker] Down containers
Expand All @@ -31,7 +33,7 @@ build: #[Docker] Build containers
ps: # [Docker] Show running containers
$(DOCKER_COMPOSE) ps

bash: #[Docker] Connect to php container with current host user
bash: upd #[Docker] Connect to php container with current host user
$(DOCKER_COMPOSE) exec php bash

logs: #[Docker] Show logs
Expand Down
16 changes: 16 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,27 @@
CleverAge/FlysystemProcessBundle
=======================

[![Test](https://github.com/cleverage/flysystem-process-bundle/actions/workflows/test.yml/badge.svg)](https://github.com/cleverage/flysystem-process-bundle/actions/workflows/test.yml)
[![Packagist Version](https://img.shields.io/packagist/v/cleverage/flysystem-process-bundle)](https://packagist.org/packages/cleverage/flysystem-process-bundle)
[![License](https://img.shields.io/packagist/l/cleverage/flysystem-process-bundle)](LICENSE)

This bundle is a part of the [CleverAge/ProcessBundle](https://github.com/cleverage/process-bundle) project.
It provides [Flysystem](https://flysystem.thephpleague.com/docs/) library integration on Process bundle.

Compatible with [Symfony stable version and latest Long-Term Support (LTS) release](https://symfony.com/releases).

## Installation

```bash
composer require cleverage/flysystem-process-bundle
```

Without Symfony Flex, register the bundle in `config/bundles.php`:

```php
CleverAge\FlysystemProcessBundle\CleverAgeFlysystemProcessBundle::class => ['all' => true],
```

## Documentation

For usage documentation, see:
Expand Down
9 changes: 7 additions & 2 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,12 @@
"role": "Maintainer"
}
],
"support": {
"issues": "https://github.com/cleverage/flysystem-process-bundle/issues",
"source": "https://github.com/cleverage/flysystem-process-bundle",
"docs": "https://github.com/cleverage/flysystem-process-bundle/blob/main/docs/index.md",
"security": "https://github.com/cleverage/flysystem-process-bundle/security/policy"
},
"autoload": {
"psr-4": {
"CleverAge\\FlysystemProcessBundle\\": "src/"
Expand Down Expand Up @@ -73,8 +79,7 @@
},
"config": {
"allow-plugins": {
"phpstan/extension-installer": true,
"symfony/runtime": true
"phpstan/extension-installer": true
},
"sort-packages": true
}
Expand Down
3 changes: 0 additions & 3 deletions tests/Functional/KernelTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -58,9 +58,6 @@ public function testTasksAndStorageAreRegistered(): void

public function testTasksAreResolvedByCode(): void
{
if (!class_exists(TaskRegistry::class)) {
self::markTestSkipped('The tasks are referenced by code since cleverage/process-bundle 5.4.');
}
$processConfigurationRegistry = self::getContainer()->get('test.process_configuration_registry');
self::assertInstanceOf(ProcessConfigurationRegistry::class, $processConfigurationRegistry);
$taskRegistry = self::getContainer()->get('test.task_registry');
Expand Down
Loading