generated from alecodes/base-template
34 lines
863 B
Makefile
34 lines
863 B
Makefile
# Repo management tasks
|
|
mod repo ".devfiles/justfile"
|
|
|
|
set dotenv-load := true
|
|
|
|
[private]
|
|
docker-compose +ARGS:
|
|
docker compose --file .devfiles/docker/docker-compose.dev.yaml --env-file .env --project-name compendium {{ARGS}}
|
|
|
|
start-dev-services: (docker-compose "up --remove-orphans")
|
|
|
|
dev:
|
|
watchexec --restart --clear --watch src --watch templates cargo run
|
|
|
|
migrate: (docker-compose "run dbmate migrate")
|
|
|
|
rollback: (docker-compose "run dbmate rollback")
|
|
|
|
build-frontend:
|
|
#!/usr/bin/env bun
|
|
import sassPlugin from "@alecodes/bun-plugin-sass";
|
|
|
|
const result = await Bun.build({
|
|
entrypoints: ["templates/base.html"],
|
|
outdir: "dist",
|
|
naming: {
|
|
entry: "[dir]/[name].[ext]",
|
|
chunk: "chunks/[name]-[hash].[ext]",
|
|
asset: "assets/[name]-[hash].[ext]",
|
|
},
|
|
plugins: [sassPlugin],
|
|
});
|
|
|
|
console.log("Assets compiled!");
|