Skip to content

atani/glowm

Repository files navigation

glowm

A Glow-like Markdown CLI with Mermaid rendering for iTerm2/Kitty and PDF output.

glowm demo glowm demo screenshot

Usage

# Render Markdown to ANSI output
./glowm README.md

# Read from STDIN
cat README.md | ./glowm -

# Export Mermaid diagrams to PDF
./glowm --pdf README.md > diagram.pdf

Options

  • -w Word wrap width
  • -s Style name (dark/light/notty/auto) or JSON style path
  • -p Force pager output (overrides --no-pager)
  • --no-pager Disable default pager (pager is on by default for TTY)
  • --pdf Export Mermaid diagrams to PDF via stdout

Config

glowm reads the config file from the OS-specific user config directory:

  • macOS: ~/Library/Application Support/glowm/config.json
  • Linux: ~/.config/glowm/config.json (or $XDG_CONFIG_HOME/glowm/config.json)
  • Windows: %AppData%\glowm\config.json

Example:

{
  "pager": {
    "mode": "vim"
  }
}

Requirements

  • Go
  • Chrome/Chromium (required for Mermaid rendering and PDF export)

Mermaid rendering

  • iTerm2 / Kitty: Mermaid diagrams are rendered inline as images
  • Other terminals: Mermaid blocks are shown as code

Install (Homebrew)

brew tap atani/tap
brew install glowm

Support

GitHub Sponsors

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Sponsor this project

Packages

 
 
 

Contributors

Languages