Strip Co-Authored-By trailers and "Generated with/by Claude" footers from a text blob. Read-only capability — emits cleaned text on stdout.
Scanned 5/27/2026
Install via CLI
openskills install acostanzo/quickstop---
name: strip-trailers
description: Strip Co-Authored-By trailers and "Generated with/by Claude" footers from a text blob. Read-only capability — emits cleaned text on stdout.
disable-model-invocation: true
allowed-tools: Bash
argument-hint: --text <text> | < stdin
---
# /commventional:strip-trailers
Engineering-ownership trailer-stripping capability. Mirrors the perl substitution chain that commventional v1.x's `PreToolUse` hook (`hooks/enforce-ownership.sh`) shipped, preserved as a consumer-invocable skill per ADR-006 §1 (capabilities, not automation).
The capability is read-only and idempotent: running twice on the same input produces identical output, and the only write is to stdout.
## Usage
Run the canonical script and emit its stdout verbatim:
```bash
bash "${CLAUDE_PLUGIN_ROOT}/bin/strip-trailers.sh" --text "<text>"
```
Or from stdin (for piping cleaned output into another tool):
```bash
printf '%s\n' "<text>" | bash "${CLAUDE_PLUGIN_ROOT}/bin/strip-trailers.sh"
```
Parse `$ARGUMENTS` for `--text "<text>"` and pass it through to the script. If `$ARGUMENTS` is empty, read the text the user wants cleaned (their next message, the contents of a file they named, or stdin if invoked programmatically).
Emit the script's stdout verbatim — it is the source of truth for the cleaned output. Do not re-format, do not add commentary.
## What it strips
- **`Co-Authored-By:` trailers** — case-insensitive on each word's first letter (`Co-Authored-By:`, `co-authored-by:`, `Co-authored-by:`, etc.)
- **`Generated with/by Claude` footers** — case-insensitive (`Generated with Claude Code`, `generated by claude`, etc.)
The substitution preserves trailing quote characters (`"` / `'` / `\`) when attribution appears inline in a shell-quoted command string, matching v1.x's behaviour exactly.
## Composition
This is a capability skill per ADR-006 §1. The consumer composes the trigger:
- **Wire it into your own commit-msg / pre-commit hook** — call this script from `.git/hooks/`.
- **Wire it into your own Claude Code `PreToolUse` hook** — write a `~/.claude/settings.json` entry that pipes the bash command payload through this script. The `/commventional:install-trailer-stripper` helper writes that wiring on demand.
- **Run it on demand** — invoke `/commventional:strip-trailers --text "..."` whenever you want a one-shot clean-up.
## Reference
- `bin/strip-trailers.sh` — the script this skill invokes.
- `test-fixtures/strip-trailers/cases.json` — fixture set proving byte-equivalence with v1.x's `enforce-ownership.sh` perl chain.
- ADR-006 §1 — capability/trigger boundary that motivates this skill's existence.
No comments yet. Be the first to comment!