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
3 changes: 2 additions & 1 deletion installer/Application/Common/resources/app.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
// settings for you.

\mb_internal_encoding('UTF-8');
\error_reporting((E_ALL | E_STRICT) ^ E_DEPRECATED);
\error_reporting(E_ALL ^ E_DEPRECATED);
\ini_set('display_errors', 'stderr');

// Register Composer's auto loader.
Expand All @@ -21,6 +21,7 @@
// Initialize shared container, bindings, directories and etc.
$options = new Options();
$options->allowSingletonsRebinding = false;
$options->validateArguments = false;
$container = new Container(options: $options);
$app = Kernel::create(
directories: ['root' => __DIR__],
Expand Down
8 changes: 8 additions & 0 deletions installer/Application/Web/Generator/Env.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,14 @@ final class Env implements GeneratorInterface
{
public function process(Context $context): void
{
$context->envConfigurator->addGroup(
values: [
'VIEW_CACHE' => false,
],
comment: 'View component options',
priority: 9,
);

$context->envConfigurator->addGroup(
values: [
'SESSION_LIFETIME' => 86400,
Expand Down
2 changes: 1 addition & 1 deletion installer/Application/Web/Generator/ViewRenderer.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ public function process(Context $context): void

if ($this->isTemplateEngineInstalled($context->application)) {
$context->resource->copy(
\dirname(__DIR__) . '/Generator/resources/ViewRenderer.php',
__DIR__ . '/resources/ViewRenderer.php',
self::TARGET_PATH,
);
$context->exceptionHandlerBootloader->addBinding(RendererInterface::class, Renderer::class);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
use App\Application\Bootloader\AppBootloader;
use Installer\Internal\ClassMetadataInterface;
use Installer\Internal\ReflectionClassMetadata;
use Spiral\Core\CoreInterface;
use Spiral\Interceptors\HandlerInterface;
use Spiral\Reactor\Writer;

final class DomainInterceptorsConfigurator extends BootloaderConfigurator
Expand All @@ -18,7 +18,7 @@ public function __construct(
) {
parent::__construct($class, $writer);

$this->append('SINGLETONS', new ClassMethodBinding(CoreInterface::class, 'domainCore'));
$this->append('SINGLETONS', new ClassMethodBinding(HandlerInterface::class, 'domainCore'));
}

public function addInterceptor(string $class): void
Expand Down
2 changes: 1 addition & 1 deletion installer/Module/CycleBridge/resources/config/cycle.php
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@
// ],
],

'warmup' => env('CYCLE_SCHEMA_WARMUP', false),
'warmup' => env('RR_MODE') === null ? false : env('CYCLE_SCHEMA_WARMUP', false),

/**
* Custom relation types for entities
Expand Down
4 changes: 3 additions & 1 deletion installer/Module/CycleBridge/resources/config/migration.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

declare(strict_types=1);

use Spiral\Boot\Environment\AppEnvironment;

/**
* Migrations configuration.
*
Expand All @@ -21,5 +23,5 @@
/**
* When set to true no confirmation will be requested on migration run.
*/
'safe' => env('APP_ENV') === 'local',
'safe' => env('SAFE_MIGRATIONS', spiral(AppEnvironment::class)->isProduction()),
];
11 changes: 9 additions & 2 deletions installer/Module/Exception/resources/app.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,25 +2,32 @@

declare(strict_types=1);

use App\Application\Kernel;
use App\Application\Exception\Handler;
use App\Application\Kernel;
use Spiral\Core\Container;
use Spiral\Core\Options;

// If you forgot to configure some of this in your php.ini file,
// then don't worry, we will set the standard environment
// settings for you.

\mb_internal_encoding('UTF-8');
\error_reporting((E_ALL | E_STRICT) ^ E_DEPRECATED);
\error_reporting(E_ALL ^ E_DEPRECATED);
\ini_set('display_errors', 'stderr');

// Register Composer's auto loader.
require __DIR__ . '/vendor/autoload.php';


// Initialize shared container, bindings, directories and etc.
$options = new Options();
$options->allowSingletonsRebinding = false;
$options->validateArguments = false;
$container = new Container(options: $options);
$app = Kernel::create(
directories: ['root' => __DIR__],
exceptionHandler: Handler::class,
container: $container,
)->run();

if ($app === null) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -259,30 +259,9 @@
d="M17.6 1.3C16.2.7 14.8.3 13.3 0l-.6 1.1a16 16 0 0 0-4.7 0L7.4 0C6 .3 4.5.7 3.2 1.3.5 5.3-.3 9.3 0 13.1c1.6 1.1 3.3 2 5.2 2.6L6.5 14c-.7-.2-1.2-.5-1.8-.8l.4-.4a12.3 12.3 0 0 0 10.5 0l.4.4-1.7.8 1 1.8c2-.6 3.8-1.5 5.3-2.6.5-4.5-.7-8.4-3-11.8ZM6.9 10.7c-1 0-1.8-1-1.8-2 0-1.2.8-2.1 1.8-2.1s1.9.9 1.9 2c0 1.2-.8 2.1-1.9 2.1Zm7 0c-1.1 0-2-1-2-2 0-1.2.9-2.1 2-2.1 1 0 1.8.9 1.8 2 0 1.2-.9 2.1-1.9 2.1Z"></path>
</svg>
</a>
<a class="links-item" href="https://forum.roadrunner.dev/" tabindex="0" target="_blank"
aria-label="Discourse">
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none">
<path fill="currentColor"
d="M12 2.4c-5.2 0-9.59 4.22-9.59 9.43v9.77h9.6c5.2 0 9.43-4.4 9.43-9.6 0-5.21-4.23-9.6-9.43-9.6Z"></path>
<path class="discourse-path-1" fill="#1F242B"
d="M12.1 6.05a5.85 5.85 0 0 0-5.13 8.63l-1.06 3.4 3.8-.85a5.85 5.85 0 1 0 2.4-11.18Z"></path>
<path class="discourse-path-2" fill="#161B22"
d="M16.68 15.52a5.84 5.84 0 0 1-6.97 1.7l-3.8.87 3.87-.46a5.84 5.84 0 0 0 6.96-9.29 5.84 5.84 0 0 1-.06 7.17Z"
opacity=".2"></path>
<path class="discourse-path-3" fill="#A2ACBA"
d="M16.35 14.4a5.84 5.84 0 0 1-6.75 2.43l-3.7 1.26 3.8-.86a5.84 5.84 0 0 0 5.97-9.97 5.84 5.84 0 0 1 .68 7.15Z"
opacity=".4"></path>
<path class="discourse-path-3" fill="#A2ACBA"
d="M7.32 14.81a5.85 5.85 0 0 1 9.43-6.47 5.84 5.84 0 0 0-9.78 6.34l-1.06 3.4 1.4-3.27Z"
opacity=".4"></path>
<path class="discourse-path-2" fill="#161B22"
d="M6.96 14.68a5.85 5.85 0 0 1 8.7-7.42A5.85 5.85 0 0 0 6.6 14.6l-.7 3.5 1.06-3.4Z"
opacity=".2"></path>
</svg>
</a>
</nav>
</div>
<div class="version"><span>Spiral Framework v3.8</span> <span>PHP <?=PHP_VERSION?></span></div>
<div class="version"><span>Spiral Framework 3</span> <span>PHP <?=PHP_VERSION?></span></div>

<div class="logo">
<a href="https://spiral.dev/">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -69,30 +69,9 @@
d="M17.6 1.3C16.2.7 14.8.3 13.3 0l-.6 1.1a16 16 0 0 0-4.7 0L7.4 0C6 .3 4.5.7 3.2 1.3.5 5.3-.3 9.3 0 13.1c1.6 1.1 3.3 2 5.2 2.6L6.5 14c-.7-.2-1.2-.5-1.8-.8l.4-.4a12.3 12.3 0 0 0 10.5 0l.4.4-1.7.8 1 1.8c2-.6 3.8-1.5 5.3-2.6.5-4.5-.7-8.4-3-11.8ZM6.9 10.7c-1 0-1.8-1-1.8-2 0-1.2.8-2.1 1.8-2.1s1.9.9 1.9 2c0 1.2-.8 2.1-1.9 2.1Zm7 0c-1.1 0-2-1-2-2 0-1.2.9-2.1 2-2.1 1 0 1.8.9 1.8 2 0 1.2-.9 2.1-1.9 2.1Z"></path>
</svg>
</a>
<a class="links-item" href="https://forum.roadrunner.dev/" tabindex="0" target="_blank"
aria-label="Discourse">
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none">
<path fill="currentColor"
d="M12 2.4c-5.2 0-9.59 4.22-9.59 9.43v9.77h9.6c5.2 0 9.43-4.4 9.43-9.6 0-5.21-4.23-9.6-9.43-9.6Z"></path>
<path class="discourse-path-1" fill="#1F242B"
d="M12.1 6.05a5.85 5.85 0 0 0-5.13 8.63l-1.06 3.4 3.8-.85a5.85 5.85 0 1 0 2.4-11.18Z"></path>
<path class="discourse-path-2" fill="#161B22"
d="M16.68 15.52a5.84 5.84 0 0 1-6.97 1.7l-3.8.87 3.87-.46a5.84 5.84 0 0 0 6.96-9.29 5.84 5.84 0 0 1-.06 7.17Z"
opacity=".2"></path>
<path class="discourse-path-3" fill="#A2ACBA"
d="M16.35 14.4a5.84 5.84 0 0 1-6.75 2.43l-3.7 1.26 3.8-.86a5.84 5.84 0 0 0 5.97-9.97 5.84 5.84 0 0 1 .68 7.15Z"
opacity=".4"></path>
<path class="discourse-path-3" fill="#A2ACBA"
d="M7.32 14.81a5.85 5.85 0 0 1 9.43-6.47 5.84 5.84 0 0 0-9.78 6.34l-1.06 3.4 1.4-3.27Z"
opacity=".4"></path>
<path class="discourse-path-2" fill="#161B22"
d="M6.96 14.68a5.85 5.85 0 0 1 8.7-7.42A5.85 5.85 0 0 0 6.6 14.6l-.7 3.5 1.06-3.4Z"
opacity=".2"></path>
</svg>
</a>
</nav>
</div>
<div class="version"><span>Spiral Framework v3.8</span> <span>PHP @php echo PHP_VERSION; @endphp</span></div>
<div class="version"><span>Spiral Framework 3</span> <span>PHP @php echo PHP_VERSION; @endphp</span></div>

<div class="logo">
<a href="https://spiral.dev/">
Expand Down
23 changes: 1 addition & 22 deletions installer/Module/TemplateEngines/Twig/resources/views/home.twig
Original file line number Diff line number Diff line change
Expand Up @@ -63,30 +63,9 @@
d="M17.6 1.3C16.2.7 14.8.3 13.3 0l-.6 1.1a16 16 0 0 0-4.7 0L7.4 0C6 .3 4.5.7 3.2 1.3.5 5.3-.3 9.3 0 13.1c1.6 1.1 3.3 2 5.2 2.6L6.5 14c-.7-.2-1.2-.5-1.8-.8l.4-.4a12.3 12.3 0 0 0 10.5 0l.4.4-1.7.8 1 1.8c2-.6 3.8-1.5 5.3-2.6.5-4.5-.7-8.4-3-11.8ZM6.9 10.7c-1 0-1.8-1-1.8-2 0-1.2.8-2.1 1.8-2.1s1.9.9 1.9 2c0 1.2-.8 2.1-1.9 2.1Zm7 0c-1.1 0-2-1-2-2 0-1.2.9-2.1 2-2.1 1 0 1.8.9 1.8 2 0 1.2-.9 2.1-1.9 2.1Z"></path>
</svg>
</a>
<a class="links-item" href="https://forum.roadrunner.dev/" tabindex="0" target="_blank"
aria-label="Discourse">
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none">
<path fill="currentColor"
d="M12 2.4c-5.2 0-9.59 4.22-9.59 9.43v9.77h9.6c5.2 0 9.43-4.4 9.43-9.6 0-5.21-4.23-9.6-9.43-9.6Z"></path>
<path class="discourse-path-1" fill="#1F242B"
d="M12.1 6.05a5.85 5.85 0 0 0-5.13 8.63l-1.06 3.4 3.8-.85a5.85 5.85 0 1 0 2.4-11.18Z"></path>
<path class="discourse-path-2" fill="#161B22"
d="M16.68 15.52a5.84 5.84 0 0 1-6.97 1.7l-3.8.87 3.87-.46a5.84 5.84 0 0 0 6.96-9.29 5.84 5.84 0 0 1-.06 7.17Z"
opacity=".2"></path>
<path class="discourse-path-3" fill="#A2ACBA"
d="M16.35 14.4a5.84 5.84 0 0 1-6.75 2.43l-3.7 1.26 3.8-.86a5.84 5.84 0 0 0 5.97-9.97 5.84 5.84 0 0 1 .68 7.15Z"
opacity=".4"></path>
<path class="discourse-path-3" fill="#A2ACBA"
d="M7.32 14.81a5.85 5.85 0 0 1 9.43-6.47 5.84 5.84 0 0 0-9.78 6.34l-1.06 3.4 1.4-3.27Z"
opacity=".4"></path>
<path class="discourse-path-2" fill="#161B22"
d="M6.96 14.68a5.85 5.85 0 0 1 8.7-7.42A5.85 5.85 0 0 0 6.6 14.6l-.7 3.5 1.06-3.4Z"
opacity=".2"></path>
</svg>
</a>
</nav>
</div>
<div class="version"><span>Spiral Framework v3.8</span> <span>PHP {{ constant('PHP_VERSION') }}</span></div>
<div class="version"><span>Spiral Framework 3</span> <span>PHP {{ constant('PHP_VERSION') }}</span></div>

<div class="logo">
<a href="https://spiral.dev/">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,11 +35,11 @@ public function testGenerateDefault(): void

namespace Tests\Fixtures;

use Spiral\Core\CoreInterface;
use Spiral\Interceptors\HandlerInterface;

final class RoutesBootloader
{
protected const SINGLETONS = [CoreInterface::class => [self::class, 'domainCore']];
protected const SINGLETONS = [HandlerInterface::class => [self::class, 'domainCore']];
}

PHP;
Expand Down Expand Up @@ -73,11 +73,11 @@ public function testGenerateWithInterceptors(): void
namespace Tests\Fixtures;

use App\Interceptor\FirstInterceptor;
use Spiral\Core\CoreInterface;
use Spiral\Interceptors\HandlerInterface;

final class RoutesBootloader
{
protected const SINGLETONS = [CoreInterface::class => [self::class, 'domainCore']];
protected const SINGLETONS = [HandlerInterface::class => [self::class, 'domainCore']];

protected const INTERCEPTORS = [
FirstInterceptor::class,
Expand Down
10 changes: 10 additions & 0 deletions installer/config.php
Original file line number Diff line number Diff line change
Expand Up @@ -128,5 +128,15 @@
comment: 'Telemetry',
priority: 9,
),
new EnvGroup(
values: [
'TOKENIZER_CACHE_TARGETS' => false,
'TOKENIZER_LOAD_CLASSES' => true,
'TOKENIZER_LOAD_ENUMS' => true,
'TOKENIZER_LOAD_INTERFACES' => true,
],
comment: 'Tokenizer',
priority: 9,
),
],
];