一键导入
wiki-rotate-log
Rotate wiki/log.md into a timestamped archive file when it grows past ~500 lines; create a fresh log.md with an archive-pointer header
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Rotate wiki/log.md into a timestamped archive file when it grows past ~500 lines; create a fresh log.md with an archive-pointer header
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
| name | wiki-rotate-log |
| description | Rotate wiki/log.md into a timestamped archive file when it grows past ~500 lines; create a fresh log.md with an archive-pointer header |
| category | wiki |
| model | claude-sonnet-4-6 |
Rotate wiki/log.md into a timestamped archive file (log-YYYY_MM_DD_HHMMSS.md) when it exceeds ~500 lines. Create a fresh wiki/log.md with an archive-pointer header. Never truncate — all content moves to the timestamped file.
The timestamp (to the second) makes every archive filename unique by construction, so repeated rotations never collide — no half-year or sequence-suffix logic needed.
Read wiki/log.md. Count the total number of lines.
Generate a timestamp to the second using Bash: date +%Y_%m_%d_%H%M%S.
The archive filename is log-<timestamp>.md — e.g. log-2026_06_14_153012.md. Because the timestamp is unique to the second, no collision check or suffix logic is needed.
Show the plan:
Log rotation plan:
Current: wiki/log.md (N lines)
Archive: wiki/log-2026_06_14_153012.md
New log: wiki/log.md (empty, with archive pointer)
The existing log.md will be renamed — no content is deleted.
Proceed? (yes / no)
Wait for confirmation.
wiki/log.md → wiki/log-<timestamp>.md using Bash mv.> Archives:). If present, carry them forward into the new log.wiki/log.md with:# Wiki Log
Append-only record of wiki operations — ingests, queries filed back, lint passes, scaffolding. **Never edit existing entries**; only append new ones at the bottom.
Entry format (consistent prefix keeps the log greppable — `grep "^## \[" log.md | tail -5`):
1–3 sentences on what happened.
Operations: `scaffold`, `ingest`, `query`, `lint`, `decision`, `task`, `bug`, `requirement`, `roadmap`, `archive`, `rotate`.
> Archives: [2026_06_14_153012](log-2026_06_14_153012.md)
---
## [YYYY-MM-DD] rotate | log.md rotated — N lines archived to log-<timestamp>.md
Previous log archived to log-<timestamp>.md. Fresh log started.
Replace <timestamp> with the actual timestamp and N with the entry count. The [YYYY-MM-DD] date prefix on the rotation entry stays date-only (matching all other log entries) — only the archive filename carries the full timestamp. If there were prior archive pointers, add them to the > Archives: line separated by ·.
Confirm rotation is complete:
Done. wiki/log.md rotated:
- N lines moved to wiki/log-2026_06_14_153012.md
- New wiki/log.md created with archive pointer
> Archives: header line in the new log.md must link to ALL prior archive files, not just the most recent one.log.md must be the rotation event itself.Update the ai-sdd framework binary + skills to the latest release — an apply-on-confirm wrapper that runs `ai-sdd update --check`, surfaces the current-to-latest version transition, and (only on explicit confirmation) runs `ai-sdd update` and lands a standalone reseed commit. Agent-agnostic (claude-code or codex). Use when a teammate wants to update / upgrade ai-sdd, sees the update-available notice, or invokes `/ai-sdd-update`.
Stand up (or refresh) an ai-sdd factory for a repository so any coding agent — claude-code, codex, … — can drive it. Discovers the repo's conventions, scaffolds the .ai-sdd/ home, authors worker skills + schemas, compiles the deterministic gates, and wires provider-neutral skill surfacing (AGENTS.md + per-agent symlinks). Use when onboarding a repo to ai-sdd or re-bootstrapping after the codebase/conventions drift.
Drive a software-factory run by dispatching a sub-agent per worker — the deterministic `ai-sdd` engine plans (next), a fresh sub-agent does each worker's work via its skill, the engine gates and advances (submit), and each completed slice is committed. Agent-agnostic (claude-code or codex). Use when asked to run, drive, continue, or advance a factory run / pipeline / orchestration, or when the user mentions `ai-sdd next` / `ai-sdd submit`.
Print the diagram-driven ai-sdd workflow cheatsheet — the canonical command sequence (bootstrap → plan → run, validate/next/submit/status) that travels with the binary. Use when a user forgets which command comes next, asks "how do I drive a run / what's the workflow", or needs the command reference without leaving the repo.
Turn a complete PROGRAM brief into a runnable master plan — a decision-closed program requirements doc and a master orchestration graph whose nodes are whole sub-features (kind:pipeline) sequenced by milestone validation gates with owners. The program tier above ai-sdd-plan. Requires a real program brief (refuses a one-liner) and human approval of the program requirements draft before emitting the graph. Use when planning a multi-feature, multi-person project in a bootstrapped repo (run ai-sdd-bootstrap first); each sub-feature is then planned with ai-sdd-plan. Re-run on an existing program to amend it in place (create-vs-amend is auto-detected from disk): append sub-features/milestones and rewire pending nodes; a started node (completed or in-flight) is immutable and corrected forward with a downstream `<node>-revert` node.
Turn a complete feature brief into a runnable plan for a bootstrapped repo — a decision-closed requirements doc and an orchestration graph (slices + depends_on) the engine executes. Requires a real brief (refuses a bare one-liner — asks for one) and human approval of the requirements draft before generating slices. The planning layer between an idea and ai-sdd-run. Use when starting a new feature in a repo that already has a .ai-sdd/ (run ai-sdd-bootstrap first). Re-run on an existing feature to amend it in place (create-vs-amend is auto-detected from disk): append slices and rewire pending ones; a started slice (completed or in-flight) is immutable and corrected forward with a downstream `<slice>-revert` slice.