This guide will get you up and running with prw in under 5 minutes.
- Go 1.22+ installed (or download a prebuilt release)
- A GitHub Personal Access Token with
reposcope - Git (for cloning)
curl -LO https://github.com/devblac/prw/releases/latest/download/prw_$(uname -s | tr '[:upper:]' '[:lower:]')_amd64.tar.gz
tar -xzf prw_*_amd64.tar.gz
chmod +x prw_*_amd64
mv prw_*_amd64 /usr/local/bin/prw
prw version# Clone the repository
git clone https://github.com/devblac/prw.git
cd prw
# Build and install
make build
make installThe binary will be available at ./bin/prw (or prw in your PATH if you ran make install).
- Go to https://github.com/settings/tokens
- Click "Generate new token" (classic)
- Give it a name like "prw CLI"
- Select scope:
repo(or justpublic_repofor public repositories) - Click "Generate token"
- Copy the token (starts with
ghp_)
Option A: Environment variable (recommended)
# Linux/macOS
export GITHUB_TOKEN="ghp_your_token_here"
# Windows PowerShell
$env:GITHUB_TOKEN="ghp_your_token_here"Option B: Config file
./bin/prw config set github_token "ghp_your_token_here"./bin/prw watch https://github.com/owner/repo/pull/123The tool will fetch the PR and add it to your watch list.
./bin/prw list./bin/prw runThis starts polling GitHub every 20 seconds. When a PR's CI status changes, you'll see:
🔔 Status Change Detected!
PR: owner/repo#123
Title: Add new feature
Status: pending → success
Link: https://github.com/owner/repo/pull/123
Time: 2025-12-06T10:32:15Z
Press Ctrl+C to stop.
One-time check and exit:
./bin/prw run --once./bin/prw unwatch https://github.com/owner/repo/pull/123Announce the current status of all watched PRs to Slack/Discord (or any webhook):
prw broadcast --filter all --webhook https://hooks.slack.com/services/...--filter:all,changed, orfailing--dry-run: preview without sending- Uses the webhook in config unless
--webhookoverrides it
Generate completion scripts:
./bin/prw completion bash # or zsh|fish|powershellAdd the output to your shell profile to enable autocomplete.
- Sample config:
examples/config.example.json - Sample env file:
examples/env.example
# Poll every 30 seconds instead of 20
./bin/prw config set poll_interval_seconds 30Get desktop notifications without hosting a webhook:
# Enable via flag
./bin/prw run --notify-native
# Or persist in config
./bin/prw config set notification_native truePlatform requirements:
- macOS: Uses
osascript(built-in) - Linux: Requires
notify-send(install vialibnotify-binpackage) - Windows: Uses PowerShell (built-in)
Send notifications to Slack, Discord, or any HTTP endpoint:
./bin/prw config set webhook_url "https://hooks.slack.com/services/YOUR/WEBHOOK/URL"When a status changes, prw will POST a JSON payload like:
{
"type": "pr_status_change",
"owner": "owner",
"repo": "repo",
"pr_number": 123,
"title": "Add new feature",
"previous_state": "pending",
"current_state": "success",
"sha": "abc123def456",
"url": "https://github.com/owner/repo/pull/123",
"timestamp": "2025-12-06T10:32:15Z"
}./bin/prw config show- Multiple PRs: You can watch as many PRs as you want from different repositories
- State persistence: Your watch list persists between runs (stored in
~/.prw/config.json) - Token security: The config file has restrictive permissions (0600), but prefer using the environment variable
- Rate limits: Default polling (20s) is conservative. Be careful with aggressive intervals
Make sure you've set the token via environment variable or config file (see Setup section).
- Check that the PR URL is correct
- Verify your token has access to the repository (especially for private repos)
- Reduce your polling interval:
prw config set poll_interval_seconds 30 - Use a dedicated token if you run multiple instances
Make sure you have Go 1.22+ and have run:
go mod download- Read the full README.md for detailed documentation
- Check CONTRIBUTING.md if you want to contribute
- Review SECURITY.md for security best practices
- Open an issue on GitHub for bugs or feature requests
- Check existing issues for solutions
- Read the README for detailed usage information
Happy PR watching! 🚀