feat(just): migrate client commands to pnpm #6
8
justfile
8
justfile
@@ -5,24 +5,24 @@ output_dir := join(project_dir, ".outputs")
|
|||||||
client_dir := join(project_dir, "client")
|
client_dir := join(project_dir, "client")
|
||||||
exec_path := join(output_dir, project_name)
|
exec_path := join(output_dir, project_name)
|
||||||
go_cmd := `realpath $(which go)`
|
go_cmd := `realpath $(which go)`
|
||||||
bun_cmd := `realpath $(which bun)`
|
pnpm_cmd := `realpath $(which pnpm)`
|
||||||
|
|
||||||
default: install clean build-back build-client run-back
|
default: install clean build-back build-client run-back
|
||||||
|
|
||||||
backend: clean build-back run-back
|
backend: clean build-back run-back
|
||||||
|
|
||||||
install:
|
install:
|
||||||
cd {{ client_dir }} && {{ bun_cmd }} install
|
cd {{ client_dir }} && {{ pnpm_cmd }} install
|
||||||
|
|
||||||
clean:
|
clean:
|
||||||
mkdir -p .outputs
|
mkdir -p .outputs
|
||||||
find .outputs -mindepth 1 ! -path .outputs/config.yaml -exec rm -rf {} +
|
find .outputs -mindepth 1 ! -path .outputs/config.yaml -exec rm -rf {} +
|
||||||
|
|
||||||
client:
|
client:
|
||||||
cd {{ client_dir }} && {{ bun_cmd }} dev
|
cd {{ client_dir }} && {{ pnpm_cmd }} dev
|
||||||
|
|
||||||
build-client:
|
build-client:
|
||||||
cd {{ client_dir }} && {{ bun_cmd }} run build --outDir {{ join(output_dir, "static") }}
|
cd {{ client_dir }} && {{ pnpm_cmd }} run build --outDir {{ join(output_dir, "static") }}
|
||||||
|
|
||||||
build-back:
|
build-back:
|
||||||
{{ go_cmd }} build -o {{ exec_path }}{{ if os() == "windows" { ".exe" } else { "" } }} {{ server_enrty }}
|
{{ go_cmd }} build -o {{ exec_path }}{{ if os() == "windows" { ".exe" } else { "" } }} {{ server_enrty }}
|
||||||
|
|||||||
Reference in New Issue
Block a user