CLI Commands Reference

Complete zone5 CLI command reference.


zone5 create

Create a new SvelteKit project with Zone5 image processing pre-configured.

Synopsis

zone5 create <input-folder> <output-folder> [options]

Arguments

ArgumentDescription
<input-folder>Path to directory containing source images (JPG files)
<output-folder>Path where the new project will be created

Options

OptionDefaultDescription
-m, --mode <type>copyHow to handle images: copy, link, or move
-p, --package-manager <pm>npmPackage manager: npm, pnpm, yarn, bun, or skip
--no-interactive-Skip prompts and use defaults
--help-Show help message
--version-Show version number

Image Modes

  • copy - Copies images to the project’s static/images/ directory. Safe option that preserves originals.
  • link - Creates symbolic links to original images. Saves disk space but requires originals to remain in place.
  • move - Moves images to the project. Use when you want to consolidate files.

Package Managers

  • npm - Node Package Manager (default)
  • pnpm - Fast, disk space efficient package manager
  • yarn - Yarn package manager
  • bun - Fast all-in-one JavaScript runtime
  • skip - Don’t install dependencies; run installation manually later

Exit Codes

CodeDescription
0Success
1Error (invalid arguments, missing directory, etc.)

Output

The command creates a complete SvelteKit project with:

output-folder/
├── .zone5.toml             # Zone5 configuration
├── package.json            # Project dependencies
├── vite.config.ts          # Vite config with zone5 plugin
├── svelte.config.js        # SvelteKit config with mdsvex
└── src/
    ├── routes/
    │   ├── +layout.svelte  # Zone5Provider wrapper
    │   ├── +page.md        # Gallery page with your images
    │   └── photo.jpg       # You images (copied/linked/moved)
    └── app.css             # Tailwind config

Global Options

Available for all commands:

OptionDescription
--helpShow help for the command
--versionShow Zone5 version

Check Version

npx zone5 --version

Get Help

npx zone5 --help
npx zone5 create --help