Seed CLISeed CLI

create-seedcli

Scaffold a new Seed CLI project.

create-seedcli is a standalone scaffolding package for instant project setup.

Usage

npm create seedcli my-cli

Works with any package manager: npm create, pnpm create, yarn create, or bun create.

This scaffolds the same templates as seed new my-cli, but it is a separate command: it can prompt for a missing project name and uses --yes, --no-install, and --no-git instead of seed new's --skipPrompts, --skipInstall, and --skipGit.

Interactive Mode

When run without a name, it prompts for one:

npm create seedcli

You'll be prompted for:

  1. Project name — Directory name and package name (kebab-cased)
  2. Template — Full (recommended), Minimal, or Plugin
  3. Description — Package description
  4. Package managernpm, pnpm, yarn, or bun (default inferred from the invoking package manager or current lockfile)

Flags

FlagDescription
--yes, -yUse defaults for template, description, and package manager. If no project name is provided, you will still be prompted for one.
--no-installSkip dependency installation
--no-gitSkip git initialization
--version, -vShow version
--help, -hShow help

Templates

The recommended template with example commands, extensions, and testing:

my-cli/
├── src/
│   ├── commands/
│   │   └── hello.ts          # Example command with args & flags
│   ├── extensions/
│   │   └── timer.ts          # Example extension
│   └── index.ts              # Entry point (auto-discovers commands/ & extensions/)
├── tests/
│   └── hello.test.ts
├── .gitignore
├── biome.json
├── package.json
├── seed.config.ts             # CLI configuration
└── tsconfig.json

A bare-bones single-file CLI:

my-cli/
├── src/
│   └── index.ts              # Entry point with inline command
├── tests/
│   └── index.test.ts
├── .gitignore
├── biome.json
├── package.json
└── tsconfig.json

A reusable plugin package for npm distribution:

my-plugin/
├── src/
│   ├── commands/
│   │   └── hello.ts          # Example command
│   ├── extensions/
│   │   └── example.ts        # Example extension
│   ├── types.d.ts            # Module augmentation for SeedExtensions
│   └── index.ts              # definePlugin() export
├── tests/
│   └── plugin.test.ts        # Uses createTestCli()
├── .gitignore
├── biome.json
├── package.json              # No bin field, has peerDependencies & publishConfig
├── tsconfig.json
└── tsconfig.build.json       # For publishing compiled dist/

Template Comparison

AspectFullMinimalPlugin
PurposeProduction CLIQuick scriptsReusable npm package
EntryAuto-discovers commands/ & extensions/Inline commanddefinePlugin() export
Example commandhello with args & flagshello (simple)hello
Extensionstimer exampleNoneexample extension
Configseed.config.tsNoneNone
bin fieldYesYesNo
TestsVitestVitestVitest + createTestCli()
Buildseed buildseed buildtscdist/

Examples

# Quick start with defaults (Full template)
npm create seedcli my-cli --yes

# Skip dependency installation
npm create seedcli my-cli --no-install

# Skip git initialization
npm create seedcli my-cli --no-git

After Scaffolding

For Full / Minimal templates:

cd my-cli
npm run dev                    # Start with watch mode
npm run dev -- --help          # Run with flags
npm run build                  # Bundle for distribution
npm run compile                # Compile to standalone binary

For Plugin template:

cd my-plugin
npm test                       # Run tests

# Use in a CLI:
# import plugin from "my-plugin"
# build("my-cli").plugin(plugin).create()

Use your preferred package manager (npm, pnpm, yarn, or bun) for all commands.

On this page