pre-close-check

Detect parallel session activity and governance state drift before closing a session.

8|Updated Apr 12, 2026
One-click install
npx skills add https://github.com/Gold-b/claude-code-governance --skill pre-close-check
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: pre-close-check
Source: https://github.com/Gold-b/claude-code-governance/tree/main/bundle/skills/pre-close-check
Command: npx skills add https://github.com/Gold-b/claude-code-governance --skill pre-close-check

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill prevents sessions from closing with stale, partial, or contradictory project state by checking filesystem and repository reality before any final handoff, release, or governance update is written.

Core Features & Use Cases

  • Parallel session detection: Scans recent git activity and handoff file modification times to identify work from other sessions that may have changed the true project state.
  • State consistency validation: Verifies that version.json, CLAUDE.md, HANDOFF.md, and the context manifest all agree on the active version and handoff target.
  • Governance safety gate: Stops closing workflows when drift or multiple active handoffs are detected, forcing a merge, override, or abort decision before damage is done.
  • Use Case: Before running a release or writing a new handoff, use this Skill to confirm no other agent session already bumped the version, updated the active handoff, or changed the governance records behind your back.

Quick Start

Ask the AI to run the pre-close-check skill on the current project before closing the session or updating any handoff or release state.

Frequently Asked Questions about pre-close-check

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I detect parallel session drift before writing a git handoff file?

Detect parallel session drift by scanning recent git commits and handoff file modification times to identify work from other sessions that may have changed the true project state. This validation confirms no other agent session already bumped the version or updated governance records.

What is state consistency validation for repository handoff workflows?

State consistency validation verifies that version.json, CLAUDE.md, HANDOFF.md, and the context manifest all agree on the active version and handoff target. It prevents sessions from closing with stale, partial, or contradictory project state documents.

How do I prevent stale git commits from breaking a release update?

Prevent stale git commits from breaking a release update by applying a governance safety gate that stops closing workflows when drift or multiple active handoffs are detected. This forces a merge, override, or abort decision before damage is done.

When do I need to check for multiple active handoffs in my repository?

Check for multiple active handoffs before closing a session, writing a new handoff, or performing a release update. This applies to repository workflows involving full-finish, live-state-orchestrator handoff writes, plan-and-execute finalization, and project state document mutations.

Does cross-file version consistency validation work with context manifests?

Yes, cross-file version consistency validation verifies that version.json, CLAUDE.md, HANDOFF.md, and the context manifest all agree on the active version and handoff target. It requires context manifest synchronization before finalizing any governance state.