Now liveThe Skillselion MCP - thousands of ranked skills, loaded into your agent mid-task. No install.Get it →
yinjialu avatar

Init Context

  • 1 installs
  • 3 repo stars
  • Updated July 5, 2026
  • yinjialu/context-harness

Initializes or repairs a context-harness personal context home, data directories, global context files, and optional Codex/Claude Code conversation-backup hooks.

About

Bootstraps the context-harness CLI runtime and sets up the personal context data home plus optional agent backup hooks. A developer uses it when setting up or repairing an automatic Code Agent conversation-context system.

  • Bootstraps the runtime via bundled script, pinned to v0.1.7
  • Installs Codex and Claude Code backup hooks at user or project scope

Init Context by the numbers

  • 1 all-time installs (skills.sh)
  • Ranked #2,479 of 3,282 Productivity & Planning skills by installs in the Skillselion catalog
  • Data as of Jul 8, 2026 (Skillselion catalog sync)
npx skills add https://github.com/yinjialu/context-harness --skill init-context

Add your badge

Show developers this skill is listed on Skillselion. Paste this into your README.

Listed on Skillselion
Installs1
repo stars3
Last updatedJuly 5, 2026
Repositoryyinjialu/context-harness

What it does

Initializes or repairs a context-harness personal context home, data directories, global context files, and optional Codex/Claude Code conversation-backup hooks.

Files

SKILL.mdMarkdownGitHub ↗

Init Context

Use this skill to initialize or repair a context-harness installation. The skill can bootstrap the CLI runtime even when only the skill was installed.

Runtime Bootstrap

Before running context-harness, execute the bundled bootstrap script from this skill directory:

runtime_dir="$(bash scripts/bootstrap.sh)"
cd "$runtime_dir"

The script clones or updates the runtime repository at ~/.local/share/context-harness by default, checks out v0.1.7, and runs uv sync.

Overrides:

  • CONTEXT_HARNESS_RUNTIME_DIR: custom runtime checkout path.
  • CONTEXT_HARNESS_REPO_URL: custom fork URL.
  • CONTEXT_HARNESS_REF: custom branch, tag, or commit.
  • CONTEXT_HARNESS_BOOTSTRAP_SKIP_UPDATE=1: skip fetch/pull.

Workflow

1. Run the Runtime Bootstrap steps above. Use the returned path as the context-harness repository root. 2. Choose the data home:

  • Use CONTEXT_HARNESS_HOME when set.
  • Use the user's explicit path when provided.
  • Otherwise use ~/.context-harness.

3. Run all uv run context-harness ... commands from the runtime repository root:

uv run context-harness --context-home <context-home> init

4. If the user wants automatic backup hooks, run these commands from the same repository root. Supported Code Agents install to user-level config by default. Use --scope project to install into the current project, or combine it with --project-root to target another project:

uv run context-harness --context-home <context-home> hooks install codex
uv run context-harness --context-home <context-home> hooks install codex --scope project
uv run context-harness --context-home <context-home> hooks install codex --scope project --project-root <codex-project-root>
uv run context-harness --context-home <context-home> hooks install claude-code
uv run context-harness --context-home <context-home> hooks install claude-code --scope project
uv run context-harness --context-home <context-home> hooks install claude-code --scope project --project-root <claude-code-project-root>

5. Report the data home and hook status.

Do not store user conversations or memory inside the context-harness repository unless the user explicitly chooses that path as the data home.

Related skills

This week in AI coding

Five minutes, every Monday - the tools, releases and tactics for developers.

unsubscribe anytime.