|
|
@@ -23,6 +23,34 @@ For the effect catalog specifically, read it from no document at all. Run
|
|
|
effects than Backlight, and only the tool knows what the current firmware
|
|
|
supports.
|
|
|
|
|
|
+## Fetch the Remote Before the First Edit
|
|
|
+
|
|
|
+`origin/main` moves while you work, and this repository is worked on from more
|
|
|
+than one machine. Check it before the first edit of a session, not before the
|
|
|
+push: a working tree that starts a rebase half-finished has already lost work.
|
|
|
+
|
|
|
+```sh
|
|
|
+git fetch origin && git log --oneline HEAD..origin/main && git diff --stat HEAD...origin/main
|
|
|
+```
|
|
|
+
|
|
|
+Read what the incoming commits touch, and rebase onto them before editing:
|
|
|
+
|
|
|
+```sh
|
|
|
+git rebase origin/main
|
|
|
+```
|
|
|
+
|
|
|
+`git status -sb` reporting `ahead N, behind M` means both are true, and `M > 0`
|
|
|
+is the one that ends in a rejected push. A `non-fast-forward` rejection is that
|
|
|
+same finding one step too late — rebase, never force-push, because the commits
|
|
|
+behind are other people's work and this branch is not the only writer.
|
|
|
+
|
|
|
+Three times now the local checkout has been behind at the moment of the push,
|
|
|
+and once the incoming commits touched `AGENTS.md` and `README.md` as well, which
|
|
|
+is where a stale copy of this file is written. A commit built against a tree that
|
|
|
+no longer exists is not wrong, it is orphaned, and the checks that would have
|
|
|
+caught it — `go test ./...` and the doc tests in `cmd/qmk-rgb-tool` — run against
|
|
|
+whatever is on disk, not against `origin/main`.
|
|
|
+
|
|
|
## Objective
|
|
|
Cross-platform Go CLI library for programmatic/agent-friendly control of QMK keyboard RGB lighting.
|
|
|
|