Files
paulomassigue 14ad2f60c5
tests / ci (push) Canceled after 0s
header:navbar e footer
2026-10-19 13:07:16 +02:00

18 lines
841 B
PHP

<?php
// Runtime directories are not distributed with application data. Prepare them
// before Laravel loads view configuration (which resolves the compiled path).
return static function (string $basePath, string $storagePath): void {
foreach (['app/private', 'app/public', 'framework/cache/data', 'framework/sessions', 'framework/views', 'logs'] as $directory) {
$path = $storagePath.'/'.$directory;
if (! is_dir($path) && ! @mkdir($path, 0775, true) && ! is_dir($path)) {
throw new RuntimeException('Cannot create Laravel runtime directory: '.$path);
}
}
$cachePath = $basePath.'/bootstrap/cache';
if (! is_dir($cachePath) && ! @mkdir($cachePath, 0775, true) && ! is_dir($cachePath)) {
throw new RuntimeException('Cannot create Laravel bootstrap cache: '.$cachePath);
}
};