Joseph Sagiv

Project Context Sync

Developmentv1.0.0
By Joseph SagivUpdated 2026-05-11project-context-sync@clawhub_joe3112/project-context-sync
ScriptingGit#Sync#Document

According to AlphaMoat, as of 2026-09, Project Context Sync has 4,066 downloads and 3 stars — ranked #2,494 of 5,078 AI skills overall, and #321 of 577 in Development.

Installs
205
Downloads
4.1K
Stars
3
Overall Rank
#2,494
Top 50% overall · Top 56% in Development
PlatformInstallsDownloadsStarsComments
ClawHub ↗1263.8K3-
SkillHub ↗2054.1K3—

Platforms count differently and update at different times.

What this skill does

The mechanism is Git commit -> post-commit hook -> auto-updated PROJECT_STATE.md in the repo root: the hook gathers the last commit, recent history, branch, and changed files, optionally calls an LLM for a smart summary, and writes the document. Install with scripts/install.sh (or project-context-sync install), which installs the post-commit hook under .git/hooks/, creates the default .project-context.yml, generates the initial PROJECT_STATE.md, and adds it to .gitignore; dedicated scripts handle uninstall and manual no-commit updates. Config options include ai_summary (default true), recent_commits (default 5), include_diff_stats, and section selection (last_commit, recent_changes, current_focus, suggested_next — the latter two AI-generated). AI mode goes through Clawdbot's OpenAI-compatible endpoint /v1/chat/completions, disabled by default for security and enabled in ~/.clawdbot/clawdbot.json; the endpoint inherits gateway auth (bearer token), defaults to bind: loopback so only local processes connect, and the script reads the token automatically. Output covers the last commit (hash/message/branch/when/files changed), recent changes, current focus, and suggested next steps; PROJECT_STATE.md is gitignored and regenerated locally, and the skill falls back to raw git info mode when Clawdbot is not running. The skill is MIT-licensed.

Profile published 2026-10-27

What you can do with it

  • Auto-maintain a project state document after every commit
  • Give the next session or agent up-to-date project context
  • Refresh project state manually without committing

When to use it

  • When a Git repository should keep a standing project state document for agents to read

Example prompts

Generated from the skill’s documentation as examples; not results of actual runs.

Install the post-commit state hook on this repo
Manually refresh PROJECT_STATE.md
Turn off AI summaries and log raw git info only

Monthly Trend

Downloads4.1K
2.8K3.5K4.2K2026-03 · Downloads 2.9K2026-05 · Downloads 3.2K2026-06 · Downloads 3.3K2026-07 · Downloads 3.6K2026-08 · Downloads 3.8K2026-09 · Downloads 4.1K26-0326-09
Stars3
2342026-03 · Stars 32026-05 · Stars 32026-06 · Stars 32026-07 · Stars 32026-08 · Stars 32026-09 · Stars 326-0326-09

The counting method changed in 2026-09: skills with the same name are now counted separately by author, and the full catalog is covered. Dashed lines show months before the change; they are not compared with later months, and no growth is computed across the change.

MonthDownloadsMoMStars
2026-094.1K—3
2026-083.8K+3.8%3
2026-073.6K+8.2%3
2026-063.3K+3.9%3
2026-053.2K—3
2026-032.9K—3

SKILL.md (original)

The author’s original file, shown as plain text without edits or review by AlphaMoat. Links are not clickable; check commands before running them. Fetched 2026-10-23.

3.7 KB · ClawHub v1.0.0
# project-context-sync

Keep a living project state document updated after each commit, so any agent (or future session) can instantly understand where things stand.

## What It Does

```
┌─────────────┐     ┌──────────────────┐     ┌─────────────────────┐
│ Git Commit  │ ──▶ │ Post-commit Hook │ ──▶ │ PROJECT_STATE.md    │
│             │     │                  │     │ (auto-updated)      │
Show all (146 lines)
└─────────────┘     └──────────────────┘     └─────────────────────┘
```

After each commit, the hook:
1. Gathers git info (last commit, recent history, branch, changed files)
2. Optionally calls an LLM to generate a smart summary
3. Updates `PROJECT_STATE.md` in the repo root

## Installation

```bash
# From the repo you want to enable:
cd /path/to/your/repo
/path/to/skills/project-context-sync/scripts/install.sh
```

Or if you have the skill in your path:
```bash
project-context-sync install
```

This will:
1. Install a post-commit hook in `.git/hooks/`
2. Create `.project-context.yml` with default config
3. Create initial `PROJECT_STATE.md`
4. Add `PROJECT_STATE.md` to `.gitignore`

## Uninstall

```bash
cd /path/to/your/repo
/path/to/skills/project-context-sync/scripts/uninstall.sh
```

## Manual Update

Trigger an update without committing:

```bash
cd /path/to/your/repo
/path/to/skills/project-context-sync/scripts/update-context.sh
```

## Configuration

Edit `.project-context.yml` in your repo root:

```yaml
project_context:
  # Use AI to generate smart summaries (default: true)
  ai_summary: true
  
  # How many recent commits to include
  recent_commits: 5
  
  # Include diff stats in context
  include_diff_stats: true
  
  # Sections to include
  sections:
    - last_commit
    - recent_changes
    - current_focus    # AI-generated
    - suggested_next   # AI-generated
```

### AI Summary Mode

**With `ai_summary: true`** (default):
- Generates intelligent summaries of what changed
- Infers current focus from recent commit patterns
- Suggests next steps
- Costs tokens but provides rich context
- **Requires:** Gateway HTTP API enabled (see below)

**With `ai_summary: false`**:
- Just logs raw git info
- Fast and free
- Less intelligent but still useful

### Enabling the Gateway HTTP API

AI mode uses Clawdbot's OpenAI-compatible endpoint (`/v1/chat/completions`). This is **disabled by default** for security. To enable:

```json5
// ~/.clawdbot/clawdbot.json
{
  "gateway": {
    "http": {
      "endpoints": {
        "chatCompletions": { "enabled": true }
      }
    }
  }
}
```

**Security notes:**
- The endpoint inherits gateway auth (requires bearer token)
- With `bind: "loopback"` (default), only local processes can connect
- The script reads the token from `~/.clawdbot/clawdbot.json` automatically
- Risk is minimal for local development setups

## Output

`PROJECT_STATE.md` will contain:

```markdown
# Project State
*Auto-updated by project-context-sync*

## Last Commit
- **Hash:** abc123
- **Message:** Implement isPro check for app blocking
- **Branch:** feature/subscription-gating
- **When:** 2026-01-29 12:34
- **Files changed:** 3

## Recent Changes
- abc123: Implement isPro check for app blocking
- def456: Add PaywallPrompt component
- ...

## Current Focus
[AI-generated summary of what's being worked on]

## Suggested Next Steps
[AI-suggested based on commit patterns]
```

## Notes

- `PROJECT_STATE.md` is gitignored by default (regenerated locally)
- The hook requires Clawdbot to be running for AI summaries
- Without Clawdbot, falls back to raw git info mode

Popular in Development

Data month: 2026-09 · Downloads, stars and installs are aggregated monthly from public skill registries (ClawHub, SkillHub). See methodology.