Getting Started
Get DiffPulse running in your repository in under two minutes. You'll scaffold a policy file, verify your environment, and evaluate a feature branch diff.
Prerequisites
- Node.js 20 or later
- Git repository with at least one commit
Install
Add DiffPulse as a dev dependency:
npm install -D @diffpulse/cli Or run commands directly with npx — no install required.
Initialize
Scaffold your policy file and GitHub workflow template:
npx @diffpulse/cli init This creates:
.diffpulse/policy.yaml— check and threshold configuration.github/workflows/diffpulse.yml— CI workflow template
Verify your environment
npx @diffpulse/cli doctor Doctor checks Node.js version, git availability, repository status, and policy file validity.
Run your first check
DiffPulse compares commits between a base ref and HEAD. For
meaningful results, work on a feature branch:
git checkout -b my-change
# ... edit files, commit ...
npx @diffpulse/cli check
On your default branch with no divergence, check may report
zero changed files. Use a feature branch or pass --base <ref>.
Validate your policy
npx @diffpulse/cli config validate