Skip to content

Commit c7dab8d

Browse files
committed
use php cs fixer
1 parent 92cb153 commit c7dab8d

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

62 files changed

+121
-121
lines changed

.github/workflows/quality.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ jobs:
1414
run: |
1515
wget -q https://cs.symfony.com/download/php-cs-fixer-v3.phar -O php-cs-fixer
1616
chmod a+x php-cs-fixer
17-
PHP_CS_FIXER_IGNORE_ENV=true ./php-cs-fixer fix src --dry-run
17+
./php-cs-fixer fix src --dry-run
1818
1919
phpstan:
2020
runs-on: ubuntu-latest

src/Action/Custom/Factory/Action.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ public function normalize(array $config): array
4444
{
4545
try {
4646
return $this->processor->processConfiguration($this->configuration, $config);
47-
} catch (Symfony\InvalidTypeException|Symfony\InvalidConfigurationException $exception) {
47+
} catch (Symfony\InvalidConfigurationException|Symfony\InvalidTypeException $exception) {
4848
throw new Configurator\InvalidConfigurationException($exception->getMessage(), 0, $exception);
4949
}
5050
}
@@ -55,7 +55,7 @@ public function validate(array $config): bool
5555
$this->processor->processConfiguration($this->configuration, $config);
5656

5757
return true;
58-
} catch (Symfony\InvalidTypeException|Symfony\InvalidConfigurationException) {
58+
} catch (Symfony\InvalidConfigurationException|Symfony\InvalidTypeException) {
5959
return false;
6060
}
6161
}

src/Action/Custom/Factory/Repository/RepositoryTrait.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ trait RepositoryTrait
1414
/** @var string[] */
1515
private array $packages;
1616

17-
public function addFiles(Packaging\FileInterface|Packaging\DirectoryInterface ...$files): Configurator\RepositoryInterface
17+
public function addFiles(Packaging\DirectoryInterface|Packaging\FileInterface ...$files): Configurator\RepositoryInterface
1818
{
1919
array_push($this->files, ...$files);
2020

src/Action/Custom/Service.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ public function normalize(array $config): array
4343
{
4444
try {
4545
return $this->processor->processConfiguration($this->configuration, $config);
46-
} catch (Symfony\InvalidTypeException|Symfony\InvalidConfigurationException $exception) {
46+
} catch (Symfony\InvalidConfigurationException|Symfony\InvalidTypeException $exception) {
4747
throw new Configurator\InvalidConfigurationException($exception->getMessage(), 0, $exception);
4848
}
4949
}
@@ -54,7 +54,7 @@ public function validate(array $config): bool
5454
$this->processor->processConfiguration($this->configuration, $config);
5555

5656
return true;
57-
} catch (Symfony\InvalidTypeException|Symfony\InvalidConfigurationException) {
57+
} catch (Symfony\InvalidConfigurationException|Symfony\InvalidTypeException) {
5858
return false;
5959
}
6060
}

src/Action/SFTP/Factory/Action.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ public function normalize(array $config): array
3939
{
4040
try {
4141
return $this->processor->processConfiguration($this->configuration, $config);
42-
} catch (Symfony\InvalidTypeException|Symfony\InvalidConfigurationException $exception) {
42+
} catch (Symfony\InvalidConfigurationException|Symfony\InvalidTypeException $exception) {
4343
throw new Configurator\InvalidConfigurationException($exception->getMessage(), 0, $exception);
4444
}
4545
}
@@ -50,7 +50,7 @@ public function validate(array $config): bool
5050
$this->normalize($config);
5151

5252
return true;
53-
} catch (Symfony\InvalidTypeException|Symfony\InvalidConfigurationException) {
53+
} catch (Symfony\InvalidConfigurationException|Symfony\InvalidTypeException) {
5454
return false;
5555
}
5656
}
@@ -68,7 +68,7 @@ public function compile(array $config): Repository
6868

6969
try {
7070
return new Repository($builder);
71-
} catch (Symfony\InvalidTypeException|Symfony\InvalidConfigurationException $exception) {
71+
} catch (Symfony\InvalidConfigurationException|Symfony\InvalidTypeException $exception) {
7272
throw new Configurator\InvalidConfigurationException(message: $exception->getMessage(), previous: $exception);
7373
}
7474
}

src/Action/SFTP/Factory/Repository/Repository.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
{
1313
public function __construct(private Builder\Action $builder) {}
1414

15-
public function addFiles(Packaging\FileInterface|Packaging\DirectoryInterface ...$files): self
15+
public function addFiles(Packaging\DirectoryInterface|Packaging\FileInterface ...$files): self
1616
{
1717
return $this;
1818
}

src/Action/SFTP/Service.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ public function normalize(array $config): array
4545
{
4646
try {
4747
return $this->processor->processConfiguration($this->configuration, $config);
48-
} catch (Symfony\InvalidTypeException|Symfony\InvalidConfigurationException $exception) {
48+
} catch (Symfony\InvalidConfigurationException|Symfony\InvalidTypeException $exception) {
4949
throw new Configurator\InvalidConfigurationException($exception->getMessage(), 0, $exception);
5050
}
5151
}
@@ -56,7 +56,7 @@ public function validate(array $config): bool
5656
$this->processor->processConfiguration($this->configuration, $config);
5757

5858
return true;
59-
} catch (Symfony\InvalidTypeException|Symfony\InvalidConfigurationException) {
59+
} catch (Symfony\InvalidConfigurationException|Symfony\InvalidTypeException) {
6060
return false;
6161
}
6262
}

src/Adapter/Docker/Satellite.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ final class Satellite implements Configurator\SatelliteInterface
2222
public function __construct(
2323
private readonly Dockerfile\Dockerfile $dockerfile,
2424
private readonly string $workdir,
25-
Packaging\FileInterface|Packaging\DirectoryInterface ...$files
25+
Packaging\DirectoryInterface|Packaging\FileInterface ...$files
2626
) {
2727
$this->files = $files;
2828
}
@@ -34,7 +34,7 @@ public function addTags(string ...$imageTags): self
3434
return $this;
3535
}
3636

37-
public function withFile(Packaging\FileInterface|Packaging\DirectoryInterface ...$files): self
37+
public function withFile(Packaging\DirectoryInterface|Packaging\FileInterface ...$files): self
3838
{
3939
array_push($this->files, ...$files);
4040

src/Adapter/Docker/SatelliteBuilder.php

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,8 @@ final class SatelliteBuilder implements Configurator\SatelliteBuilderInterface
2323
private iterable $command = [];
2424
/** @var iterable<string> */
2525
private iterable $tags = [];
26-
private null|PackagingContract\FileInterface|PackagingContract\AssetInterface $composerJsonFile = null;
27-
private null|PackagingContract\FileInterface|PackagingContract\AssetInterface $composerLockFile = null;
26+
private null|PackagingContract\AssetInterface|PackagingContract\FileInterface $composerJsonFile = null;
27+
private null|PackagingContract\AssetInterface|PackagingContract\FileInterface $composerLockFile = null;
2828
/** @var iterable<array<string, string>> */
2929
private iterable $paths = [];
3030
/** @var \AppendIterator<string,PackagingContract\FileInterface, \Iterator<string,PackagingContract\FileInterface>> */
@@ -66,8 +66,8 @@ public function withComposerRequire(string ...$package): self
6666
}
6767

6868
public function withComposerFile(
69-
PackagingContract\FileInterface|PackagingContract\AssetInterface $composerJsonFile,
70-
PackagingContract\FileInterface|PackagingContract\AssetInterface $composerLockFile = null
69+
PackagingContract\AssetInterface|PackagingContract\FileInterface $composerJsonFile,
70+
PackagingContract\AssetInterface|PackagingContract\FileInterface $composerLockFile = null
7171
): self {
7272
$this->composerJsonFile = $composerJsonFile;
7373
$this->composerLockFile = $composerLockFile;
@@ -76,7 +76,7 @@ public function withComposerFile(
7676
}
7777

7878
public function withFile(
79-
PackagingContract\FileInterface|PackagingContract\AssetInterface $source,
79+
PackagingContract\AssetInterface|PackagingContract\FileInterface $source,
8080
string $destinationPath = null
8181
): self {
8282
if (!$source instanceof PackagingContract\FileInterface) {

src/Adapter/Filesystem/Satellite.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,12 +18,12 @@ final class Satellite implements Configurator\SatelliteInterface
1818
public function __construct(
1919
private readonly string $workdir,
2020
private readonly Composer $composer,
21-
Packaging\FileInterface|Packaging\DirectoryInterface ...$files
21+
Packaging\DirectoryInterface|Packaging\FileInterface ...$files
2222
) {
2323
$this->files = $files;
2424
}
2525

26-
public function withFile(Packaging\FileInterface|Packaging\DirectoryInterface ...$files): self
26+
public function withFile(Packaging\DirectoryInterface|Packaging\FileInterface ...$files): self
2727
{
2828
array_push($this->files, ...$files);
2929

0 commit comments

Comments
 (0)