docs: rewrite README around the dev CLI + remotes

Reflects the post-cleanup shape: single `dev up [--fakewallet|--regtest]`
entry point (the two parallel wrappers are gone), no modules/lnbits/
line (deleted), license footer points at the MIT file we already shipped,
and a settings.nix.git.remotes snippet so a reader sees the topology
toggle without opening docs/remotes.md.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
Padreug 2026-05-25 13:09:46 +02:00
commit 6cabca3113

View file

@ -7,33 +7,55 @@ Opinionated, bare-skeleton scaffold for running an LNbits stack
NixOS module pattern but stripped of any personal identity so the NixOS module pattern but stripped of any personal identity so the
template is consumable as-is. template is consumable as-is.
The goal: clone, fill in your identity + remote topology (upstream The goal: clone, fill in your identity + remote topology, and get a
only / github fork / extra private remote on gitea, forgejo, working LNbits dev environment driven by one command:
codeberg, …), and get a working LNbits dev environment with either:
- **FakeWallet** — no docker, no chains, nothing to start. Fast ```
iteration on extensions and frontend work. dev up # default: FakeWallet — no docker, instant
- **Full regtest** — multi-node LND + CLN + Eclair stack with dev up --regtest # full multi-node regtest stack (LND + CLN + Eclair
bitcoind, electrs, boltz, etc. For channel/payment integration # + bitcoind + electrs); for channel/payment
testing. # integration testing
dev down # tear down whatever's running
dev logs # follow lnbits (+ docker, if regtest)
dev shell # drop into the lnbits venv (or a regtest container)
```
`--fakewallet` is the default mode because the iteration loop for
extension and frontend work doesn't need real chains. `--regtest`
exists for the moments when it does.
## Remote topology
`settings.nix` exposes three slots so the same scaffold works whether
you push to GitHub only, run a private mirror, or both:
```nix
git.remotes = {
upstream = "https://github.com/lnbits/lnbits"; # always
fork = null; # or "https://github.com/<you>/lnbits"
extras = []; # or [{ name = "private"; url = "ssh://…"; }]
};
```
See [`docs/remotes.md`](docs/remotes.md) for the three canonical
patterns (upstream-only, github-fork-for-PRs, multi-remote-with-private
host on forgejo / gitea / codeberg / sourcehut).
## Planned shape ## Planned shape
- `flake.nix` — pins `lnbits/lnbits` upstream + dev tooling. - `flake.nix` — pins `lnbits/lnbits` upstream + dev tooling.
- `settings.nix` — single source of truth (user, email, host, remote - `settings.nix` — single source of truth (user, host, timezone, remote
topology). User fills in. topology). Consumer fills in.
- `modules/lnbits/` — opinionated LNbits NixOS module. - `modules/core.nix``lnbits-sensei.*` option schema (features, bind addr).
- `modules/dev-env/` — worktree mgmt, navigation helpers, regtest - `modules/git/remotes.nix` — remote topology abstraction.
spin-up, fakewallet default, upstream-PR helper. Generalized off - `modules/dev-env/` — the `dev` CLI, worktree mgmt, regtest stack
spin-up, tmux session launcher, upstream-PR helper. Generalized off
any private-host assumptions. any private-host assumptions.
- `modules/git/remotes.nix` — abstract remote topology (`upstream`,
`fork`, optional `extras` list).
## Development ## Development
This repo is iterated on under the sandboxed-claude policy from This repo is iterated on under the sandboxed-claude policy from
[omnixy](https://github.com/TheArctesian/omnixy)'s omnixy's `scripts/sandbox-claude.sh` — a per-launch `.claude/settings.json`
`scripts/sandbox-claude.sh` — a per-launch `.claude/settings.json`
that allows nix/git/inspection and hard-denies sudo, push/remote, that allows nix/git/inspection and hard-denies sudo, push/remote,
container engines, etc. Substantive scaffolding work happens in that container engines, etc. Substantive scaffolding work happens in that
sandbox; promotion (`git push`) is done from the main shell after sandbox; promotion (`git push`) is done from the main shell after
@ -41,4 +63,4 @@ review.
## License ## License
TBD — leaning MIT to match omnixy. [MIT](LICENSE).