logo

Prism

GitHub GitHub go.mod Go version GitHub release (latest by date) Go Report Card Go Reference

Create beautiful images of your source code directly from your terminal.

example

Installation

Precompiled prism binaries can be found at releases page.

Instructions below show how to build prism from sources.

go install github.com/mrmarble/prism/cmd/[email protected] # or target a specific version @v0.1.0

Usage

Be sure prism executable is under your $PATH.

Usage of prism: prism [input file] [args…] Run prism without arguments to get help output.

Flags:
  -h, --help                  Show context-sensitive help.
  -l, --lang=STRING           Language to parse.
  -o, --output="prism.png"    Output file name
      --version               Print version information and quit
      --header                Display header
      --lines=STRING          Specify a range of lines instead of reading the whole file. Ex: 10-20
  -n, --numbers               Display line numbers
  -r, --relative              Use relative numbers. Needs --lines and --numbers

Supported languages

See languages for a list of implemented languages.

GitHub

View Github