Skip to content

Instantly share code, notes, and snippets.

@tjstebbing
Last active June 20, 2016 03:28
Show Gist options
  • Save tjstebbing/10016d080540e83c64417d04fc00c9d3 to your computer and use it in GitHub Desktop.
Save tjstebbing/10016d080540e83c64417d04fc00c9d3 to your computer and use it in GitHub Desktop.

mdless

Read markdown files in your terminal

cd ~/code
git clone git@github.com:axiros/terminal_markdown_viewer.git
cd terminal_markdown_viewer
pip install markdown pygments pyyaml

Then add the following to your .bashrc/.zshrc

mdless () { /Users/yourname/code/terminal_markdown_viewer/mdv.py  -t 994.0134 -T 627.2501 "$@" | less; }

Now you can happily:

mdless README.md

swagger extension:

npm install -g swagger-markup

Then add the following to your .bashrc/.zshrc

swagless () { swagger-markup -f markdown "$@" > "/tmp/$@" && mdless "/tmp/$@" ; }

Now you can:

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