refactor(sessionlock): move readiness ledger under the wayland adapter
- commit
- 6bb50007ff8b76127e17e3b022245d74cc8089af
- author
- brice · · 2026-10-04 15:28 UTC
- committer
- brice · · 2026-10-04 15:36 UTC
- parent
- c900986
- signature
- GPG Verified
CD88F9E564E0102646FB6077A1A07C7C7C3E349D· arch-gpg Verified for the committer email
6 files · +4 -5
M .hexcheck.yaml +1 -2
| @@ -2,8 +2,7 @@ version: 1 | |||
| 2 | 2 | components: | |
| 3 | 3 | core: { role: core, paths: [internal/core/**] } | |
| 4 | 4 | ports: { role: ports, paths: [internal/ports/**] } | |
| 5 | - | # sessionlock is the display owner's proof ledger, not core placement policy. | |
| 6 | - | adapters: { role: adapter, paths: [internal/adapters/**, internal/logging/**, internal/sessionlock/**] } | |
| 5 | + | adapters: { role: adapter, paths: [internal/adapters/**, internal/logging/**] } | |
| 7 | 6 | # app is the composition root: it wires adapters to core, like cmd. | |
| 8 | 7 | entrypoints: { role: entrypoint, paths: [cmd/**, internal/app/**, internal/cli/**] } | |
| 9 | 8 | generated: { role: ignore, paths: [internal/mocks/**] } | |
| @@ -2,8 +2,7 @@ version: 1 | |||||
| 2 | components: | 2 | components: | ||
| 3 | core: { role: core, paths: [internal/core/**] } | 3 | core: { role: core, paths: [internal/core/**] } | ||
| 4 | ports: { role: ports, paths: [internal/ports/**] } | 4 | ports: { role: ports, paths: [internal/ports/**] } | ||
| 5 | - | # sessionlock is the display owner's proof ledger, not core placement policy. | 5 | + | adapters: { role: adapter, paths: [internal/adapters/**, internal/logging/**] } |
| 6 | - | adapters: { role: adapter, paths: [internal/adapters/**, internal/logging/**, internal/sessionlock/**] } | |||
| 7 | # app is the composition root: it wires adapters to core, like cmd. | 6 | # app is the composition root: it wires adapters to core, like cmd. | ||
| 8 | entrypoints: { role: entrypoint, paths: [cmd/**, internal/app/**, internal/cli/**] } | 7 | entrypoints: { role: entrypoint, paths: [cmd/**, internal/app/**, internal/cli/**] } | ||
| 9 | generated: { role: ignore, paths: [internal/mocks/**] } | 8 | generated: { role: ignore, paths: [internal/mocks/**] } | ||
M internal/adapters/wayland/server.go +1 -1
| @@ -15,9 +15,9 @@ import ( | |||
| 15 | 15 | "github.com/bnema/go-wayland-bindings/server/wayland" | |
| 16 | 16 | "github.com/bnema/neferwl/internal/adapters/captureallow" | |
| 17 | 17 | "github.com/bnema/neferwl/internal/adapters/clock" | |
| 18 | + | "github.com/bnema/neferwl/internal/adapters/wayland/sessionlock" | |
| 18 | 19 | "github.com/bnema/neferwl/internal/adapters/workspaceid" | |
| 19 | 20 | "github.com/bnema/neferwl/internal/ports" | |
| 20 | - | "github.com/bnema/neferwl/internal/sessionlock" | |
| 21 | 21 | "github.com/bnema/purego-libwayland/server" | |
| 22 | 22 | "github.com/bnema/zerowrap" | |
| 23 | 23 | "golang.org/x/sys/unix" | |
| @@ -15,9 +15,9 @@ import ( | |||||
| 15 | "github.com/bnema/go-wayland-bindings/server/wayland" | 15 | "github.com/bnema/go-wayland-bindings/server/wayland" | ||
| 16 | "github.com/bnema/neferwl/internal/adapters/captureallow" | 16 | "github.com/bnema/neferwl/internal/adapters/captureallow" | ||
| 17 | "github.com/bnema/neferwl/internal/adapters/clock" | 17 | "github.com/bnema/neferwl/internal/adapters/clock" | ||
| 18 | + | "github.com/bnema/neferwl/internal/adapters/wayland/sessionlock" | |||
| 18 | "github.com/bnema/neferwl/internal/adapters/workspaceid" | 19 | "github.com/bnema/neferwl/internal/adapters/workspaceid" | ||
| 19 | "github.com/bnema/neferwl/internal/ports" | 20 | "github.com/bnema/neferwl/internal/ports" | ||
| 20 | - | "github.com/bnema/neferwl/internal/sessionlock" | |||
| 21 | "github.com/bnema/purego-libwayland/server" | 21 | "github.com/bnema/purego-libwayland/server" | ||
| 22 | "github.com/bnema/zerowrap" | 22 | "github.com/bnema/zerowrap" | ||
| 23 | "golang.org/x/sys/unix" | 23 | "golang.org/x/sys/unix" | ||
R internal/sessionlock/readiness.go → internal/adapters/wayland/sessionlock/readiness.go +0 -0 renamed, 100% similar
renamed, 100% similar
R internal/sessionlock/readiness_test.go → internal/adapters/wayland/sessionlock/readiness_test.go +0 -0 renamed, 100% similar
renamed, 100% similar
M internal/app/security_duplicate_test.go +1 -1
| @@ -5,8 +5,8 @@ import ( | |||
| 5 | 5 | "testing" | |
| 6 | 6 | ||
| 7 | 7 | "github.com/bnema/neferwl/internal/adapters/sessionsecurity" | |
| 8 | + | "github.com/bnema/neferwl/internal/adapters/wayland/sessionlock" | |
| 8 | 9 | "github.com/bnema/neferwl/internal/ports" | |
| 9 | - | "github.com/bnema/neferwl/internal/sessionlock" | |
| 10 | 10 | ) | |
| 11 | 11 | ||
| 12 | 12 | // Native Close validation is exercised by DRM's generated-KMS tests. This | |
| @@ -5,8 +5,8 @@ import ( | |||||
| 5 | "testing" | 5 | "testing" | ||
| 6 | 6 | ||||
| 7 | "github.com/bnema/neferwl/internal/adapters/sessionsecurity" | 7 | "github.com/bnema/neferwl/internal/adapters/sessionsecurity" | ||
| 8 | + | "github.com/bnema/neferwl/internal/adapters/wayland/sessionlock" | |||
| 8 | "github.com/bnema/neferwl/internal/ports" | 9 | "github.com/bnema/neferwl/internal/ports" | ||
| 9 | - | "github.com/bnema/neferwl/internal/sessionlock" | |||
| 10 | ) | 10 | ) | ||
| 11 | 11 | ||||
| 12 | // Native Close validation is exercised by DRM's generated-KMS tests. This | 12 | // Native Close validation is exercised by DRM's generated-KMS tests. This | ||
M internal/app/security_hotplug_test.go +1 -1
| @@ -6,8 +6,8 @@ import ( | |||
| 6 | 6 | "testing" | |
| 7 | 7 | "time" | |
| 8 | 8 | ||
| 9 | + | "github.com/bnema/neferwl/internal/adapters/wayland/sessionlock" | |
| 9 | 10 | "github.com/bnema/neferwl/internal/ports" | |
| 10 | - | "github.com/bnema/neferwl/internal/sessionlock" | |
| 11 | 11 | ) | |
| 12 | 12 | ||
| 13 | 13 | func hotplugEvent(t *testing.T, events <-chan ports.SecurityBackendEvent) ports.SecurityBackendEvent { | |
| @@ -6,8 +6,8 @@ import ( | |||||
| 6 | "testing" | 6 | "testing" | ||
| 7 | "time" | 7 | "time" | ||
| 8 | 8 | ||||
| 9 | + | "github.com/bnema/neferwl/internal/adapters/wayland/sessionlock" | |||
| 9 | "github.com/bnema/neferwl/internal/ports" | 10 | "github.com/bnema/neferwl/internal/ports" | ||
| 10 | - | "github.com/bnema/neferwl/internal/sessionlock" | |||
| 11 | ) | 11 | ) | ||
| 12 | 12 | ||||
| 13 | func hotplugEvent(t *testing.T, events <-chan ports.SecurityBackendEvent) ports.SecurityBackendEvent { | 13 | func hotplugEvent(t *testing.T, events <-chan ports.SecurityBackendEvent) ports.SecurityBackendEvent { | ||