ctx-commit

Attach contextual decisions and learnings to code changes during commits.

74|14|Updated Jan 20, 2026
One-click install
npx skills add https://github.com/ActiveMemory/ctx --skill ctx-commit
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: ctx-commit
Source: https://github.com/ActiveMemory/ctx/tree/main/internal/tpl/claude/skills/ctx-commit
Command: npx skills add https://github.com/ActiveMemory/ctx --skill ctx-commit

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Commit messages often lose the reasoning behind design choices. This skill attaches contextual decisions and learnings to code changes so future teammates understand the context.

Core Features & Use Cases

  • Pre-commit checks to ensure builds pass when Go or other code changes occur, and to verify staged changes align with the intended context.
  • After-commit prompts to capture decisions and learning, offering commands like ctx add decision and ctx add learning to persist rationale alongside the code.
  • Workflow coverage for feature development, bugfixes, and refactors, ensuring the context trail accompanies meaningful commits and deployments.

Quick Start

Invoke ctx-commit after meaningful work to capture decisions and learnings alongside the code.

Frequently Asked Questions about ctx-commit

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

FAQPage Schema
How do I preserve decisions and learning with every git commit?

To preserve decisions and learning with every git commit, use automated workflow checks that prompt you to record rationale after a successful commit. This ensures the context trail accompanies meaningful code changes across feature, bugfix, and refactor workflows.

Can I enforce pre-commit validations for staged code changes?

Yes, you can enforce pre-commit validations to verify staged changes align with the intended context. Pre-commit checks ensure builds pass when code changes occur, preventing invalid commits before prompting for decision or learning documentation.

What is the best way to document design rationale alongside code changes?

The best way to document design rationale alongside code changes is to attach contextual decisions after a successful commit. Post-commit prompts offer commands to persist decisions and learnings, ensuring future teammates understand the reasoning behind the work.

Does this workflow automation support bugfix and refactor contexts?

Yes, this workflow automation supports bugfix and refactor contexts. It covers feature development, bugfixes, and refactors, ensuring the context trail accompanies meaningful commits and deployments across all standard development workflows.

How do I record a decision after a successful commit?

You record a decision after a successful commit by responding to the after-commit prompt. The automation offers specific commands to add decisions and learnings, persisting the rationale directly alongside the newly committed code changes.

Why should I attach context to commit messages?

You should attach context to commit messages because they often lose the reasoning behind design choices. Attaching contextual decisions and learnings ensures future teammates understand the context and rationale accompanying the code changes.