Skip to content

Instantly share code, notes, and snippets.

@techgaun
Created October 29, 2014 16:20
Show Gist options
  • Save techgaun/5a33e475bed149a9b355 to your computer and use it in GitHub Desktop.
Save techgaun/5a33e475bed149a9b355 to your computer and use it in GitHub Desktop.
markdown viewer in command line

Markdown Viewer in your terminal

  • markdown
apt-get install markdown lynx
markdown <markdown_file> | lynx -stdin
  • pandoc
apt-get install pandoc lynx
pandoc <markdown_file> -f markdown -t html | lynx -stdin

You might want to create a bash alias since you will use this frequently

  • using markdown
function mdview {
pandoc "$1" -f markdown -t html | lynx -stdin
}
  • using pandoc
function mdview {
markdown "$1" | lynx -stdin
}
@zomblake
Copy link

Are the code examples switched?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment