feat : numéro de version et config CI/CD
Some checks failed
Auto Tag Develop / tag (push) Failing after 4s

This commit is contained in:
2026-02-09 15:40:14 +01:00
parent c1025d6066
commit 31c0ae15f4
14 changed files with 295 additions and 51 deletions

View File

@@ -0,0 +1,26 @@
<?php
declare(strict_types=1);
namespace App\State;
use ApiPlatform\Metadata\Operation;
use ApiPlatform\State\ProviderInterface;
use App\ApiResource\AppVersion;
use Symfony\Component\DependencyInjection\Attribute\Autowire;
final readonly class AppVersionProvider implements ProviderInterface
{
public function __construct(
#[Autowire('%app.version%')]
private string $version,
) {}
public function provide(Operation $operation, array $uriVariables = [], array $context = []): AppVersion
{
$dto = new AppVersion();
$dto->version = $this->version;
return $dto;
}
}