Skip to content

Catalog Guide

The catalog (ct) is a declarative package manager for pi. It manages packages via a cat.yaml file and syncs across machines using GitHub Gist.

Installation

bash
pi install npm:@pi-stef/catalog

Quick Start

bash
/ct login          # Authenticate with GitHub
/ct init           # Create cat.yaml
/ct add npm:@pi-stef/team   # Add a package
/ct sync           # Install + push to gist

Commands

CommandDescription
/ct syncPull, reconcile, install, push
/ct initInitialize cat.yaml
/ct init --from-gist=<id>Import catalog from a gist
/ct add <source>Add a package (name auto-derived)
/ct remove <name>Remove a package
/ct update <name>Update a package to latest
/ct update --allUpdate all packages
/ct enable <name>Enable a package
/ct disable <name>Disable a package
/ct toggle <name>Toggle enabled/disabled
/ct statusShow catalog status
/ct diffShow pending changes
/ct verifyVerify catalog integrity
/ct pushPush catalog to gist
/ct pullPull catalog from gist
/ct loginAuthenticate with GitHub
/ct profilesList all profiles
/ct profile <name>Show/switch active profile
/ct profile <name> --createCreate a new profile
/ct profile <name> --deleteDelete a profile
/ct resetReset catalog and lock file

cat.yaml Format

The catalog file (~/.pi/sf/catalog/cat.yaml) declares your packages:

yaml
meta:
  activeProfile: default

packages:
  azure-foundry:
    source: npm:@pi-stef/azure-foundry
    enabled: true
  cursor:
    source: npm:@pi-stef/cursor
    enabled: true
  team:
    source: npm:@pi-stef/team
    enabled: true
  web:
    source: npm:@pi-stef/web
    enabled: true
  figma:
    source: npm:@pi-stef/figma
    enabled: false

Package Fields

FieldRequiredDescription
sourceYesPackage source (e.g., npm:@pi-stef/team, git:github.com/user/repo)
typeNo"skill" or "pi-native"
enabledNotrue (default) or false
profileNoLabel for the package (annotation only)

Setup Detection

Some packages require additional setup (environment variables, CLI tools, config files). The catalog detects these requirements via .pi-setup.json files and warns you during install/update.

For example, the atlassian package needs:

json
{
  "env": ["ATLASSIAN_BASE_URL", "ATLASSIAN_EMAIL", "ATLASSIAN_API_TOKEN"]
}

If these are missing, /ct status shows a ⚠ setup incomplete warning.

Lock File

The catalog maintains a catalog.lock.json that tracks installed versions and sync state. This file is managed automatically — do not edit it manually.

Configuration Files

FileLocation
Catalog manifest~/.pi/sf/catalog/cat.yaml
Lock file~/.pi/sf/catalog/catalog.lock.json
Gist cache~/.pi/sf/catalog/.gist
Package config~/.pi/sf/<package>/config.json