Skip to content
← Back to writing

How to ship lots of pull requests without a big CI bill

AI agents can open dozens of pull requests a day. Here is how my factory checks every one of them, decides who has to look, and keeps the build bill down, with the real numbers from November.

THE IDEA / AT A GLANCE

See the argument.

  1. 01 / Problem

    What breaks

    Every check costs money each time it runs. AI agents push far more often than people, so check costs can grow until someone turns the checks off.

    Each cut removes runs that could not fail a change, such as builds Vercel had already cancelled. Production still builds from main and GitHub Actions still gates every pull request.

  2. 02 / Mechanism

    What changes

    A scroll story follows one pull request through CI: cheap checks for what the change touches on every push, the full suite on main and weekly, a merge gate on the exact commit, and production built only for the app that changed.

    A weekly cost report opens an issue when the daily average goes over budget, so the next waste shows up within a week instead of on the monthly bill.

  3. 03 / Evidence

    What supports it

    On 7 to 8 November the repository's GitHub Actions jobs billed 651 minutes in 24 hours. The merge gate billed 173 minutes for 16 minutes of real work.

    After three fixes on 8 November, Actions use per merged pull request fell from about 72 minutes to about 18.

  4. 04 / Boundary

    What it does not prove

    The 17 November preview change has not been measured over a full week yet. GitHub Actions use is still above the free allowance. The figures are for this site's repository, not a client system.

Sources behind this article 3
  1. 1. docs.github.com
  2. 2. vitest.dev
  3. 3. vercel.com

Explore the examples, reasoning and technical detail.

Read the explanation

Billed minutes against real work. Cut the waste, keep the check. Illustrated diagram.

The short answer

Make each pull request small, check only what it can affect, and run the full suite where it’s cheap: on main and once a week. The goal is never fewer checks. It’s checks cheap enough that nobody is tempted to skip them.

Scroll to follow one pull request from an agent’s push to production.

  1. 01 / 07

    One issue, one small pull request

    Small pull requests are cheap to check and easy to throw away. Each agent works one issue on its own branch.

    Pull request

    • Note: One issue
    • Note: One branch
    • Note: A few files changed

    212 pull requests merged from 1 to 17 November.

  2. 02 / 07

    No preview site unless asked

    Agents used to trigger about 100 preview builds a day per site, at 3 to 4 cents each. Now a preview builds only when a commit message asks for one.

    Vercel

    • Skipped: Preview: not requested
    • Passed: GitHub Actions still gates the PR
  3. 03 / 07

    Safeguards in about a minute

    Parse every changed file, lint the workflows, and check policy rules such as no unapproved scheduled jobs.

    Shipping safeguards

    • Passed: Every changed file parses
    • Passed: Workflow lint
    • Passed: Policy rules
  4. 04 / 07

    Only the tests the change can affect

    Vitest’s related mode follows imports, so a change runs the tests that import it. Browser and accessibility checks run only for the areas the files touch.

    Lightweight CI

    • Passed: Related unit tests
    • Passed: Browser checks: touched areas
    • Passed: Accessibility: light and dark
    • Skipped: Untouched areas: run on main
  5. 05 / 07

    The gate was the waste

    A five-second job that confirms the other checks passed. It woke on every Vercel status, including “build skipped”, and GitHub bills each run as a full minute. Now it ignores skip notices.

    Merge gate, 24 hours

    • Failed: 173 runs, 16 real minutes
    • Failed: 140 set off by Vercel statuses
    • Passed: Now ignores build-skipped

    7 to 8 November: 173 billed minutes for 16 real ones.

  6. 06 / 07

    Build only the app that changed

    A merge into main builds production only for the site it touched, then tests the live site.

    Production

    • Passed: Changed app: build and test live
    • Skipped: Unchanged app: no build

    About 7 to 10 US cents per production build.

  7. 07 / 07

    Everything else, once a week

    Every browser journey on desktop and phone, a crawl of every internal link, and the full unit suite. A cost report keeps an issue open while CI is over 150 minutes a day.

    Weekly

    • Passed: Full CI: every page, both widths
    • Passed: Link crawl: 115 URLs on 21 October
    • Failed: Cost report: still over budget

    After the first three cuts, Actions use per merged pull request fell from about 72 minutes to about 18.

Where one day’s minutes went

GitHub rounds every job up to a whole minute when it bills, so I measured a full day of billed and real minutes.

Billed GitHub Actions minutes by job, 24 hours, 7 to 8 November 2026 (651 in total)
  1. Wayrest build and business journeys30 runs, 260 real minutes 275 min
  2. Merge gate173 runs, 16 real minutes 173 min
  3. Lightweight CI41 runs 86 min
  4. Wayrest specialist checks31 runs 80 min
  5. Everything else25 runs 37 min

Source: Job timings from the GitHub Actions API, recorded when the change was made

Managed Software

Want help checking and releasing changes as you build?

How managed software works

What it costs

What the factory costs to run The repository behind this site and wayrest.com.au, November 2026.
ItemWhat it isCost
Production build One build of one site after a merge.About 7 to 10 US cents each.
Preview build A copy of the site for a branch.About 3 to 4 cents. Now only on request.
Hosting Serving the sites when nothing is building.About 73 cents a day.
GitHub Actions All CI checks, about 7,160 minutes from 1 to 17 November.Over the 2,000 free minutes. Still the biggest lever.
Analytics PostHog events, replays and errors.$0. About 1,800 of 1 million free events.

NoteHosting averaged $3.79 a day from 30 October to 16 November, peaking at $10.42 on 8 November, almost all build time from agent branches. The target is about a dollar a day.

Vercel billing records, GitHub Actions run timings and PostHog usage, read 15 to 17 November 2026.

What I cut, and what I kept

Each cut removed runs that couldn’t fail anything. None removed a check that could.

CutWhat it removedWhat still runs
Gate ignores “build skipped”Runs that only read a skip noticeThe gate waits for every real check
Build only the changed appRebuilding every site on each mergeA production build for every real change
Previews only when askedA preview for every agent pushGitHub Actions on every pull request
Wayrest’s full browser suite on mainA 19-minute run on every pushAbout 3.5 minutes of checks per push

The preview change went live on 17 November and hasn’t run a full week yet, so there’s no savings figure for it. Vitest related mode and Vercel’s ignored build step do most of the work.

Questions to ask if you’re paying for software

How do you run CI on lots of AI pull requests without a big bill?

Keep each pull request small, run only the tests and browser checks its files can affect, run the full suite on main and weekly, and build previews and production only when needed.

What runs on every change?

If the answer is the full suite, sometimes, the gaps are where bugs get in. Something cheap should run every time.

Which changes can merge without a person, and why?

There should be a written risk rule. Low-risk changes merge on green checks; medium and high wait for a person.

What does checking cost each month, and who watches it?

A check nobody can afford is the first one switched off. A weekly cost report against a budget keeps it visible.

Scope: GitHub Actions, Vercel and PostHog usage for the repository behind calvinkennedy.com and wayrest.com.au, November 2026.

Newsletter

Short notes on building AI agents in production.

One email when something worth sharing ships. No fluff, no daily cadence, no recycled growth-thread noise.

Primary use: site updates, governed AI workflow lessons, and major project writeups.

Have a question or a different example?

Send a correction, ask about a decision, or share what happened in your own project.

Send a note