-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathjustfile
More file actions
34 lines (26 loc) · 1.01 KB
/
justfile
File metadata and controls
34 lines (26 loc) · 1.01 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
set dotenv-load
# Build mode configuration.
mode := env_var_or_default("BUILD_MODE", "debug")
release_flag := if mode == "release" { "--release" } else { "" }
log_prefix := if mode == "debug" { "RUST_LOG=debug" } else { "" }
# Display list of commands.
default:
just -l
# Start PostgreSQL and Minio servers.
servers:
nix run ./devenv
# Start backend server.
backend:
cd backend; {{log_prefix}} bacon run -- {{release_flag}}
# Start frontend server. https://github.com/trunk-rs/trunk/issues/732#issuecomment-2391810077
frontend:
cd frontend; ping -c 1 8.8.8.8 && pnpm i --prefer-offline; trunk serve {{release_flag}} --skip-version-check --offline --open
# Regenerate "frontend/graphql/schema.json".
regenerate-schema:
graphql-client introspect-schema http://localhost:8000 > frontend/graphql/schema.json
# Prepare the project before pushing.
prepare:
cd devenv; nix fmt; cd ..; cargo fmt; cargo doc --no-deps; cargo clippy; cargo test
# Scan for hardcoded values.
scan-hardcoded:
./scan_hardcoded.sh