@joyanhui/pi-ext-float-term

Pi coding agent extension — floating terminal overlay (fish, lazygit, yazi, gcp) powered by node-pty

Packages

Package details

extension

Install @joyanhui/pi-ext-float-term from npm and Pi will load the resources declared by the package manifest.

$ pi install npm:@joyanhui/pi-ext-float-term
Package
@joyanhui/pi-ext-float-term
Version
1.0.4
Published
Aug 18, 2026
Downloads
312/mo · 17/wk
Author
joyanhui
License
MIT
Types
extension
Size
34 KB
Dependencies
0 dependencies · 2 peers
Pi manifest JSON
{
  "extensions": [
    "./float-term.ts"
  ]
}

Security note

Pi packages can execute code and influence agent behavior. Review the source before installing third-party packages.

README

@joyanhui/pi-ext-float-term

A pi extension providing floating terminal overlays powered by node-pty. Similar to Neovim's <leader>ft floating terminal.

Features

  • Floating fish shellCtrl+Alt+F opens an interactive fish terminal in an overlay
  • Floating lazygitCtrl+Alt+G opens lazygit in a floating terminal
  • Floating yaziCtrl+Alt+Y opens the yazi file manager
  • Floating gcpCtrl+Shift+Alt+G runs gcp (git conventional commits) then drops into fish
  • Exit gracefullyexit / Ctrl+D quits the shell and auto-closes; Ctrl+Space force-closes

Installation

pi install npm:@joyanhui/pi-ext-float-term

Or for a single session:

pi -e npm:@joyanhui/pi-ext-float-term

Requirements

  • pi coding agent (v0.x+)
  • node-pty is a native addon without Linux prebuilds; on Linux it must be compiled with node-gyp, so it needs node-gyp, python3, make, and g++.
  • The extension resolves node-pty at runtime from: local install, bun global (~/.bun/install/global), npm global, or the FLOAT_TERM_NODE_PTY env var pointing at a node-pty directory.
  • If the package installs with a warning (optional dependency failed), build node-pty once and either install it globally or point FLOAT_TERM_NODE_PTY at it.

Commands

Command Description
/float-fish Open floating fish terminal
/float-lazygit Open floating lazygit
/float-yazi Open floating yazi file manager

Shortcuts

Shortcut Action
Ctrl+Alt+F Floating fish shell
Ctrl+Alt+G Floating lazygit
Ctrl+Alt+Y Floating yazi
Ctrl+Shift+Alt+G Floating gcp (git commit + push)

gcp — Interactive Git Commit & Push

The gcp function (triggered via Ctrl+Shift+Alt+G) is an interactive helper for creating Conventional Commits and pushing them. It automates the git add . && git commit -m "..." && git push workflow.

How it works:

  1. Shows working tree overview — displays git status --short so you can review what will be staged
  2. Prompts for commit type — select from a numbered list of conventional commit types:
# Type Description
1 ✨feat A new feature
2 🐛fix A bug fix
3 📝docs Documentation only changes
4 💄style Formatting, whitespace, missing semicolons (no logic change)
5 ♻️refactor Code refactoring (neither feat nor fix)
6 ⚡perf Performance improvement
7 ✅test Adding or modifying tests
8 👷build Build system, dependencies, CI configuration
9 🔧chore Maintenance, tooling, config files, gitignore
10 ⏪revert Revert a previous commit
11 🔄update Dependency updates, toolchain version bumps, library upgrades
  1. Prompts for commit description — enter a short summary (required)
  2. Executes — runs git add . then git commit -m "<type>: <description>" then git push

The function defaults to type ✨feat (option 1) if you press Enter without selecting a number.

Requirements

  • pi coding agent (v0.x+)
  • node-pty (included as dependency, auto-installed)

Documentation

For more information, visit dev.leiyanhui.com/ai/pi-float-term.

For source code, visit github.com/joyanhui/pi-extension.

License

MIT