62 lines
1.6 KiB
Makefile
62 lines
1.6 KiB
Makefile
_default:
|
|
@just --unsorted --list
|
|
|
|
check:
|
|
bc-check
|
|
|
|
fmt:
|
|
fd --extension=rs --exec-batch leptosfmt
|
|
bc-fmt
|
|
|
|
fix:
|
|
bc-fix
|
|
|
|
serve:
|
|
RUST_BACKTRACE=1 cargo leptos watch -- serve
|
|
|
|
# build-release:
|
|
# rm -rf dist
|
|
# mkdir dist
|
|
# cargo leptos build --release -vv
|
|
# cp target/release/ascend dist/
|
|
# cp -r target/site dist/
|
|
# run-release:
|
|
# #!/usr/bin/env bash
|
|
# cd dist
|
|
# LEPTOS_SITE_ROOT="site" LEPTOS_SITE_ADDR="127.0.0.1:1337" ./ascend serve
|
|
|
|
reset-state:
|
|
cargo run --features ssr -- reset-state
|
|
|
|
# Open firewall port for development
|
|
open-firewall:
|
|
sudo nixos-firewall-tool open tcp 1337
|
|
|
|
# Remove local datastore and copy prod datastore
|
|
cp-prod-datastore:
|
|
rm -r datastore
|
|
rsync --human-readable --recursive --info=stats1,progress2 --archive 192.168.1.3:/home/ascend/datastore .
|
|
|
|
# Update ascend input and nixos-rebuild switch
|
|
prod-deploy:
|
|
# Build on this machine (faster) and copy to prod /nix/store
|
|
nix copy --to ssh://192.168.1.3 .
|
|
|
|
# Update ascend input on prod machine nix configuration
|
|
ssh 192.168.1.3 'cd /home/plul/repos/gitlab.com/plul/nixexprs; just update-ascend'
|
|
|
|
# Switch nix configuration on prod (should be fast as /nix/store should be pre-populated)
|
|
ssh -t 192.168.1.3 'cd /home/plul/repos/gitlab.com/plul/nixexprs; just switch'
|
|
|
|
prod-logs:
|
|
ssh 192.168.1.3 'journalctl --unit ascend.service'
|
|
|
|
leptos-discord:
|
|
xdg-open "https://discord.com/channels/1031524867910148188/1031524868883218474"
|
|
|
|
leptos-issues:
|
|
xdg-open "https://github.com/leptos-rs/leptos/issues"
|
|
|
|
icons:
|
|
xdg-open "https://heroicons.com/"
|