Skip to content

Instantly share code, notes, and snippets.

@StephenKing
Created May 27, 2020 23:18
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save StephenKing/d74cddcbd1eab3529a678b1ca6fad530 to your computer and use it in GitHub Desktop.
Save StephenKing/d74cddcbd1eab3529a678b1ca6fad530 to your computer and use it in GitHub Desktop.
GitHub Action to render and upload Asciidoc
name: build asciidoc
on:
push:
branches:
- master
jobs:
asciidoc_build:
runs-on: ubuntu-18.04
name: Build Asciidoc
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Build HTML
uses: avattathil/asciidoctor-action@master
with:
program: "asciidoctor -D . --backend=html5 document.adoc"
- name: Upload HTML Artifact
uses: actions/upload-artifact@v1
with:
name: HTML document
path: document.html
- name: Build PDF
uses: avattathil/asciidoctor-action@master
with:
program: "asciidoctor-pdf -a allow-uri-read -D . document.adoc"
- name: Upload PDF Artifact
uses: actions/upload-artifact@v2
with:
name: PDF document
path: document.pdf
@StephenKing
Copy link
Author

Screenshot 2020-05-28 at 01 16 18

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