dot_claude/skills/apm-usage/SKILL.md
Use APM (Agent Package Manager) to manage agent skills and dependencies. Use when adding, removing, or updating skills in a project or globally, creating skills for a repository, or configuring apm.yml.
npx skillsauth add mizchi/chezmoi-dotfiles apm-usageInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
APM is a dependency manager for AI agent skills, instructions, prompts, and MCP servers. Think of it as npm for agent configuration.
# Install all dependencies from apm.yml
apm install
# Install a specific package
apm install owner/repo
apm install owner/repo/skills/skill-name # subdirectory skill
apm install owner/repo#v1.0.0 # pinned version
# Global (user-scope) install → ~/.claude/skills/
apm install -g owner/repo/skills/skill-name
# Update all to latest
apm install --update # project scope
apm install -g --update # global scope
# Remove
apm uninstall owner/repo
apm uninstall -g owner/repo
# Inspect
apm deps list # project deps
apm deps list -g # global deps
apm deps tree # dependency tree
apm deps tree -g
# Security scan
apm audit
# Dry run (preview without changes)
apm install --dry-run
name: my-project
version: 1.0.0
dependencies:
apm:
# GitHub shorthand
- owner/repo
- owner/repo#v1.0.0 # pinned tag
- owner/repo/skills/skill-name # subdirectory
# Non-GitHub hosts
- gitlab.com/org/repo
- git: [email protected]:org/repo.git
path: skills/my-skill
ref: main
# Local path (dev only, not for -g)
- ./packages/my-skill
mcp:
- io.github.github/github-mcp-server
scripts: {}
scripts: の実例scripts: は name → command のマップ。apm install 後の setup、開発中のワンショット処理を登録する:
scripts:
postinstall: "echo 'skills installed; restart Claude Code to pick them up'"
verify: "ls -1 .claude/skills | sort"
audit: "apm audit"
呼び出し: apm run <name>(例: apm run verify)。postinstall は apm install 成功時に自動実行される(hook)。ワンショット処理(例: apm run audit)は明示的に呼ぶ。
apm.lock.yaml) の運用apm install は apm.lock.yaml を生成する。再現性を担保するため:
apm.lock.yaml を commit する(チーム間で同じ skill version を解決するため)。node_modules の package-lock と同じ発想~/.apm/apm.lock.yaml は chezmoi で同期すると新マシンで同じ version が入るapm install --frozen-lockfile を使って drift を防ぐ(lockfile が manifest と一致しなければ fail)apm install --updatechezmoi で dotfiles を管理している場合、APM との境界:
| path | chezmoi | APM |
|---|---|---|
| ~/.apm/apm.yml | 管理(source にコピー) | 読む |
| ~/.apm/apm.lock.yaml | 管理(新マシン再現性のため) | 生成 |
| ~/.apm/apm_modules/ | ignore(大きいキャッシュ) | 管理 |
| ~/.claude/skills/<name>/ | ignore(APM-managed は chezmoi 対象外) | 展開先 |
chezmoi 側の .chezmoiignore に次を追加:
.apm/apm_modules
.claude/skills/<apm-managed-name>
自作 skill(chezmoi add で source にコピーしたもの)とは名前が衝突しないよう注意。衝突時は APM が install 時に上書きする。詳細は chezmoi-management skill を参照。
Follow the agentskills.io open standard. Publishing-focused guide (repo layout, tag/release, dependency declaration, verification checklist) is in references/publishing.md.
my-repo/
└── skills/
└── my-skill/
├── SKILL.md # Required
├── scripts/ # Optional: executable code
├── references/ # Optional: detailed docs
└── assets/ # Optional: templates, resources
---
name: my-skill
description: One-line description of what this skill does and when to use it.
---
# Skill body
Instructions for the AI agent. Keep under 500 lines.
Move detailed reference material to references/ directory.
| Field | Required | Constraints |
|-------|----------|-------------|
| name | Yes | 1-64 chars, lowercase alphanumeric + hyphens, must match directory name |
| description | Yes | 1-1024 chars, describe what + when |
| license | No | SPDX identifier or license file reference |
| compatibility | No | Environment requirements (max 500 chars) |
| metadata | No | Arbitrary key-value pairs |
--)apm install owner/my-repo/skills/my-skill
my-library/
├── skills/
│ └── my-library-guide/
│ └── SKILL.md
├── src/
└── package.json
my-org-skills/
├── skill-a/
│ └── SKILL.md
├── skill-b/
│ └── SKILL.md
└── skill-c/
└── SKILL.md
Users install individually: apm install owner/my-org-skills/skill-a
APM auto-detects deployment targets from project structure:
| Directory exists | Target | Skills deployed to |
|-----------------|--------|-------------------|
| .claude/ | claude | .claude/skills/ |
| .github/ | copilot | .github/skills/ |
| .cursor/ | cursor | .cursor/skills/ (if supported) |
| .codex/ | codex | .agents/skills/ |
Override with --target claude or set target: in apm.yml.
| | Project (apm install) | Global (apm install -g) |
|---|---|---|
| Manifest | ./apm.yml | ~/.apm/apm.yml |
| Modules | ./apm_modules/ | ~/.apm/apm_modules/ |
| Lockfile | ./apm.lock.yaml | ~/.apm/apm.lock.yaml |
| Deploy to | ./.claude/skills/ | ~/.claude/skills/ |
| Local .apm/ content | Deployed | Skipped |
For private repos, APM resolves auth automatically:
gh auth login (GH_TOKEN) — zero-config if already logged ingit credential fill — OS keychain, SSH keysGITHUB_APM_PAT environment variable — for CI or explicit setupNo extra configuration needed if gh auth login is done.
apm install --force overwrites local files on collisiontools
Use when working on github.com/mizchi/pkspec, especially release readiness, version bumps, GitHub Actions/Nix release checks, adapter DSL work, or the experimental Playwright/Vitest coverage presets. Covers the repo's spec gates, pkfire release flow, pkl CLI dependency gotchas, and what is intentionally still experimental.
data-ai
指定されたリポジトリ、複数リポジトリ、または GitHub organization から、ドメイン固有の専門用語、業界用語、社内・プロダクト用語、リポジトリ実装マップ、技術構成、オンボーディング向け Mermaid 構成図を抽出・生成するときに使う。ユーザーが「用語集を作る」「ドメイン辞書を作る」「オンボーディング資料にする」「repo/org を見て専門用語をまとめる」「AI が再確認しなくてよい知識ベースを作る」と依頼したら起動する。
development
Guide for writing MoonBit bindings to JavaScript using `extern "js"`. Use when adding FFI declarations against browser/Node/Deno APIs or npm packages, wrapping JS objects behind opaque types, bridging Promises with `async fn` and `Promise::wait()`, configuring `moon.pkg` exports for esm/cjs/iife output, or handling null/undefined at the JS boundary.
testing
技術記事の再現性 (読者が手元で再現できるか) を評価するスキル。subagent に「初見の読者として手元で再現を試みる」シミュレーションをさせ、足りない情報をリストアップさせる。記事ドラフトの最終チェック、または公開後フィードバック前の事前検証で使う。