Skip to content

Commit 823bfdc

Browse files
committed
Merge branch 'agents'
2 parents d78450d + aaadc22 commit 823bfdc

File tree

1 file changed

+36
-0
lines changed

1 file changed

+36
-0
lines changed

AGENTS.md

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
# Repository Guidelines for bitbox-wallet-app
2+
3+
## Project Structure & Module Organization
4+
The repository powers the BitBoxApp. Core Go services live under `backend/` with entrypoints in
5+
`cmd/` (e.g., `cmd/servewallet`). Frontend clients reside in `frontends/` (`web` for React, `qt` for
6+
the desktop app, `android` and `ios` for mobile artifacts). Shared assets and docs sit in `docs/`,
7+
while automation lives in `scripts/`. Use `vendor/` for pinned Go modules and keep `config/` aligned
8+
with the scenarios documented in `docs/BUILD.md`.
9+
10+
## Build, Test, and Development Commands
11+
- `make envinit` installs golangci-lint, gomobile, and other dev tooling. Run once per environment
12+
refresh.
13+
- `make servewallet` starts the Go backend against the vendored modules; pair it with `make webdev`
14+
(which calls `npm start`) for live UI development.
15+
- `make buildweb` performs a clean web build (`npm ci && npm run build`) used by desktop packages.
16+
- `make webtest`, `make webe2etest`, and `make weblint` proxy to the React test, Playwright, and
17+
ESLint pipelines under `frontends/web`.
18+
- `./scripts/ci.sh` mirrors CI: Go race tests, frontend build, and packaging checks. Use it before
19+
large pull requests.
20+
21+
## Coding Style & Naming Conventions
22+
Go code must stay gofmt/goimports clean; prefer package-level names that mirror directory names
23+
(`backend/accounts`, `backend/rates`). TypeScript follows the ESLint config surfaced by `npm run
24+
lint`; keep React components PascalCased and colocate styles alongside component folders. When
25+
adding Make targets or scripts, stick to lowercase hyphenated names (`servewallet-prodservers`).
26+
27+
## Testing Guidelines
28+
Place Go tests in `_test.go` files and run `go test -mod=vendor ./...` (optionally via
29+
`scripts/coverage.sh` to emit `coverage.cov`). Frontend unit specs live beside components as
30+
`*.test.ts(x)`; invoke `make webtest` for the suite. Use `make webe2etest` for Playwright smoke
31+
flows and document new scenarios in `frontends/web/tests/README.md` if they require fixtures.
32+
33+
## Commit & Pull Request Guidelines
34+
Follow the existing `context: summary` convention (lowercase imperative, no trailing period)—e.g.,
35+
`frontend: simplify account selector`. Keep commits atomic and under ~500 lines when
36+
possible.

0 commit comments

Comments
 (0)