@backnotprop/pi-move

Pi extension that adds /move session relocation with Git worktree support.

Packages

Package details

extension

Install @backnotprop/pi-move from npm and Pi will load the resources declared by the package manifest.

$ pi install npm:@backnotprop/pi-move
Package
@backnotprop/pi-move
Version
0.1.0
Published
Jun 5, 2026
Downloads
47/mo · 16/wk
Author
backnotprop
License
MIT
Types
extension
Size
29.3 KB
Dependencies
0 dependencies · 1 peer
Pi manifest JSON
{
  "extensions": [
    "./extensions/move-session.ts"
  ]
}

Security note

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

README

pi-move

Pi package that adds /move for relocating the current session to another directory or Git worktree.

Install

pi install npm:@backnotprop/pi-move

Development/local install:

pi -e ~/oss-agents/pi-move
pi install ~/oss-agents/pi-move

Git install:

pi install git:git@github.com:backnotprop/pi-move

Usage

/move <path>
/move --changes <path>
/move --new [name]
  • /move <path> updates the session working directory only.
  • /move --changes <path> transfers scoped tracked and untracked Git changes when moving to another worktree.
  • /move --new [name] creates a detached Git worktree at HEAD, then moves there.

New worktrees are created under:

~/.pi/agent/worktrees/<project-key>/<context-slug>

If no name is provided, the extension derives the slug from the session name and recent text messages. Existing directory collisions receive -2 through -10 suffixes.

Notes

  • Destinations must resolve to the same logical project.
  • Change transfer is scoped to the old session directory.
  • Source cleanup after a successful move uses git checkout -- . and git clean -fd -- . from the old session directory.
  • Moving within the same checkout updates the session location without transferring or cleaning changes.