Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Move storage directory into the app directory #894

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
4 changes: 2 additions & 2 deletions .idea/develop.iml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ class PackageDiscoverCommand extends BaseCommand

public function handle(PackageManifest $manifest): void
{
$manifest->manifestPath = Hyde::path('storage/framework/cache/packages.php');
$manifest->manifestPath = Hyde::path('app/storage/framework/cache/packages.php');
parent::handle($manifest);
}
}
4 changes: 3 additions & 1 deletion packages/framework/src/Foundation/Application.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@
*/
class Application extends \LaravelZero\Framework\Application
{
protected $storagePath = 'app/storage';

/**
* {@inheritdoc}
*/
Expand All @@ -25,6 +27,6 @@ protected function registerBaseBindings(): void
public function getCachedPackagesPath(): string
{
// Since we have a custom path for the cache directory, we need to return it here.
return 'storage/framework/cache/packages.php';
return 'app/storage/framework/cache/packages.php';
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ protected function getManifestPath(): string
{
return Hyde::path(config(
'hyde.build_manifest_path',
'storage/framework/cache/build-manifest.json'
'app/storage/framework/cache/build-manifest.json'
));
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ public function test_package_discover_command_can_run()
public function test_package_discover_command_registers_manifest_path()
{
$this->artisan('package:discover')->assertExitCode(0);
$this->assertEquals(Hyde::path('storage/framework/cache/packages.php'),
$this->assertEquals(Hyde::path('app/storage/framework/cache/packages.php'),
$this->app->make(PackageManifest::class)->manifestPath);
$this->assertFileExists(Hyde::path('storage/framework/cache/packages.php'));
$this->assertFileExists(Hyde::path('app/storage/framework/cache/packages.php'));
}
}
4 changes: 2 additions & 2 deletions packages/framework/tests/Unit/GenerateBuildManifestTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,9 @@ public function test_action_generates_build_manifest()
{
(new GenerateBuildManifest())->run();

$this->assertFileExists(Hyde::path('storage/framework/cache/build-manifest.json'));
$this->assertFileExists(Hyde::path('app/storage/framework/cache/build-manifest.json'));

$manifest = json_decode(file_get_contents(Hyde::path('storage/framework/cache/build-manifest.json')), true);
$manifest = json_decode(file_get_contents(Hyde::path('app/storage/framework/cache/build-manifest.json')), true);

$this->assertIsArray($manifest);

Expand Down