npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

prflow

v1.0.1

Published

AI-powered CLI tool for creating beautiful, template-aware pull requests

Downloads

24

Readme

PRflow ✈️

AI-powered CLI for creating beautiful, template-aware pull requests

npm version License: MIT Node.js TypeScript

PRflow streamlines your pull request workflow by intelligently generating PR descriptions from your commits, filling in templates automatically, and remembering your team's preferences.

✨ Features

  • 🤖 AI-Powered Descriptions - Generate PR descriptions using OpenAI, Anthropic, or local Ollama
  • 📝 Template-Aware - Automatically detects and fills your PR template
  • 🎫 Ticket Detection - Auto-detects Jira, Linear, GitHub Issues, and 6 more PM tools from branch names
  • 🧠 Team Learning - Remembers your frequently used reviewers and labels
  • 📋 Conventional Commits - Understands and leverages conventional commit format
  • 👀 Preview Mode - Review your PR before creating
  • 🔍 Dry Run - See what would happen without creating the PR
  • Pre-flight Checks - Catch common mistakes before they happen
  • CI/CD Ready - Non-interactive mode for automation
  • ✏️ Editor Integration - Edit descriptions in vim, nano, or VS Code
  • 🔌 Offline Mode - Works without AI when needed

🚀 Quick Start

# Install globally
npm install -g prflow

# Or use npx (no install needed)
npx prflow

# Create a PR (from your feature branch)
prflow

# Or use the short alias
prf

📖 Usage

Create a Pull Request

# Basic usage - creates PR from current branch to main
prflow

# Specify base branch
prflow develop

# Create as draft
prflow --draft

# Preview before creating
prflow --preview

# Skip AI generation
prflow --no-ai

# Dry run - see what would be created
prflow create --dry-run

# Non-interactive mode (for CI/CD)
prflow create --yes --title "Auto PR" --body "Automated PR"

# Skip pre-flight checks
prflow create --skip-checks

# Verbose output
prflow create --verbose

All Create Options

prflow create [base] [options]

Options:
  -d, --draft                Create as draft PR
  -p, --preview              Preview PR before creating
  --no-ai                    Skip AI description generation
  -t, --title <title>        PR title
  -b, --body <body>          PR description body
  -a, --assignee <users...>  Assignees
  -r, --reviewer <users...>  Reviewers
  -l, --label <labels...>    Labels
  --dry-run                  Show what would be created without actually creating
  -y, --yes                  Non-interactive mode - use defaults
  --verbose                  Show detailed output
  --skip-checks              Skip pre-flight checks
  --update                   Update existing PR if one exists

Check PR Status

# Check if a PR exists for current branch
prflow status

# Open PR in browser
prflow open

Configuration

# Interactive configuration wizard
prflow config

# Show current configuration
prflow config --show

# Configure globally
prflow config --global

# Configure for current project
prflow config --local

# Clear team learning data
prflow config --clear-learning

Initialize in a Repository

# Create .prflowrc.json
prflow init

# Also create a PR template
prflow init --template

✅ Pre-flight Checks

Before creating a PR, prflow validates:

  • ✓ Not on protected branch (main/master)
  • ✓ No uncommitted changes
  • ✓ Commits ahead of base branch
  • ✓ GitHub token configured
  • ✓ Remote repository configured
  • ✓ Branch pushed to remote
# Example output when checks fail
❌ Pre-flight check failed:
1. You are on the base branch (main). Create a feature branch first:
   git checkout -b feature/my-feature

2. You have uncommitted changes. Please commit or stash them first:
   git add . && git commit -m "your message"

🎫 Project Management Integration

PRflow auto-detects tickets from your branch names:

| Tool | Branch Pattern | Detected | |------|---------------|----------| | Jira | feature/PROJ-123-desc | PROJ-123 | | Linear | fix/ENG-456-bug | ENG-456 | | GitHub Issues | feature/123-desc | #123 | | Shortcut | feature/sc-789-story | sc-789 | | ClickUp | fix/CU-abc123-task | CU-abc123 | | Azure DevOps | feature/AB#12345-work | AB#12345 | | Asana | Task IDs | Supported | | Trello | Card IDs | Supported | | Notion | Page IDs | Supported |

Configure your PM tool in .prflowrc.json:

{
  "projectManagement": {
    "tool": "jira",
    "baseUrl": "https://yourcompany.atlassian.net",
    "projectKey": "PROJ"
  }
}

⚙️ Configuration

PRflow looks for configuration in this order:

  1. .prflowrc.json in current directory
  2. .prflowrc.yaml in current directory
  3. prflow key in package.json
  4. Global ~/.prflowrc.json
  5. Environment variables

Example Configuration

{
  "ai": {
    "provider": "openai",
    "model": "gpt-4o"
  },
  "editor": "vim",
  "defaults": {
    "assignSelf": true,
    "draft": false,
    "labels": [],
    "reviewers": []
  },
  "projectManagement": {
    "tool": "jira",
    "baseUrl": "https://company.atlassian.net"
  }
}

Environment Variables

| Variable | Description | |----------|-------------| | GITHUB_TOKEN | GitHub personal access token (required) | | GH_TOKEN | Alternative GitHub token variable | | OPENAI_API_KEY | OpenAI API key | | ANTHROPIC_API_KEY | Anthropic API key |

🤖 AI Providers

OpenAI (Default)

{
  "ai": {
    "provider": "openai",
    "model": "gpt-4o"
  }
}

Anthropic (Claude)

{
  "ai": {
    "provider": "anthropic",
    "model": "claude-sonnet-4-20250514"
  }
}

Ollama (Local - Free)

{
  "ai": {
    "provider": "ollama",
    "model": "llama3.2",
    "baseUrl": "http://localhost:11434"
  }
}

Offline Mode

{
  "ai": {
    "provider": "none"
  }
}

Or use the --no-ai flag:

prflow --no-ai

📝 PR Templates

PRflow automatically detects templates in these locations:

  • .github/PULL_REQUEST_TEMPLATE.md
  • .github/pull_request_template.md
  • PULL_REQUEST_TEMPLATE.md
  • docs/PULL_REQUEST_TEMPLATE.md

When a template is found, PRflow will:

  1. Parse all sections (Description, Impact, etc.)
  2. Detect checkboxes and type selections
  3. Fill in content intelligently using AI
  4. Preserve your template structure

🧠 Team Learning

PRflow remembers your preferences:

  • Reviewers - Frequently selected reviewers appear first with ⭐
  • Labels - Often-used labels are prioritized

Data is stored locally and persists across sessions.

🎯 Workflow Example

# 1. Create a feature branch with ticket
git checkout -b feature/PROJ-123-user-authentication

# 2. Make commits (conventional commits work best)
git commit -m "feat(auth): add JWT token validation"
git commit -m "feat(auth): implement login endpoint"
git commit -m "test(auth): add authentication tests"

# 3. Create PR with PRflow
prflow

# PRflow will:
# ✅ Detect ticket PROJ-123 from branch name
# ✅ Analyze your commits
# ✅ Generate AI description
# ✅ Fill in your PR template
# ✅ Link to Jira ticket
# ✅ Suggest relevant labels
# ✅ Show frequent reviewers first
# ✅ Create the PR with all metadata

🔧 CI/CD Integration

Use prflow in your CI pipelines:

# GitHub Actions example
- name: Create PR
  env:
    GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
  run: |
    npx prflow create \
      --yes \
      --title "Auto: Update dependencies" \
      --body "Automated dependency update" \
      --label "dependencies" \
      --draft

🛠️ Development

# Clone the repository
git clone https://github.com/hempun10/test-pr-pilot.git
cd test-pr-pilot

# Install dependencies
npm install

# Build
npm run build

# Run tests
npm test

# Run in development
npm run dev

# Link for local testing
npm link

🧪 Testing

# Run all tests
npm test

# Watch mode
npm run test:watch

📄 License

MIT © hempun10