Skip to content

Commit

Permalink
Merge pull request #217 from NLeSC/pdf
Browse files Browse the repository at this point in the history
Generate PDF
  • Loading branch information
sverhoeven authored Sep 9, 2020
2 parents 632ca33 + 6f91263 commit 387177b
Show file tree
Hide file tree
Showing 4 changed files with 35 additions and 0 deletions.
3 changes: 3 additions & 0 deletions .docsifytopdfrc.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
contents:
- _sidebar.md
pathToPublic: guide-nlesc.pdf
24 changes: 24 additions & 0 deletions .github/workflows/pdf.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: Generate PDF

on:
release:
types: [published]

jobs:
generate:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Change absolute paths to relative
run: perl -pi -e 's@\]\(\/@\]\(@' _sidebar.md
- uses: actions/setup-node@v1
with:
node-version: '12'
- name: Install converter + uploadergit
run: npm install docsify-pdf-converter @iomeg/zenodo-upload
- name: Generate PDF
run: npx docsify-pdf-converter
- name: Upload PDF to Zenodo
run: npx --package @iomeg/zenodo-upload zenodo_upload 4020565 guide-nlesc.pdf "${github_ref:10}" ${{ secrets.ZENODO_TOKEN }}
env:
github_ref: ${{ github.ref }}
5 changes: 5 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,3 +41,8 @@ If you have made a significant contribution to the guide, please make sure to ad
## Chapter Owners

To see who is responsible for which part of the guide see [chapter_owners.md](chapter_owners.md).

## Create a PDF file

We host a PDF version of the guide on [Zenodo](https://doi.org/10.5281/zenodo.4020565).
To update it a [new release](https://github.com/NLeSC/guide/releases) needs to be made of the guide. This will trigger a GitHub action to create a new Zenodo version with the PDF file.
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
Dead-link checker status (does not actually build guide itself): [![Build Status](https://travis-ci.org/NLeSC/guide.svg?branch=master)](https://travis-ci.org/NLeSC/guide)
[![DOI](https://zenodo.org/badge/DOI/10.5281/zenodo.4020565.svg)](https://doi.org/10.5281/zenodo.4020565)

# Guide

Expand All @@ -11,3 +12,5 @@ Read this book online here: https://guide.esciencecenter.nl
If you would like to contribute to this book see [CONTRIBUTING.md](CONTRIBUTING.md).

To see who is responsible for which part of the guide see [chapter_owners.md](chapter_owners.md).

The guide is best read online, but there is a [PDF document](https://doi.org/10.5281/zenodo.4020564) for offline reading.

0 comments on commit 387177b

Please sign in to comment.