Chaffbroom
Free & source availableRuns in your own CI

Less clutter and less CI spend left behind by every pull request.

Chaffbroom is two small, free GitHub Actions, source available under FSL-1.1-ALv2. Chaffbroom Winnow deletes orphaned preview environments. Chaffbroom Tollbook shows what GitHub Actions costs per pull request. Each is also a CLI and a TypeScript library. Both run on your own runner with your own tokens and send nothing anywhere.

GitHub Actions workflow (nightly sweep, plus reap on PR close)
on:
  schedule:
    - cron: "17 3 * * *"
  pull_request:
    types: [closed]
  workflow_dispatch:
    inputs:
      mode:
        description: plan or apply
        default: plan

permissions:
  # …

What it does

Preview environmentspr-101PR open · keptpr-102PR merged · deletedpr-879 days old · deleted Pull request #101 Actions cost, list price$0.42JobsRerunsCancelled
Chaffbroom Winnow deletes the previews nobody needs any more. Chaffbroom Tollbook puts what each pull request cost on the pull request.

How it works

  1. Run npx chaffbroom init to see the files it would write, then npx chaffbroom init --yes to write them (or copy an example workflow). Commit them.
  2. Add the provider tokens or secrets the product needs as repository secrets.
  3. Run it in report-only form first: Chaffbroom Winnow defaults to plan, Chaffbroom Tollbook can report without a budget.
  4. Turn on deletion or the budget gate once the output looks right.

Set it up with your coding agent

Ask your agent to set up Chaffbroom and try it. Paste this into any coding agent. It reads first, says what it will change and waits for your yes, never asks for a secret in the chat, and never deletes anything.

Set up Chaffbroom (https://github.com/chaffbroom/chaffbroom) in this repository and try it. Chaffbroom is two free tools, source available under FSL-1.1-ALv2, that run with my own tokens and send nothing anywhere: Winnow finds stale preview environments, Tollbook shows what GitHub Actions costs per pull request.

Rules:
- Before you add or edit any file, list the files and the change, and wait for my yes.
- Never ask me to paste a token or secret into this chat, and never print one. Use tokens already in the environment, or `gh auth token`. I add repository secrets myself.
- Read only: never run winnow apply, never post a comment, never open an issue.
- No key, account or payment is needed. Support and the org-wide report are Enterprise: chaffbroom@sivakoza.ai. Do not try to set those up.

Steps:
1. Use the npm package chaffbroom: `npx chaffbroom ...`. It is one bundled file with no dependencies and needs Node 20+; npx fetches it on first use (add --yes after npx if the shell cannot answer npx's question).
2. Tollbook: run npx chaffbroom tollbook weekly --repo <owner/name> --days 7 --top 5 --format json with GITHUB_TOKEN from `gh auth token` (it needs actions: read). Sum up the total cost, the top workflows and the rerun waste. Money is in micro-dollars, at list price.
3. Run npx chaffbroom init --dry-run and show me what it would write: .winnow.yml with the preview providers it found, and the workflows (Winnow starts in plan mode). If it found the wrong providers, run it again with --provider <id>. After my yes, run the same command with --yes instead of --dry-run, and show me the `gh secret set` lines it prints; I run those myself. Say that the jobs use GitHub Actions minutes, which GitHub bills on private repositories.
4. Once I have filled in the ids in .winnow.yml, run npx chaffbroom winnow plan --format json and report what would be deleted, and which providers were skipped for a missing token.

More prompts, one per tool: prompts.

Before you install

  • A GitHub repository where you can add workflows and repository secrets.
  • Node 20+ for npx chaffbroom or the library. The Actions run on node24, which is what GitHub runners provide.
  • For Chaffbroom Winnow: an API token for each provider you want swept, passed in as environment variables or Action inputs.
  • For Chaffbroom Tollbook: the job needs actions: read and pull-requests: write; the weekly issue needs issues: write.
  • Pin third-party actions to full commit SHAs, as the example workflows do.
  • What you pay, to GitHub and not to us: the Actions minutes these jobs use. They are free on public repositories and billed by GitHub on private ones. Provider and GitHub API calls use your own tokens and cost nothing.

Pricing

Free & source available

FreeAll of the code, in your own CI
  • Chaffbroom Winnow: the plan, the deletion and the on-close sweep.
  • Chaffbroom Tollbook: the PR comment, the budget gate and the per-repo weekly summary.
  • Both run on your runner with your own tokens and send nothing anywhere.
  • No account, no license key, no plan gate.

Enterprise

Contact usMonthly subscription, priced per organization
  • Support by email from the people who build Chaffbroom.
  • Later: a hosted weekly Chaffbroom Tollbook report across all your repositories. It is not built yet.
  • Everything in the free plan stays free.
  • Sold by contact: write to chaffbroom@sivakoza.ai and we agree the scope after a call.

Less clutter and less CI spend left behind by every pull request.