docs: record that the session-start hook stores an absolute path (task 0042)
Resolve the nix-flake-packaging spec's open verification item by observation rather than inference, and act on the unfavourable answer. `resolvePortableHookCommand` in axi-sdk-js returns the bare binary name only when a PATH entry realpath-matches the entrypoint. npm symlinks its bin entry straight at dist/main.js and satisfies that; Nix installs a generated wrapper script whose realpath is the wrapper, so the absolute store path is recorded instead. Verified by probing the SDK with both install shapes and by driving the flake-built binary against a temporary HOME. The path is content-addressed, so it moves on every rebuild and is eventually collected, and a session-start hook that cannot execute fails silently. The mitigation is documentation, per the decision recorded when the item was opened: the setup help text now says to re-run `setup hooks` after an upgrade. How the setup command constructs the hook is deliberately unchanged. Preferring the bare name is the right answer for every wrapper-based install, not a Nix special case, so it belongs in a successor task with its own ADR alongside the related `isManagedHook` substring defect. package.nix's postUnpack rename therefore stays; its comment no longer promises this task will remove it.
This commit is contained in:
@@ -18,6 +18,14 @@ Install gitea-axi's ambient context for agent sessions.
|
||||
Both are idempotent: re-running updates the managed files in place rather than
|
||||
failing. There is no postinstall script — installation is always explicit.
|
||||
|
||||
Re-run "setup hooks" after upgrading gitea-axi. The hook records an absolute
|
||||
path to the entrypoint, which moves when the install location changes, and a
|
||||
session-start hook that cannot be executed fails silently rather than warning.
|
||||
This matters most for immutable installs such as Nix, where every rebuild lands
|
||||
the entrypoint at a fresh path and the old one is eventually collected. When the
|
||||
path moves, the re-run may leave the stale entry behind instead of replacing it;
|
||||
remove it by hand if a duplicate appears.
|
||||
|
||||
flags:
|
||||
--help Show this help
|
||||
`;
|
||||
|
||||
Reference in New Issue
Block a user