Add CI, Renovate config, changelog, and lockfiles; refresh docs #20
No reviewers
Labels
No labels
bug
decision
docs
enhancement
integration
ops
security
tech-debt
testing
No milestone
No project
No assignees
2 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
rbrooks/BatteryStorageCalculator!20
Loading…
Reference in a new issue
No description provided.
Delete branch "chore/project-hygiene"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Addresses #3, #4, #5, #6, and #19.
Two findings reshaped this work: the roadmap had zero unchecked items, so remaining work was pulled from the audit docs instead; and Renovate was already running (onboarding PR #2, opened 2026-06-23), so this tunes it rather than standing it up.
Reproducible builds (#19)
The repo had no lockfiles and no
.gitignore. Every dependency uses a caret range, sonpm installresolved a fresh tree each run - CI, local dev, and the Docker image could build different dependency trees from identical source. This also made Renovate mostly ineffective: in-range minor/patch PRs changed nothing real, andlockFileMaintenancewas a no-op.Both
package-lock.jsonfiles were generated withnpm install --package-lock-onlyinnode:20-alpine, matching the version both Dockerfiles pin. Both are lockfileVersion 3 (224 and 91 packages) and record all platform variants of@rollup/rollup-*(musl, gnu, win32, darwin), sonpm ciresolves correctly regardless of host platform.CI (#3)
.forgejo/workflows/ci.ymlruns frontend tests, backend tests, and the production build on PRs tomainand pushes tomain, with concurrency cancellation for superseded runs.createMemoryRepositoryfromsrc/repository.memory.js; none referencerepository.pg.jsorDATABASE_URL. The suite never touches a live database.Verified by running the exact pipeline in
node:20-alpine:npm cisucceeded for both packages, 46 frontend tests passed, 22 backend tests passed, production build succeeded.Renovate (#4)
renovate.jsongates all majors behind dependency-dashboard approval, which is what prevents the 13 queued major PRs (React 19, Vite 8, Tailwind 4, Express 5, node 26, postgres 18) from landing at once. Also: weekly off-hours schedule, grouped React/Vite/CSS/Docker updates, concurrency limits, auto-merge for devDependency patch+minor and production patch.Changelog (#5)
CHANGELOG.mdreconstructs 0.1.0 -> 1.0.0 from the 38 commits (2026-05-08 to 2026-06-03) in Keep a Changelog format. It states plainly that pre-1.0.0 versions are a retroactive reading of the commit log and were never tagged - they are not checkout-able. No retroactive tags applied.Docs (#6)
Inverter Modelingmoved out ofMissing, where it listed 11 implemented features under a heading saying its gaps wereNone. Fixed a stale caveat claiming Emporia data is dropped on reload (true only unauthenticated). Tab list said 8;App.jsx:47has 11.src/App.jsxas the calculation coordinator, which stopped being true when calculation moved to the shared runtime. AddedWhere Calculations Run; documented per-circuit whole-home exclusion under outage, explicitly noting it does not affect bill savings.001rather than004. Rebuilt from actual DDL. Added Contributing section and the missing Reports tab.Also verified, and not a bug: two migrations share the
003_prefix.migrate.jskeys each by full filename and sorts lexicographically, so ordering is deterministic. Documented as a naming smell.Review notes
🤖 Generated with Claude Code
CI conventions corrected (
2804be5)Checked the runner labels actually in use across this Forgejo rather than assuming. The original workflow used
runs-on: docker, which is the minority convention here — 13 of 15 repos useubuntu-latest; onlyTeaLeavesandiac-repo's renovate job usedocker, and both pair it with an explicitcontainer:image.Checking that surfaced two further problems that would have bitten at runtime:
1. Unqualified action reference. I had
uses: actions/checkout@v4. Every other repo here fully qualifies it ashttps://data.forgejo.org/actions/checkout@v4. The bare form depends on the instance's default action URL resolving as expected.2. Alpine container vs JS actions. I had
container: node:20-alpine. act_runner injects a glibc-built node into the job container to execute JS actions, and Alpine is musl — socheckoutcould have failed at runtime. NotablyTeaLeavesusesnode:24-bookworm, not Alpine, for its containerised job. Dropped the container entirely in favour ofsetup-nodeon the runner image, which matches the dominant pattern and adds npm caching keyed on both lockfiles.Node 20 still matches what both Dockerfiles pin.
Also adopted the house
ci-prefix on the concurrency group and theworkflow_dispatchtrigger.Caveat on verification: the earlier container run proved
npm ci, both suites, and the build pass against the lockfiles. It could not exerciseruns-onselection, action resolution, or the npm cache — those only prove out on a real runner. Worth watching the first run land.