50 lines
925 B
Makefile
50 lines
925 B
Makefile
COMPOSER ?= composer
|
|
PHP ?= php8.1
|
|
SSH ?= ssh
|
|
YARN ?= yarn
|
|
NPM_BIN ?= npm
|
|
|
|
all: build
|
|
|
|
asset-watch:
|
|
$(YARN_BIN)
|
|
$(NPM_BIN) run watch
|
|
|
|
asset: js-routing
|
|
$(YARN_BIN)
|
|
$(NPM_BIN) run build
|
|
|
|
js-routing: doctrine-migration
|
|
$(PHP) bin/console fos:js-routing:dump --format=json --target=public/js/fos_js_routes.json
|
|
|
|
clean:
|
|
rm -fr var/cache/dev/*
|
|
rm -fr var/cache/prod/*
|
|
$(PHP) bin/console
|
|
|
|
doctrine-migration:
|
|
PHP=$(PHP) ./bin/doctrine-migrate
|
|
|
|
.ONESHELL:
|
|
lint:
|
|
eslint --fix assets/js/**/*.{js,vue}
|
|
for f in assets/css/*.scss assets/css/app/*.scss; do
|
|
cssbeautify-cli -f $$f -w $$f.scss
|
|
done
|
|
|
|
build: clean js-routing asset
|
|
|
|
.ONESHELL:
|
|
font:
|
|
cd assets/fonts/deblan/
|
|
svg2ttf src/deblan-icon.svg deblan-icon.ttf
|
|
ttf2woff deblan-icon.ttf deblan-icon.woff
|
|
cat deblan-icon.ttf | ttf2woff2 > deblan-icon.woff2
|
|
ttf2eot deblan-icon.ttf deblan-icon.eot
|
|
|
|
deploy-prod:
|
|
mage deploy prod
|
|
|
|
deploy-preprod:
|
|
mage deploy preprod
|