AgentSkillsCN

pub-pipeline

当用户提出“出版我的软件包”“出版流水线”“让这个项目顺利出版”“我该如何出版这个项目”或仅提及出版而未明确指定生态体系时,可使用此技能。该技能会自动识别项目类型(R软件包、Python软件包或图书手稿),并引导用户前往相应的生态体系专属出版技能。

SKILL.md
--- frontmatter
name: pub-pipeline
description: "This skill should be used when the user asks to \"publish my package\", \"publication pipeline\", \"get this published\", \"how do I publish this\", or mentions publication without specifying an ecosystem. It detects the project type (R package, Python package, or book manuscript) and routes to the appropriate ecosystem-specific publication skill."

Publication Pipeline Router

Detect the current project type and route to the appropriate publication workflow.

Detection Logic

Check the current working directory for project type indicators:

CheckProject TypeRoute To
DESCRIPTION file with Package: fieldR package/r-publish (the r-pub-pipeline skill)
pyproject.toml or setup.py or setup.cfgPython package/pypi-publish (the pypi-publish skill)
.docx, .epub, .tex manuscript filesBook manuscript/kdp-publish (the kdp-publish skill)
Multiple types detectedAmbiguousAsk the user which workflow to run
None detectedUnknownAsk the user what they want to publish

Workflow

Step 1: Detect project type (Glob tool)

Search the current directory for:

  • DESCRIPTION (R package indicator — verify it contains a Package: field)
  • pyproject.toml, setup.py, setup.cfg (Python package indicators)
  • *.tex, *.docx, *.epub, manuscript/ directory (book indicators)

Step 2: Load user config (Read tool)

Read .claude/pub-pipeline.local.md if it exists. If missing, inform the user and offer to create one from the template at ${CLAUDE_PLUGIN_ROOT}/docs/user-config-template.md.

Step 3: Route

Based on detection, invoke the appropriate ecosystem skill. If the project type is ambiguous (e.g., both DESCRIPTION and pyproject.toml exist), present options to the user and ask which publication workflow to run.

Supported Ecosystems

EcosystemSkillsCommands
R packagescran-audit, joss-audit, joss-draft, r-pub-pipeline/cran-audit, /joss-audit, /joss-draft, /r-publish
Python packagespypi-publish/pypi-publish
Books (Amazon KDP)kdp-audit, kdp-listing, kdp-publish/kdp-audit, /kdp-listing, /kdp-publish

Reference Files

  • ${CLAUDE_PLUGIN_ROOT}/docs/user-config-template.md — Shared user config template