Closed omarlopesino closed 1 year ago
Work in progress have been done in scriptor at branch fb-frontend-themes-path. Also, a work in progress is done in the boilerplate in the following pull request: https://github.com/Metadrop/drupal-boilerplate/pull/80
Please may someone review these PR: https://github.com/Metadrop/scripthor/pull/46 https://github.com/Metadrop/drupal-boilerplate/pull/80 ?
LGTM!
This is already merged and released. Closing.
Problem description
Currently, to build/watch themes assets, it is used the make frontend command. This command works on the theme defined in the .env THEME_PATH variable. While this works in most cases, when a DRupal site has more than one theme, it requires to changes the THEME_PATH variable in the .env file.
This may be a bit uncomfortable because it requires changing a file managed by GIT but it does not need to be committed. Plus, .env variables must be changed when to change the environment features, and not to parameterise a command, which is this case.
Proposed resolution
The resolution si to delegate all the theme variables into the make frontend command through these steps:
Boilerplate
Scripthor
Scripthor must be adapted to replace the values of the FRONTEND_THEME variable in the Makefile with the custom theme created in the `composer create-project' process.