Stop wasting Vercel preview builds on PRs that don't touch docs/site/.
| Scenario | Before | After |
|---|---|---|
PR touches docs/site/ | deploys | deploys |
PR touches only src/ | deploys (waste) | cancelled |
cc-snapshot PR (only shared/) | deploys (waste) | cancelled |
Override PR (only package.json) | deploys (waste) | cancelled |
| main branch push | deploys | deploys |
{
"git": { "deploymentEnabled": { "main": true } },
"github": { "silent": true, "autoJobCancelation": true },
"ignoreCommand": "git diff HEAD^ HEAD --quiet -- ."
}
Project root in Vercel dashboard is set to docs/site/. The ignoreCommand runs from there and exits 0 (skip) when no changes under that path. github.silent suppresses the inline PR comment.
~85% of Vercel preview builds. Only ~10–15 of ~120 monthly PRs touch docs/site/.