<h3 align="center">
  <img src="https://raw.githubusercontent.com/catppuccin/catppuccin/main/assets/logos/exports/1544x1544_circle.png" width="100" alt="Catppuccin logo"/><br/>
  Catppuccin for <a href="https://pi.dev">Pi</a>
</h3>

<p align="center">Soothing pastel themes for the Pi coding agent.</p>

<p align="center">
  <img src="assets/preview.svg" alt="All four Catppuccin flavors in Pi"/>
</p>

## Previews

<details>
<summary>🌻 Latte</summary>
<img src="assets/latte.svg" alt="Catppuccin Latte preview"/>
</details>
<details>
<summary>🪴 Frappé</summary>
<img src="assets/frappe.svg" alt="Catppuccin Frappé preview"/>
</details>
<details>
<summary>🌺 Macchiato</summary>
<img src="assets/macchiato.svg" alt="Catppuccin Macchiato preview"/>
</details>
<details>
<summary>🌿 Mocha</summary>
<img src="assets/mocha.svg" alt="Catppuccin Mocha preview"/>
</details>

## Installation

### Local Pi package

Clone this repository, then install its absolute path:

```bash
git clone https://github.com/catppuccin/pi.git
cd pi
pi install "$PWD"
```

Use `pi install -l "$PWD"` instead to register it only for the current project. Pi may ask you to trust a project before loading project-local resources.

### Manual

Copy one or all theme files into Pi's global theme directory:

```bash
mkdir -p ~/.pi/agent/themes
cp themes/catppuccin-*.json ~/.pi/agent/themes/
```

If `PI_CODING_AGENT_DIR` is set, use `$PI_CODING_AGENT_DIR/themes/` instead.

### npm

Install the published package with:

```bash
pi install npm:catppuccin-pi
```

## Usage

Choose a flavor from `/settings`, or start one session without changing saved settings:

```bash
pi --use-theme catppuccin-mocha
```

Follow terminal light/dark appearance automatically:

```bash
pi --use-theme catppuccin-latte/catppuccin-mocha
```

Frappé or Macchiato can replace Mocha in that pair. For a file checked out locally without package installation:

```bash
pi --theme ./themes/catppuccin-mocha.json --use-theme catppuccin-mocha
```

Pi hot-reloads the active custom theme when its file changes. A truecolor terminal is recommended; check that `$COLORTERM` is `truecolor` or `24bit`.

## Supported flavors

| Flavor | Theme name | Appearance |
|---|---|---|
| Latte | `catppuccin-latte` | Light |
| Frappé | `catppuccin-frappe` | Dark |
| Macchiato | `catppuccin-macchiato` | Dark |
| Mocha | `catppuccin-mocha` | Dark |

## Compatibility

Themes target the Pi 0.84.2 theme contract and include all 55 color tokens known to that release, including optional search, scrollbar, and maximum-thinking colors. New optional Pi tokens retain Pi's documented fallbacks until this port adopts them.

Bash and Readline do not parse theme files. Pi owns shell execution and line editing; this package only sets Pi's `bashMode` border color. It therefore has no shell-version-specific branches.

## Development

Requirements: Node.js 20 or newer and npm.

```bash
npm ci
npm run generate       # regenerate themes
npm run previews       # regenerate SVG previews
npm run check          # unit, schema, provenance, contrast, and freshness checks
npm run smoke:pi       # offline load test using the installed pi executable
npm pack --dry-run     # inspect the distributable package
```

Generated JSON and SVG files are committed and must not be edited manually. See [the maintenance guide](docs/maintenance.md), [validation evidence](docs/visual-validation.md), and [implementation plan](PLAN.md).

## 💝 Thanks to

- The [Catppuccin](https://github.com/catppuccin/catppuccin) community.
- The [Pi](https://github.com/earendil-works/pi) maintainers.

&nbsp;

<p align="center">
  <img src="https://raw.githubusercontent.com/catppuccin/catppuccin/main/assets/footers/gray0_ctp_on_line.svg" alt="Catppuccin footer"/>
</p>

<p align="center">
  Copyright © 2026 Catppuccin contributors
</p>

<p align="center">
  <a href="LICENSE">MIT License</a>
</p>
