This repository has been archived by the owner on Dec 15, 2024. It is now read-only.
forked from freedit-org/freedit
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* chore: move rs code into `apps/server` * chore: scaffold vite/react app * feat: render raw html served by rust server in react app * chore: use `just` as tasks runner * doc: add main README * fix `dev-client` just script * refactor: write default config dirs relatively to exec bin
- Loading branch information
Showing
107 changed files
with
997 additions
and
335 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,16 @@ | ||
/target | ||
/freedit.db* | ||
/certs | ||
/static/imgs | ||
.rustc_info.json | ||
.rustdoc_fingerprint.json | ||
config.toml | ||
/snapshots | ||
/tantivy | ||
.DS_Store | ||
.envrc | ||
.tool-versions | ||
|
||
apps/server/freedit.db | ||
apps/server/config.toml | ||
apps/server/static/imgs | ||
apps/server/snapshots | ||
apps/server/tantivy | ||
certs | ||
target | ||
|
||
bun.lockb | ||
node_modules | ||
*.tsbuildinfo | ||
yarn.lock |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
export PATH := "./node_modules/.bin:" + env_var('PATH') | ||
|
||
default: | ||
@just --choose | ||
|
||
build: | ||
#!/usr/bin/env -S parallel --shebang --ungroup --jobs {{ num_cpus() }} | ||
just build-client | ||
just build-server | ||
|
||
[working-directory: 'apps/client'] | ||
build-client: | ||
@bun tsc -b | ||
bun vite build | ||
|
||
[working-directory: 'apps/server'] | ||
build-server: | ||
@cargo build -r | ||
|
||
clean-server: | ||
@rm -fr apps/server/{config.toml,freedit.db,snapshots,static/imgs,tantivy,target} | ||
|
||
dev: | ||
@just dev-client & just dev-server | ||
|
||
[working-directory: 'apps/client'] | ||
dev-client: | ||
@bun vite dev | ||
|
||
[working-directory: 'apps/server'] | ||
dev-server: | ||
@cargo run | ||
|
||
start: | ||
@just start-server & just start-client | ||
|
||
start-server: | ||
@./apps/server/target/release/freedit | ||
|
||
start-client: | ||
@vite preview |
Oops, something went wrong.