Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/mgan59/docdown
A nodejs based command-line tool to convert Markdown to Html
https://github.com/mgan59/docdown
Last synced: 2 days ago
JSON representation
A nodejs based command-line tool to convert Markdown to Html
- Host: GitHub
- URL: https://github.com/mgan59/docdown
- Owner: mgan59
- Created: 2011-08-18T19:26:13.000Z (over 13 years ago)
- Default Branch: master
- Last Pushed: 2013-12-22T16:38:32.000Z (almost 11 years ago)
- Last Synced: 2023-03-11T20:49:22.465Z (over 1 year ago)
- Language: CoffeeScript
- Homepage:
- Size: 198 KB
- Stars: 6
- Watchers: 1
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.markdown
Awesome Lists containing this project
README
# DocDown - What is it?
Currently I have been writing docs in markdown for easy viewing on github. Recently one said markdown file was going to be sent out to a 3rd party. Knowing these 3rd party members wouldn't be viewing the documents in a markdown viewer I thought the best solution would be to convert the markdown into styled html. I had looked on Github and found several blogging engines built around markdown files being converted to html and served via express. That isn't what I needed. So I wrote DocDown as a simple command-line tool to help with my productivity. Maybe it will help you as well.
# How To Install DocDown
Well you will need nodejs and npm, if you haven't used those yet go find a tutorial and get started :)
Once you have npm installed do the following
npm install -g docdown
The package includes a bin script that allows you to run docdown where ever on your systems.
# How To Use DocDown
A basic example is as follows, assuming you are in your folder with the markdown file called my_doc.markdown do the following
docdown --markdown my_doc.markdown
which will generate a file called my_doc.html in the local folderYou can specify a output file name if you don't want it to inherit the original source's filename
docdown --markdown my_doc.markdown --output super_doc.html
Will generate a file called super_doc.html in the local folder# Variables
The following variables can be used when calling the tool as the followingdocdown --markdown my_doc.markdown --title "New project specs"
Variable
Description
Default value
title
Title in the generated HTML
DocDown Generated File
author
Value in the meta tag author in the head of the document
None
# Todo
Eventually I'll add support for custom templates for the html, currently a really basic white template is used. I have the hooks in place for the cmd-line arguments to almost work.
In addition, I'd also like to add support to do an entire directory of markdown and create a directory of .html output
[![Bitdeli Badge](https://d2weczhvl823v0.cloudfront.net/mgan59/docdown/trend.png)](https://bitdeli.com/free "Bitdeli Badge")