Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
37 changes: 37 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
name: build
on:
pull_request:
push:
branches:
- main
jobs:
web:
name: Web
runs-on: ubuntu-latest
timeout-minutes: 10
defaults:
run:
working-directory: web
steps:
- uses: actions/checkout@v4
- uses: oven-sh/setup-bun@v2
with:
bun-version: 1.2.2
- run: bun install --frozen-lockfile
working-directory: server
- run: bun install --frozen-lockfile
- run: bun run build
server:
name: Server
runs-on: ubuntu-latest
timeout-minutes: 10
defaults:
run:
working-directory: server
steps:
- uses: actions/checkout@v4
- uses: oven-sh/setup-bun@v2
with:
bun-version: 1.2.2
- run: bun install --frozen-lockfile
- run: bun run build
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
node_modules
/.env
web/dist

# Nix + Direnv
/.direnv
Expand Down
6 changes: 5 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,10 @@
"scripts": {
"prepare": "lefthook install",
"dev": "bun --env-file=./.env :dev",
":dev": "trap 'kill 0' EXIT; (cd web && bun dev) & (cd server && bun dev) & wait"
":dev": "trap 'kill 0' EXIT; (cd web && bun dev) & (cd server && bun dev) & wait",
"check:fix": "bun biome check . --fix --unsafe && bun run build",
"check": "bun biome check . && bun run build",
"build": "(cd web && bun run build) && (cd server && bun run build)",
"clean": "rm -r node_modules && rm -r **/node_modules && rm web/dist -r"
}
}
12 changes: 2 additions & 10 deletions server/bun.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion server/index.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { Context, Hono, Next } from "hono";
import { Hono } from "hono";
import cors from "./middlewares/cors";
import hello from "./routes/hello";

Expand Down
5 changes: 3 additions & 2 deletions server/package.json
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
{
"name": "server",
"scripts": {
"dev": "bun run --env-file=../.env --hot index.ts"
"dev": "bun run --env-file=../.env --hot index.ts",
"build": "bun tsc"
},
"dependencies": {
"hono": "^4.7.1"
},
"devDependencies": {
"@types/bun": "latest"
"typescript": "^5.7.3"
}
}
14 changes: 12 additions & 2 deletions server/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,17 @@
{
"compilerOptions": {
"strict": true,
"target": "es2015",
"module": "nodenext",
"moduleResolution": "nodenext",
"jsx": "react-jsx",
"jsxImportSource": "hono/jsx"
"jsxImportSource": "hono/jsx",
"noEmit": true,
"skipLibCheck": true,
"allowImportingTsExtensions": true,
"strict": true,
"noUnusedLocals": true,
"noUnusedParameters": true,
"noFallthroughCasesInSwitch": true,
"noUncheckedSideEffectImports": true
}
}