Commands¶
Available CLI commands for development.
Composer Scripts¶
Run with composer <script>.
| Command | Runs |
|---|---|
composer lint |
pint --test |
composer lint:fix |
pint |
composer lint:phpcs |
phpcs |
composer lint:fix:phpcs |
phpcbf |
composer analyse |
phpstan analyse --memory-limit=-1 |
composer test |
phpunit -c phpunit.xml.dist |
composer test:unit |
phpunit -c phpunit-unit.xml.dist |
composer test:setup |
docker compose exec db mysql -uroot -p${DB_ROOT_PASSWORD:-rootpassword} -e 'CREATE DATABASE IF NOT EXISTS wordpress_test;' |
composer docs:generate |
php scripts/generate-docs.php |
npm Scripts¶
Run with npm run <script>.
| Command | Runs |
|---|---|
npm run lint:scss |
stylelint 'web/app/themes/naluma-theme/assets/scss/**/*.scss' |
npm run lint:scss:fix |
stylelint 'web/app/themes/naluma-theme/assets/scss/**/*.scss' --fix |
npm run lint:js |
eslint |
npm run lint:js:fix |
eslint --fix |
npm run scss |
sass --no-source-map --style=expanded web/app/themes/naluma-theme/assets/scss/main.scss web/app/themes/naluma-theme/style.css |
npm run scss:inject-header |
node scripts/inject-theme-header.js |
npm run css |
run-s scss scss:inject-header |
npm run build |
run-s css |
npm run watch |
chokidar "web/app/themes/naluma-theme/assets/scss/**/*.scss" -c "npm run css" |
npm run prepare |
husky |
npm run bootstrap:events |
ts-node scripts/bootstrap-posthog-events.ts |
npm run bootstrap:events:dry |
ts-node scripts/bootstrap-posthog-events.ts --dry-run |