Features

Plugin System

Extend gh-please with custom plugins

Plugin System

The gh-please plugin system allows you to extend functionality with custom command groups and providers.

Plugin Management

List Installed Plugins

gh please plugin list

Output:

Installed plugins:
- @pleaseai/gh-please-ai (0.1.0) - AI-powered code review and issue automation

Install Plugin

gh please plugin install <plugin-name>

Example:

gh please plugin install ai

Uninstall Plugin

gh please plugin uninstall <plugin-name>

Available Plugins

@pleaseai/gh-please-ai (Premium)

AI-powered code review and issue automation.

Features:

  • Initialize PleaseAI configuration (.please/config.yml)
  • AI-powered code review
  • Issue triage → investigate → fix workflow
  • Code review automation with severity thresholds

Installation:

gh please plugin install ai

Commands:

# Initialize configuration
gh please init

# AI workflows
gh please ai triage 123
gh please ai investigate 123
gh please ai fix 123
gh please ai review 456
gh please ai apply 456

Documentation: See Available Plugins for details.

Plugin Development

Want to create your own plugin? See the Plugin Development Guide.

Plugin Types

  1. Command Group - Adds new command groups
  2. Provider - Provides services to other plugins
  3. Utility - Helper functions and tools

Plugin Interface

export interface GhPleasePlugin {
  name: string
  version: string
  type: PluginType
  registerCommands: () => Command[]
  init?: () => Promise<void>
  metadata?: PluginMetadata
}

Discovery Mechanism

Plugins are discovered from:

  1. npm packages - Packages with ghPleasePlugin metadata in package.json
  2. Local plugins - ~/.gh-please/plugins/ directory

Example Plugin Structure

my-plugin/
├── package.json          # With ghPleasePlugin metadata
├── src/
│   ├── index.ts         # Plugin entry point
│   └── commands/        # Command implementations
└── README.md

package.json:

{
  "name": "@username/gh-please-myplugin",
  "version": "1.0.0",
  "ghPleasePlugin": {
    "type": "command-group",
    "description": "My custom plugin"
  }
}

Migration from v0.2.x

If upgrading from v0.2.x, AI commands have been moved to a separate plugin.

Before (v0.2.x):

gh please init
gh please review 456

After (v0.3.0):

# Install AI plugin first
gh please plugin install ai

# Then use AI commands
gh please init
gh please ai review 456

See Migration Guide for details.