generator-razor 14.0.30 → 14.0.32
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/app/index.js
CHANGED
|
@@ -432,33 +432,35 @@ export default class extends Generator {
|
|
|
432
432
|
'typo3/sysext/core/bin/typo3'
|
|
433
433
|
)
|
|
434
434
|
|
|
435
|
+
const cwd = this.destinationRoot()
|
|
436
|
+
|
|
435
437
|
this.log('→ Activating razor bootstrap...')
|
|
436
438
|
|
|
437
|
-
|
|
439
|
+
this.spawnCommandSync(
|
|
438
440
|
typo3,
|
|
439
441
|
['extension:activate', 'razorbootstrap'],
|
|
440
442
|
{
|
|
441
|
-
cwd
|
|
443
|
+
cwd
|
|
442
444
|
}
|
|
443
445
|
)
|
|
444
446
|
|
|
445
447
|
this.log('→ Updating TER extension list...')
|
|
446
448
|
|
|
447
|
-
|
|
449
|
+
this.spawnCommandSync(
|
|
448
450
|
typo3,
|
|
449
451
|
['razorbootstrap:ter:update'],
|
|
450
452
|
{
|
|
451
|
-
cwd
|
|
453
|
+
cwd
|
|
452
454
|
}
|
|
453
455
|
)
|
|
454
456
|
|
|
455
457
|
this.log('→ Removing razor bootstrap...')
|
|
456
458
|
|
|
457
|
-
|
|
459
|
+
this.spawnCommandSync(
|
|
458
460
|
typo3,
|
|
459
461
|
['extension:deactivate', 'razorbootstrap'],
|
|
460
462
|
{
|
|
461
|
-
cwd
|
|
463
|
+
cwd
|
|
462
464
|
}
|
|
463
465
|
)
|
|
464
466
|
|
|
@@ -468,21 +470,25 @@ export default class extends Generator {
|
|
|
468
470
|
|
|
469
471
|
this.log('→ Flushing TYPO3 caches...')
|
|
470
472
|
|
|
471
|
-
await
|
|
473
|
+
await fs.remove(
|
|
474
|
+
this.destinationPath('typo3temp/var/cache')
|
|
475
|
+
)
|
|
476
|
+
|
|
477
|
+
this.spawnCommandSync(
|
|
472
478
|
typo3,
|
|
473
479
|
['cache:flush'],
|
|
474
480
|
{
|
|
475
|
-
cwd
|
|
481
|
+
cwd
|
|
476
482
|
}
|
|
477
483
|
)
|
|
478
484
|
|
|
479
485
|
this.log('→ Activating razor...')
|
|
480
486
|
|
|
481
|
-
|
|
487
|
+
this.spawnCommandSync(
|
|
482
488
|
typo3,
|
|
483
489
|
['extension:activate', 'razor'],
|
|
484
490
|
{
|
|
485
|
-
cwd
|
|
491
|
+
cwd
|
|
486
492
|
}
|
|
487
493
|
)
|
|
488
494
|
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
<?php
|
|
2
|
+
|
|
3
|
+
declare(strict_types=1);
|
|
4
|
+
|
|
5
|
+
/*
|
|
6
|
+
* This file is part of the TYPO3 CMS project.
|
|
7
|
+
*
|
|
8
|
+
* It is free software; you can redistribute it and/or modify it under
|
|
9
|
+
* the terms of the GNU General Public License, either version 2
|
|
10
|
+
* of the License, or any later version.
|
|
11
|
+
*
|
|
12
|
+
* For the full copyright and license information, please read the
|
|
13
|
+
* LICENSE.txt file that was distributed with this source code.
|
|
14
|
+
*
|
|
15
|
+
* The TYPO3 project - inspiring people to share!
|
|
16
|
+
*/
|
|
17
|
+
|
|
18
|
+
namespace RZ\Razorbootstrap\Command;
|
|
19
|
+
|
|
20
|
+
use Symfony\Component\Console\Attribute\AsCommand;
|
|
21
|
+
use Symfony\Component\Console\Command\Command;
|
|
22
|
+
use Symfony\Component\Console\Input\InputInterface;
|
|
23
|
+
use Symfony\Component\Console\Output\OutputInterface;
|
|
24
|
+
use Symfony\Component\Console\Style\SymfonyStyle;
|
|
25
|
+
use TYPO3\CMS\Core\Attribute\AsNonSchedulableCommand;
|
|
26
|
+
use TYPO3\CMS\Extensionmanager\Exception\ExtensionManagerException;
|
|
27
|
+
use TYPO3\CMS\Extensionmanager\Remote\RemoteRegistry;
|
|
28
|
+
|
|
29
|
+
#[AsCommand(
|
|
30
|
+
name: 'razorbootstrap:ter:update',
|
|
31
|
+
description: 'Updates the TYPO3 Extension Repository extension list'
|
|
32
|
+
)]
|
|
33
|
+
#[AsNonSchedulableCommand]
|
|
34
|
+
final class UpdateTerCommand extends Command
|
|
35
|
+
{
|
|
36
|
+
public function __construct(
|
|
37
|
+
private readonly RemoteRegistry $remoteRegistry
|
|
38
|
+
) {
|
|
39
|
+
parent::__construct();
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
protected function execute(
|
|
43
|
+
InputInterface $input,
|
|
44
|
+
OutputInterface $output
|
|
45
|
+
): int {
|
|
46
|
+
$io = new SymfonyStyle($input, $output);
|
|
47
|
+
|
|
48
|
+
$io->text('Updating TER extension list...');
|
|
49
|
+
|
|
50
|
+
try {
|
|
51
|
+
foreach ($this->remoteRegistry->getListableRemotes() as $remote) {
|
|
52
|
+
$remote->getAvailablePackages(true);
|
|
53
|
+
}
|
|
54
|
+
} catch (ExtensionManagerException $exception) {
|
|
55
|
+
$io->error($exception->getMessage());
|
|
56
|
+
|
|
57
|
+
return Command::FAILURE;
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
$io->success('TER extension list successfully updated.');
|
|
61
|
+
|
|
62
|
+
return Command::SUCCESS;
|
|
63
|
+
}
|
|
64
|
+
}
|