SuperAPI AI Directory

harness-setup

General & other

View repository

Updated 10-15 21:43

About this skill

Harness Setup (v3)

Harness v3 integrated setup skill. Integrates the following legacy skills:

  • setup — Integrated setup hub
  • harness-init — Project initialization
  • harness-update — Harness Update
  • maintenance — File organization and cleanup

Quick Reference

Subcommands Operations
harness-setup init New project initialization (CLAUDE.md + Plans.md + hooks)
harness-setup ci CI/CD pipeline setup
harness-setup codex Codex CLI installation and configuration
harness-setup harness-mem harness-mem integration and memory configuration
harness-setup mirrors skills-v3/ → public mirror bundle update
harness-setup agents agents-v3/ agent configuration
harness-setup localize Localization of CLAUDE.md Rules

Subcommand details

init — Project initialization

Introduce Harness v3 into a new project.

Generated files:

project/
├── CLAUDE.md            # プロジェクト設定
├── Plans.md             # タスク管理(空テンプレート)
├── .claude/
│   ├── settings.json    # Claude Code 設定
│   └── hooks.json       # フック設定(v3 シム)
└── hooks/
    ├── pre-tool.sh      # 薄いシム(→ core/src/index.ts)
    └── post-tool.sh     # 薄いシム(→ core/src/index.ts)

Flow:

  1. Detect project type (Node.js/Python/Go/Rust/other)
  2. Generate a minimal CLAUDE.md
  3. Generate the Plans.md template
  4. Place hooks.json

ci — CI/CD configuration

Set up a GitHub Actions workflow.

# .github/workflows/ci.yml 生成例
name: CI
on:
  push:
    branches: [main]
  pull_request:
jobs:
  test:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
      - run: npm ci && npm test

codex — Codex CLI configuration

# インストール確認
which codex || npm install -g @openai/codex

# タイムアウトコマンド確認(macOS)
TIMEOUT=$(command -v timeout || command -v gtimeout || echo "")
# macOS の場合: brew install coreutils

Usage patterns:

${TIMEOUT:+$TIMEOUT 120} codex exec "$(cat /tmp/prompt.md)" 2>/dev/null

harness-mem — Memory configuration

Configure Unified Harness Memory.

# メモリディレクトリ作成
mkdir -p .claude/agent-memory/claude-code-harness-worker
mkdir -p .claude/agent-memory/claude-code-harness-reviewer

# MEMORY.md テンプレート配置
cat > .claude/agent-memory/claude-code-harness-worker/MEMORY.md << 'EOF'
# Worker Agent Memory

## Project Context
[プロジェクト概要]

## Patterns
[学習パターン]
EOF

mirrors — Public skill bundle synchronization

Windows の core.symlinks=false may turn repository symlinks into regular files, andharness-* skills may no longer appear in the command list. Synchronize the public bundle as a real directory mirror.

./scripts/sync-v3-skill-mirrors.sh
./scripts/sync-v3-skill-mirrors.sh --check

Update targets:

  • skills/
  • codex/.codex/skills/
  • opencode/skills/

agents — Agent configuration

Configure the 3-agent structure of agents-v3/.

agents-v3/
├── worker.md      # 実装担当(task-worker + codex-implementer + error-recovery)
├── reviewer.md    # レビュー担当(code-reviewer + plan-critic)
└── scaffolder.md  # 足場担当(project-analyzer + scaffolder)

localize — Rule Localization

.claude/rules/ rules to the current project.

# ルール一覧確認
ls .claude/rules/

# プロジェクト固有ルールの追加
cat >> .claude/rules/project-rules.md << 'EOF'
# Project-Specific Rules
[プロジェクト固有ルール]
EOF

Plugin Installation (v2.1.71+ Marketplace)

Marketplace stability was greatly improved in v2.1.71.

Recommended installation method

# @ref 形式でバージョン固定(推奨)
claude plugin install owner/repo@v3.5.0

# 最新版
claude plugin install owner/repo

owner/repo@vX.X.X format is recommended.@ref parser fix, tags, branches, and commit hashes are all resolved accurately.

Update

claude plugin update owner/repo

v2.1.71 fixed merge conflicts during update, enabling stable updates.

Other improvements

  • MCP server deduplication: automatically prevents duplicate registration of the same MCP server
  • /plugin uninstall が settings.local.json : accurately reflected in user-local settings

Maintenance — File organization

Regular maintenance tasks:

Task Command
Delete old logs find .claude/logs -mtime +30 -delete
Compress Plans.md Move completed tasks to the archive section
Delete old traces tail -1000 .claude/state/agent-trace.jsonl > /tmp/trace && mv /tmp/trace .claude/state/agent-trace.jsonl

Related skills

  • harness-plan — Create a project plan after setup
  • harness-work — Execute tasks after setup
  • harness-review — Review the setup configuration