build: replace install task with mise deps for automatic dependency management

This commit is contained in:
2026-05-01 20:26:15 +00:00
parent fe5603e206
commit 905d668847
2 changed files with 13 additions and 10 deletions

View File

@@ -20,15 +20,14 @@ Tool versions are declared in `mise.toml`. Install [mise](https://mise.jdx.dev)
### Development
```bash
# Install frontend dependencies (first time only)
mise run install
# Start both servers (Go API + Vite dev server)
mise run dev
# Go API: http://localhost:8080
# Vite UI: http://localhost:5173 (with /api proxy)
```
**Note**: Dependencies are automatically installed when needed. If you want to manually trigger dependency installation, run `mise deps`.
`AUTH_TOKEN` defaults to `devtoken` in `mise.toml`. Override it by setting the variable in your environment before running.
Open `http://localhost:5173`, go to **Settings**, enter your token.
@@ -53,7 +52,7 @@ AUTH_TOKEN=mysecrettoken ./wotra
| `mise run dev:api` | Start Go API server only |
| `mise run dev:ui` | Start Vite dev server only |
| `mise run test` | Run all Go tests |
| `mise run install` | Install frontend npm dependencies |
| `mise deps` | Install/update project dependencies |
| `mise run clean` | Remove build artifacts |
## Configuration (environment variables)

View File

@@ -1,7 +1,16 @@
[settings]
experimental = true
[deps.npm]
auto = true
dir = "web"
[deps.go]
auto = true
[tools]
go = "1.26.2"
node = "24.14.0"
npm = "latest"
[env]
AUTH_TOKEN = "devtoken"
@@ -56,11 +65,6 @@ run = "npm test"
description = "Run Go tests and frontend Vitest tests"
depends = ["test", "test:web"]
[tasks.install]
description = "Install frontend npm dependencies"
dir = "web"
run = "npm install"
[tasks.clean]
description = "Remove build artifacts"
run = """