A GitHub Action to convert Markdown files to HTML via GitHub's API.
Essentially, this action will take input Markdown files and render them into self-contained HTML files that look as close as possible to how Markdown files are displayed on github.com.
It is tested and runs on windows-latest
, ubuntu-latest
, and macos-latest
.
jobs:
Job:
runs-on: windows-latest
steps:
- name: Convert Markdown to HTML
uses: natescherer/markdown-to-html-with-github-style-action@v1
with:
path: README.md,CHANGELOG.md,docs\doc1.md
outputpath: out
Name | Required | Description |
---|---|---|
path |
true | A comma-separated list of one or more paths to markdown files to convert, relative to the root of your project. |
outputpath |
false | Path to a folder where HTML files should be saved. By default, HTML files will be saved in the same path as the source markdown file. |
matchpathstructure |
false | If set to true , will output files into the path provided to outputfolder while preserving the directory structure of the input files. I.E. if path is README.md,docs/Doc1.md and outputfolder is out , the files created will be out/README.html and out/docs/Doc1.html rather than both files being created in the root of out . |
This Action does not have outputs.
Nate Scherer - Initial work - natescherer
This project is licensed under The MIT License - see LICENSE for details.
sindresorhus - For creating the CSS used in this action