Skip to content

mturac/pluginpool-pr-storyteller

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

hero

pr-storyteller

Stop writing PR descriptions from a blank cursor. Generate a real one in seconds.

License: MIT Python 3.8+ Claude Code Plugin Tests: 6 passing

TL;DR: /pr-storyteller → PR title + summary + test plan, drafted from your actual commits and diff.

Writing

LinkedIn

Dev.to

Writing

Install (Claude Code)

git clone https://github.com/mturac/pluginpool-pr-storyteller ~/.claude/plugins/pr-storyteller

Restart Claude Code; the slash command /pr-storyteller appears.

Writing

Quick start

/pr-storyteller

Or invoke the helper directly:

python3 scripts/story.py
python3 scripts/story.py --base develop

Writing

Flags

Flag Default Description
--base main (falls back to master) Base branch to diff against

Writing

Example output (JSON)

{
  "commits": [
    {"hash": "abc1234", "subject": "feat(auth): rotate refresh tokens"},
    {"hash": "def5678", "subject": "test(auth): cover stale-token replay"}
  ],
  "files_changed": [
    {"path": "src/auth/refresh.py", "additions": 84, "deletions": 12},
    {"path": "tests/test_refresh.py", "additions": 41, "deletions": 0}
  ],
  "suggested_title": "feat(auth): rotate refresh tokens"
}

Claude turns that into:

### Summary
- Rotate the refresh-token secret on every successful refresh
- Reject stale refresh tokens that have already been redeemed

### Changes
- `src/auth/refresh.py` — token rotation + replay rejection
- `tests/test_refresh.py` — coverage for the replay path

### Test plan
- [ ] Successful login → both access and refresh tokens issued
- [ ] Reuse a refresh token → 401 + token family invalidated
- [ ] Clock skew tolerance still passes

Writing

How it works

  1. Reads git log <base>..HEAD for commits (hash + subject).
  2. Reads git diff --stat <base>..HEAD for changed files + additions/deletions.
  3. Suggests a title from the latest commit subject.
  4. Claude composes a real PR body from that scaffold.

Writing

Limitations

  • Doesn't fetch from the remote — make sure your local <base> is current.
  • Handles empty diffs and non-git directories gracefully (returns empty JSON).
  • Binary files surface via git diff --numstat and are reported with - for additions/deletions.

Writing

Examples

Step-by-step walkthroughs with real input fixtures and the helper's actual output live in examples/. Three or four scenarios per plugin — from the happy path to the edge cases the test suite guards.

Writing

Part of the pluginpool family

Ten focused Claude Code plugins for everyday productivity: commit-narrator · pr-storyteller · test-gap · deps-doctor · env-lint · secret-guard · standup-gen · todo-harvest · flaky-detector · changelog-forge

Writing

License

MIT — see LICENSE. Contributions welcome.

About

PR title + body + test plan generator from commits/diff vs base branch.

Topics

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors