Docs

CLI reference

The orbiter CLI scaffolds projects, manages users, exports content, and syncs media with git.

Install

npm install -g @a83/orbiter-cli

orbiter init [dir]

Scaffold a new Astro + Orbiter project.

orbiter init my-site
cd my-site && npm install && npm run dev

Creates astro.config.mjs, a fresh content.pod with a default Posts collection, example Astro pages, and a GitHub Actions workflow template.

orbiter add-user

Add an admin or editor user to an existing pod.

orbiter add-user --pod ./content.pod

Interactive prompts: username, password, role (admin or editor).

orbiter export

Export all published entries to JSON or Markdown files.

# JSON (default)
orbiter export --pod ./content.pod --out ./export

# Markdown with frontmatter
orbiter export --pod ./content.pod --out ./export --format md

# Single collection
orbiter export --pod ./content.pod --out ./export --collection posts

Output: ./export/{collection}/{slug}.json or .md

orbiter unpack

Extract media BLOBs from the pod to regular files. Run before git commit for platforms with ephemeral filesystems.

orbiter unpack --pod ./content.pod --media-dir ./media

After unpacking, BLOBs are removed from _media.data and a storage.mode=git flag is set in _meta. See Git sync mode.

orbiter pack

Restore media BLOBs from files back into the pod. Run at build time before astro build.

orbiter pack --pod ./content.pod --media-dir ./media

All options

CommandFlagDescription
init[dir]Target directory (default: current)
add-user--podPath to the pod file
add-user--usernameSkip interactive prompt
add-user--roleadmin or editor
export--podPath to the pod file
export--outOutput directory
export--formatjson (default) or md
export--collectionSingle collection to export
unpack--podPath to the pod file
unpack--media-dirOutput directory for media files (default: ./media)
pack--podPath to the pod file
pack--media-dirDirectory containing media files (default: ./media)