# CLI

Every plumbago command and option.

## init

Sets Plumbago up in a React and Tailwind v4 project: writes plumbago.json, copies the theme next to your Tailwind CSS file and imports it, and adds the cn helper.

```sh
npx plumbago init
```

- `--css <path>`: Your Tailwind CSS file, when Plumbago can't find it.

- `--preset <code>`: Start with the look from a preset code, made on the Create page: accent (any color), grays, corners, density, menu style, font and heading font. Without it you get the Graphite defaults.

- `--force`: Set up again over an existing plumbago.json.

## apply

Restyles a project that already has Plumbago: rewrites the accent, grays, corners, density, menu style and fonts in your copy of the theme, and swaps the font import. Plumbago remembers the code in plumbago.json, so adding the theme again keeps the look.

```sh
npx plumbago apply a0000
```

## add

Copies components into components/ui, with the components and helpers they use, rewrites their imports for your project and installs missing packages. Files you've changed are kept.

```sh
npx plumbago add button sheet
```

- `--overwrite`: Replace files you've changed.

## list

Shows every component with its description. There are 43 right now.

```sh
npx plumbago list
```

## skill

Adds the Plumbago skill for Claude Code to .claude/skills/plumbago, so Claude adds and styles components the Plumbago way. See AI agents.

```sh
npx plumbago skill
```

- `--overwrite`: Replace a skill you've changed with the latest one.

## mcp

Runs the MCP server that agents connect to, with tools to list, view and add components. You add it to your agent once; see AI agents.

```sh
npx -y plumbago@latest mcp
```

## Updating components

Components don't have versions of their own: once they're copied, they're your files. To pick up fixes from a newer Plumbago, run add again with the latest CLI.

```sh
npx plumbago@latest add sheet
```

Files you haven't touched are updated. Files you've changed are kept and listed, so you can compare them with the new version, or replace them with `--overwrite`. The [changelog](https://plumbago.ochotzas.com/changelog.md) says what changed in each release.

## Options for every command

- `--cwd <path>`: Project root. Defaults to the current folder.

- `--registry <url>`: Read components from another registry, as a URL or a folder.

- `--no-install`: Print the packages to install instead of installing them.

You can also set `PLUMBAGO_REGISTRY` instead of passing `--registry`. See the [installation guide](https://plumbago.ochotzas.com/installation.md) for a full setup, or make a preset code on the [Create page](https://plumbago.ochotzas.com/create.md).
