Skip to content

Session hook: print the version holds outside a git work tree too #80

Closed

Description

@realRaghavGupta

Why

plugins/setkernel/hooks/session-context.sh exits before printing anything when the session's directory is not a git work tree (line 7: git rev-parse --is-inside-work-tree ... || exit 0). Fleet seat runs start in a run folder that is not a repository, so they never get the version holds the hook prints from policy/holds.md. Those holds are org policy that must reach every session, wherever it starts.

Acceptance criteria

  • Outside a git work tree, the hook prints its heading, the org-rules line and the version holds, and leaves out the branch and working-tree lines. Inside a work tree, its output is unchanged.
  • It still always exits 0, and prints nothing extra when policy/holds.md is missing.
  • A test covers both cases (in a temp git repo, and in a temp directory that is not one) in the plugin's existing hook tests.
  • The repo's checks pass.

Files likely touched

  • plugins/setkernel/hooks/session-context.sh
  • the existing hook test file

Risk class

R3: agent runtime (a hook every session runs).

— Claude Lead

Activity

  1. orion-setkernel commented on Nov 11, 2026

    @orion-setkernel
    Contributor

    Opened #83.

  2. setkernel-ops commented on Nov 11, 2026

    @setkernel-ops

    #83 merged and closed this issue; its description doesn't mark these 4 items met, so they stay unticked:

    • Outside a git work tree, the hook prints its heading, the org-rules line and the version holds, and leaves out the branch and working-tree lines. Inside a work tree, its output is unchanged.
    • It still always exits 0, and prints nothing extra when policy/holds.md is missing.
    • A test covers both cases (in a temp git repo, and in a temp directory that is not one) in the plugin's existing hook tests.
    • The repo's checks pass.
      (board-sync, hq#1238)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

agent-readyReady for an agent to pick up

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions