Skip to content

Commit

Permalink
Test Symfony 7 branch
Browse files Browse the repository at this point in the history
  • Loading branch information
alexander-schranz committed Jul 16, 2024
1 parent 8e2bd9a commit 1964ff1
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 7 deletions.
4 changes: 2 additions & 2 deletions Command/ArticleExportCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -35,15 +35,15 @@ public function __construct(ArticleExportInterface $articleExporter)
$this->articleExporter = $articleExporter;
}

protected function configure()
protected function configure(): void
{
$this->addArgument('target', InputArgument::REQUIRED, 'export.xliff')
->addArgument('locale', InputArgument::REQUIRED)
->addOption('format', 'f', InputOption::VALUE_REQUIRED, '', '1.2.xliff')
->setDescription('Export article translations from given language into xliff file for translating into a new language.');
}

protected function execute(InputInterface $input, OutputInterface $output)
protected function execute(InputInterface $input, OutputInterface $output): int
{
$target = $input->getArgument('target');
if (0 === !\strpos($target, '/')) {
Expand Down
4 changes: 2 additions & 2 deletions Command/ArticleImportCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ public function __construct(ArticleImportInterface $articleImporter, ?LoggerInte
$this->logger = $logger ?: new NullLogger();
}

protected function configure()
protected function configure(): void
{
$this->addArgument('file', InputArgument::REQUIRED, 'export.xliff')
->addArgument('locale', InputArgument::REQUIRED)
Expand All @@ -55,7 +55,7 @@ protected function configure()
->setDescription('Import article translations from xliff file into a specific language.');
}

protected function execute(InputInterface $input, OutputInterface $output)
protected function execute(InputInterface $input, OutputInterface $output): int
{
$filePath = $input->getArgument('file');
if (0 === !\strpos($filePath, '/')) {
Expand Down
4 changes: 2 additions & 2 deletions Command/ReindexCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -77,15 +77,15 @@ public function __construct(
$this->suluContext = $suluContext;
}

public function configure()
public function configure(): void
{
$this->setDescription('Rebuild elastic-search index for articles');
$this->setHelp('This command will load all articles and index them to elastic-search indexes.');
$this->addOption('drop', null, InputOption::VALUE_NONE, 'Drop and recreate index before reindex');
$this->addOption('clear', null, InputOption::VALUE_NONE, 'Clear all articles of index before reindex');
}

protected function execute(InputInterface $input, OutputInterface $output)
protected function execute(InputInterface $input, OutputInterface $output): int
{
$startTime = \microtime(true);

Expand Down
8 changes: 7 additions & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,17 @@
"homepage": "https://github.com/sulu/SuluArticleBundle/contributors"
}
],
"repositories": [
{
"type": "vcs",
"url": "[email protected]:alexander-schranz/ElasticsearchBundle.git"
}
],
"require": {
"php": "^7.3 || ^8.0",
"ext-json": "*",
"elasticsearch/elasticsearch": "^5.0 || ^6.0 || ^7.0",
"handcraftedinthealps/elasticsearch-bundle": "^5.2.6.4",
"handcraftedinthealps/elasticsearch-bundle": "dev-feature/symfony-7-upgrade as 5.999",
"handcraftedinthealps/elasticsearch-dsl": "^5.0.7.1 || ^6.2.0.1 || ^7.2.0.1",
"jms/serializer": "^3.3",
"jms/serializer-bundle": "^3.3 || ^4.0 || ^5.0",
Expand Down

0 comments on commit 1964ff1

Please sign in to comment.