Skip to content

CLI

Use the registry from any package manager

The CLI is the shadcn-style distribution path for apps that should own their component source while still following Cooud UI conventions.

Initialize a project

Select your package manager

bash
pnpm dlx cooud-ui@latest init

Add components

Copy components into your app

bash
pnpm dlx cooud-ui@latest add button card dialog

Inspect the registry

List available registry items, or diff a copied component against the registry version to spot local drift.

bash
npx cooud-ui@latest list
npx cooud-ui@latest diff button

Command surface

These commands are designed for app teams that want source ownership and repeatable upgrades.

init

setup

Creates cooud-ui.json, installs base dependencies, writes lib/cn, and imports tokens.

add

daily

Copies components into your app, resolves registry dependencies, and rewrites imports.

list

inspect

Prints registry items and lets teams audit what exists before adding code.

diff

audit

Compares local copied components against the registry version to expose drift.

Config

The config keeps local aliases explicit, so generated code lands in the right folders for each app.

json
{
"aliases": {
"ui": "@/components/ui",
"lib": "@/lib"
},
"paths": {
"ui": "components/ui",
"lib": "lib"
},
"registry": "https://raw.githubusercontent.com/pedrogbraz/cooud-ui/main/registry"
}

Use --registry ./registry for offline testing against a local registry build.