Update Makefile
Added theme related rules: - theme-build - theme-build-prod - theme-clean - theme-install-dependencies - theme-watch References #41
This commit is contained in:
parent
d343b4cdf2
commit
edb8a59f84
20
Makefile
20
Makefile
|
@ -1,7 +1,11 @@
|
||||||
SHELL=/bin/bash -e -o pipefail
|
SHELL=/bin/bash -e -o pipefail
|
||||||
|
|
||||||
|
THEME_PATH:=web/themes/custom/opdavies
|
||||||
|
|
||||||
.PHONY: *
|
.PHONY: *
|
||||||
|
|
||||||
|
clean: theme-clean
|
||||||
|
|
||||||
phpcs:
|
phpcs:
|
||||||
symfony php vendor/bin/phpcs -n \
|
symfony php vendor/bin/phpcs -n \
|
||||||
--standard="Drupal,DrupalPractice" \
|
--standard="Drupal,DrupalPractice" \
|
||||||
|
@ -38,3 +42,19 @@ stop:
|
||||||
|
|
||||||
test: phpstan phpunit phpcs
|
test: phpstan phpunit phpcs
|
||||||
|
|
||||||
|
theme-build: theme-install-dependencies
|
||||||
|
cd ${THEME_PATH} && npm run dev
|
||||||
|
|
||||||
|
theme-build-prod: theme-install-dependencies
|
||||||
|
bin/drush.sh opdavies:export-body-values-for-theme-purging
|
||||||
|
cd ${THEME_PATH} && npm run prod
|
||||||
|
|
||||||
|
theme-clean: ${THEME_PATH}/build ${THEME_PATH}/node_modules
|
||||||
|
rm -fr ${THEME_PATH}/build
|
||||||
|
rm -fr ${THEME_PATH}/node_modules
|
||||||
|
|
||||||
|
theme-install-dependencies: ${THEME_PATH}/package.json ${THEME_PATH}/package-lock.json
|
||||||
|
cd ${THEME_PATH} && npm install
|
||||||
|
|
||||||
|
theme-watch: theme-build
|
||||||
|
cd ${THEME_PATH} && npm run watch
|
||||||
|
|
Loading…
Reference in a new issue