Type something to search...

CLI Commands

Complete command reference

All Astrolock CLI commands.

Getting Help

astrolock --help           # All commands
astrolock <command> --help # Command-specific help

Core Commands

CommandDescription
astrolock initInitialize a new site
astrolock writeStart development server
astrolock buildBuild for production
astrolock previewPreview production build

Content Commands

CommandDescription
astrolock content <collection> <title>Create new content

Examples

# Create a blog post
astrolock content blog "My New Post"

# Create an audio entry
astrolock content mixes "Summer Mix 2025"

# Create an author profile
astrolock content author "Jane Smith"

Import Commands

CommandDescription
astrolock import rekordboxImport Rekordbox DJ mixes
astrolock import images <collection> <path>Create image collection from folder
astrolock import media <collection> <path>Bulk import media files
astrolock import stock-imagesGenerate placeholder images

Deploy Commands

CommandDescription
astrolock deploy <target>Deploy to a target
astrolock deploy to <target>Deploy with explicit routing

Examples

# Deploy to a target
astrolock deploy live --execute

# Dry run (preview what would be deployed)
astrolock deploy stage

Collections

Collections are configured in .astrolock/astrolock.yaml. Edit this file to add, modify, or remove collections.

collections:
  mixes:
    displayName: "DJ Mixes"
    contentType: "audio"
    defaults:
      contentExtension: "mp3"