CLI
The Metrists CLI converts markdown files into static websites. It handles building, theming, and deployment.
Installation
npm install -g metristsOr use npx without installing:
npx metrists <command>Commands
init: Create a new project
metrists initwatch: Start development server
metrists watchbuild: Generate static site
metrists buildpublish: Deploy to hosting platform
metrists publish vercel
metrists publish netlify
metrists publish s3Configuration
The CLI reads .metristsrc for settings:
{
"theme": "default",
"output": "dist",
"title": "My Book"
}CI/CD Integration
The CLI works in any CI environment. Example GitHub Actions workflow:
- name: Build book
run: npx metrists build
- name: Deploy
run: npx metrists publish vercelGlobal Options
--config <path>: Specify config file location--theme <name>: Override theme--output <dir>: Override output directory--verbose: Detailed logging