Commit Graph

8 Commits

Author SHA1 Message Date
david b5650c53ba test: add JS test framework using Node built-in test runner
Extracted pure utility functions (esc, sanitize, formatBytes, formatTime)
into web/ui/util.js with CommonJS export for Node testing compatibility.
Added 19 tests across 4 suites using node:test + node:assert (zero deps).

- util.js: browser-compatible utility functions
- util.test.js: 19 tests (5 esc, 3 sanitize, 6 formatBytes, 5 formatTime)
- package.json: 'test' script → node --test util.test.js
- mise.toml: js-test task
- app.js: removed duplicate helper functions (now in util.js)
- index.html: load util.js before app.js
2026-06-22 02:23:24 -07:00
david d194a25bf8 chore: pin node to 22.12 to fix electron-build engine requirements
@electron/rebuild and node-abi require node >=22.12.0.
System node (22.9.0) caused EBADENGINE errors during electron-build.
2026-06-22 00:16:42 -07:00
david 4f03524668 chore: add JS/ESLint toolchain, refactor onclick to event delegation
- Add ESLint config for web/ui (flat config, golangci-lint-compatible)
- Add js-lint task to mise.toml (npm run lint in web/ui)
- Add ESLint check to check-toolchain.sh
- Add .golangci.yml for golangci-lint v2 with correct exclusions
- Refactor app.js: replace inline onclick with data-action + event delegation
- Add null checks and HTTP status checks to browseWavs
- Add web/ui/node_modules/ to .gitignore
2026-06-22 00:10:49 -07:00
david 470fb9a4c4 docs: update README/AGENTS for current codebase
- All references updated from fetch → akai-fetch
- AGENTS: document golangci-lint, extract.go replaces bash,
  remove findScript, update Electron binary name
- README: update roadmap, extraction tech stack
- mise.toml: add golangci-lint tool
2026-06-21 23:22:00 -07:00
david 04d2bec114 fix: add init target to pre-create output dirs before docker
Docker creates host-side bind-mount directories as root:root.
Pre-creating them with make init (or mise run init) ensures
they exist with the user's ownership before docker compose
touches them. docker-up now depends on init.
2026-06-21 22:29:55 -07:00
david 15979d01b5 fix: check MkdirAll errors, add gopls to toolchain
- serve.go/cmdAPIDownload: check MkdirAll error, use absolute path
- main.go/cmdDownload,cmdExtract: check MkdirAll errors
- check-toolchain.sh: verify gopls installation
- mise.toml: add gopls install task
- AGENTS.md: document gopls as dev dependency
2026-06-21 22:27:17 -07:00
david e671320bbb feat: add toolchain check scripts and mise tasks
- scripts/check-toolchain.sh: checks gcc, homebrew, mise, go, node
- scripts/check-docker-toolchain.sh: checks docker, compose, colima (macOS), buildx
- mise tasks: check-toolchain, check-docker-toolchain, check-all
2026-06-21 21:46:11 -07:00
david 9657aaa523 chore: docker compose, mise.toml, updated toolchain
- Dockerfile: updated to serve mode with web/ embed, expose 8080
- docker-compose.yml: new, maps :8080 and output volume
- Makefile: added serve, akaiutil, electron-* targets
- mise.toml: new, go 1.26 + node 22, all build/run tasks
- .gitignore: exclude built akaiutil binary
2026-06-21 19:46:34 -07:00