SkillAgentSearch skills...

Markdown2html

Yet another script that converts GitHub Flavored Markdown files to HTML.

Install / Use

/learn @takistakis/Markdown2html
About this skill

Quality Score

0/100

Supported Platforms

Universal

README

markdown2html

Yet another script that converts GitHub Flavored Markdown files to HTML.

It is inspired by grip, and is an attempt to replicate it without its dependencies and without the need to interact directly with GitHub, or even being connected to the internet. The first time it runs, github-markdown.css is downloaded and stored in ~/.cache and from then on, it can be used while being offline. Generated HTML is put at /tmp by default.

Note that GitHub doesn't use pygments anymore for syntax highlighting, so it's difficult to generate the same CSS classes to use its colorscheme, and pygments doesn't include a similar one. For now, markdown2html uses the tango style which comes built-in with pygments.

Requirements

Install with:

$ pip install markdown pygments docopt

Optionally, if pymdown_extensions is present, extensions extra, magiclink, tasklist, highlight and tilde are used.

Usage

markdown2html [options] <file>

Options:
  -o, --out <file>      Write output to <file>
  -f, --force           Overwrite existing CSS file
  -p, --preview         Open generated HTML file in browser
  -i, --interval <int>  Refresh page every <int> seconds
  -q, --quiet           Show less information
  -h, --help            Show this help message and exit

License

Licensed under GPLv3 or later.

Related Skills

View on GitHub
GitHub Stars10
CategoryDevelopment
Updated2y ago
Forks4

Languages

Python

Security Score

75/100

Audited on Nov 3, 2023

No findings