Skip to content

pierre-borckmans/pide

Repository files navigation

pide - IDE Integration for Pi

Shows your current IDE file/selection in pi and lets you quickly reference it with Ctrl+;.

screenshot

Setup

pi install npm:@pborck/pi-de

Then run /ide-setup in pi to install your IDE plugin:

setup

Usage

Select code in your IDE, then press Ctrl+; in pi to reference it:

usage

Installation

Pi Extension

# Install from npm
pi install npm:@pborck/pi-de

# Or from git
pi install github.com/pierre-borckmans/pide

IDE Plugins

Note: /ide-setup handles plugin installation automatically. The instructions below are for manual installation only.

Currently supported IDEs:

  • VS Code / Cursor / VSCodium
  • Neovim
  • IntelliJ IDEA
  • GoLand
  • WebStorm
  • PyCharm
  • CLion
  • Rider
  • RubyMine
  • PhpStorm
  • DataGrip
  • Android Studio
  • RustRover

VS Code / Cursor / VSCodium:

code --install-extension ./vscode-plugin/pide-vscode-0.1.0.vsix

Neovim (lazy.nvim):

{
  "pierre-borckmans/pide",
  config = function()
    require("pide").setup()
  end,
}

Neovim (packer.nvim):

use {
  "pierre-borckmans/pide",
  config = function()
    require("pide").setup()
  end,
}

JetBrains (IntelliJ, GoLand, WebStorm, PyCharm, etc.):

  1. Build: cd jetbrains-plugin && ./gradlew buildPlugin
  2. Install: Settings → Plugins → ⚙️ → Install from Disk → select build/distributions/pide-jetbrains-0.1.0.zip

Commands

commands

Command Description
/ide Insert file reference into editor
/ide-clear Clear the current selection
/ide-setup Install IDE plugin

How It Works

┌─────────────┐                      ┌──────────────────────────┐
│    IDE      │ ───── writes to ────▶│ ~/.pi/ide-selection.json │
│             │                      │                          │
└─────────────┘                      └───────────┬──────────────┘
                                                 │
                           ┌─────────────────────┼─────────────────────┐
                           │ file watch          │ file watch          │
                           ▼                     ▼                     ▼
                    ┌─────────────┐       ┌─────────────┐       ┌─────────────┐
                    │  pi (term1) │       │  pi (term2) │       │  pi (term3) │
                    └─────────────┘       └─────────────┘       └─────────────┘

All pi instances see the selection via file-based communication. No port conflicts!

JSON Format

IDEs write to ~/.pi/ide-selection.json:

{
  "file": "/absolute/path/to/file.ts",
  "selection": "selected text (optional)",
  "startLine": 10,
  "endLine": 15,
  "ide": "vscode",
  "timestamp": 1707570000000
}

Building IDE Plugins

VS Code

cd vscode-plugin
npm install
npm run compile
npm run package

Neovim

No build step required! The plugin is pure Lua. For development:

# Symlink to your nvim config for testing
ln -s $(pwd)/nvim-plugin ~/.local/share/nvim/site/pack/pide/start/pide

JetBrains

cd jetbrains-plugin
./gradlew buildPlugin

License

MIT

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

No packages published