Skip to content

stormlightlabs/lantern

Repository files navigation

lantern

A modern, fast, terminal presentation tool inspired by maaslalani/slides, built with Rust.

Quickstart

Installation

From a local clone:

cargo install --path cli

From GitHub:

cargo install --git https://github.com/stormlightlabs/lantern.git lantern-cli

From Tangled:

cargo install --git https://tangled.sh/desertthunder.dev/lantern lantern-cli

Create Your First Deck

Create a markdown file presentation.md:

---
theme: nord
---

# Welcome to lantern

A terminal presentation tool built with Rust

---

## Features

- Base16 theming system
- Syntax highlighting
- Live reload
- Export to image/video

---

## Code Example

```rust
fn main() {
    println!("Hello, lantern!");
}
```

---

## That's it

Press `q` to quit, `←/→` to navigate

Present

# Interactive TUI mode
lantern present presentation.md

# Print to stdout
lantern print presentation.md

# With custom theme
lantern present presentation.md --theme catppuccin-mocha

Navigation

Key Action
, j, n Next slide
, k, p Previous slide
q Quit

Design Principles

Color as Data: All color use flows through typed wrappers using owo-colors. No ad-hoc ANSI escapes.

Themeable: Built on the Base16 theming system with 10 prebuilt themes (Catppuccin, Nord, Gruvbox Material, Solarized, Oxocarbon). Each theme defines 16 semantic colors mapped to content and UI elements. Themes can be selected via frontmatter, CLI flags, or environment variables.

Reproducible: Everything is reproducible in plain text — decks can render without TUI (using lantern print).

Composable: Parser → Model → Renderer are independent modules with tests and traits.

Portable: Runs on any terminal supporting UTF-8; dependencies limited to core crates.

Testing

This project uses cargo-llvm-cov for coverage

Installation:

# MacOS
brew install cargo-llvm-cov

# Linux
cargo +stable install cargo-llvm-cov --locked

Run tests:

cargo llvm-cov

# Open the browser
cargo llvm-cov --open

About

magical markdown slides

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages