Getting Started
This guide walks you through installing typub and publishing your first content.
Requirements
- Rust 1.85+ (edition 2024)
- Typst (for document compilation)
Installation
cargo install typub
Initialize a Content Project
typub init
This creates the default configuration:
.
├── typub.toml # typub configuration
├── .typub/ # Status tracking database
└── posts/ # Your content directory
Create Your First Post
Create a Typst document:
// posts/hello-world/content.typ
= Hello World
This is my first post published with typub!
And the metadata file:
# posts/hello-world/meta.toml
title = "Hello World"
created = 2026-02-12
tags = ["tutorial", "typub"]
Configure a Platform
Edit typub.toml to enable a platform:
[platforms.devto]
enabled = true
# API key from environment: DEVTO_API_KEY
Set your API key:
export DEVTO_API_KEY="your-api-key-here"
Publish
# Publish to Dev.to
typub publish posts/hello-world -p devto
# Or publish to all enabled platforms
typub publish posts/hello-world
Development Mode
For local development with live reload:
# Start dev server with live reload
typub dev posts/hello-world -p xiaohongshu
# Or specify a custom port
typub dev posts/hello-world -p xiaohongshu --port 3000
Interactive Dashboard (TUI)
typub provides an interactive terminal dashboard for content management:
# Launch TUI dashboard
typub tui
The TUI provides three main views:
Post List
- Browse all your posts with publishing status indicators
- Sort posts by date, title, or modification time (press
s) - Press
Enterto view post details
Post Detail
- View post metadata and publishing status for each platform
- Use ↑/↓ to select a platform
- Press
pto preview the selected platform’s rendering - Press
Pto publish to the selected platform - Press
Ato publish to all enabled platforms
Preview
- View platform-specific preview in plain text
- Press
oto open full HTML preview in browser - Scroll with ↑/↓ or PageUp/PageDown
Keyboard Shortcuts:
q- Go back or quitr- Reload post listCtrl+C- Force quit
Check Status
# See what's been published where
typub status posts/hello-world
Next Steps
Basic path
- Adapters Guide — platform setup model
- Assets Guide — image strategy basics
- Theme Customization — custom CSS and theme overrides
- Profiles Guide — copy-paste profile basics
Advanced path
- Advanced Customization — layered overrides and advanced config
- External Storage — S3-compatible setup and operations