From 54b06d473a494c9c3d5398486d0a3c55f55e59ac Mon Sep 17 00:00:00 2001 From: Joseph Bielawski Date: Fri, 2 Feb 2024 14:43:54 +0100 Subject: [PATCH] Add shortcut for building static content for landing page (#951) * Add shortcut for building static content for landing page * Update composer.json --- src/web/landing/.gitignore | 3 ++- src/web/landing/build/.gitkeep | 0 src/web/landing/composer.json | 5 +++++ .../landing/config/packages/static_content_generator.yaml | 2 ++ 4 files changed, 9 insertions(+), 1 deletion(-) create mode 100644 src/web/landing/build/.gitkeep create mode 100644 src/web/landing/config/packages/static_content_generator.yaml diff --git a/src/web/landing/.gitignore b/src/web/landing/.gitignore index 6a44d6694..2f0cb2fdf 100644 --- a/src/web/landing/.gitignore +++ b/src/web/landing/.gitignore @@ -1,4 +1,5 @@ .env.local +build/ vendor/ var/ -public/assets \ No newline at end of file +public/assets diff --git a/src/web/landing/build/.gitkeep b/src/web/landing/build/.gitkeep new file mode 100644 index 000000000..e69de29bb diff --git a/src/web/landing/composer.json b/src/web/landing/composer.json index 7d3374d8a..4b57b48f0 100644 --- a/src/web/landing/composer.json +++ b/src/web/landing/composer.json @@ -32,6 +32,7 @@ }, "config": { "allow-plugins": { + "php-http/discovery": false, "symfony/runtime": true } }, @@ -41,6 +42,10 @@ "@assets:clear", "bin/console tailwind:build", "bin/console asset-map:compile" + ], + "build": [ + "bin/console static-content-generator:generate:routes", + "bin/console static-content-generator:copy:assets -d assets" ] } } diff --git a/src/web/landing/config/packages/static_content_generator.yaml b/src/web/landing/config/packages/static_content_generator.yaml new file mode 100644 index 000000000..add4e6397 --- /dev/null +++ b/src/web/landing/config/packages/static_content_generator.yaml @@ -0,0 +1,2 @@ +static_content_generator: + output_directory: "%kernel.project_dir%/build"