Skip to content

removal of IDE files #72

removal of IDE files

removal of IDE files #72

name: WMO First Mile Data Collection Guide
on:
push:
branches:
- main
env:
FILE_BASENAME: first-mile-guide-DRAFT
jobs:
build-first-mile-guide:
name: Generate documentation
runs-on: ubuntu-latest
steps:
- name: Install dependencies
run: |
sudo apt-get update -y \
&& sudo apt-get install -y pandoc \
&& sudo gem install asciidoctor asciidoctor-pdf
- name: checkout repository
uses: actions/checkout@master
- name: build documentation
run: |
mkdir -p /tmp/first-mile-guide/guide/images \
&& cd first-mile-guide \
&& asciidoctor --trace -a stylesheet=css/wmo-asciidoc.css -o /tmp/first-mile-guide/guide/${FILE_BASENAME}.html index.adoc \
&& asciidoctor -a allow-uri-read --trace --backend docbook --out-file - index.adoc | pandoc --from docbook --to docx --output /tmp/first-mile-guide/guide/${FILE_BASENAME}.docx \
&& asciidoctor -a allow-uri-read --trace -r asciidoctor-pdf --trace -b pdf -o /tmp/first-mile-guide/guide/${FILE_BASENAME}.pdf index.adoc \
&& cp images/*.png /tmp/first-mile-guide/guide/images | true \
&& cd ..
- name: checkout gh-pages branch
uses: actions/checkout@master
with:
ref: gh-pages
- name: update gh-pages branch and publish
run: |
git checkout gh-pages
git config --global user.email "tomkralidis@gmail.com"
git config --global user.name "Tom Kralidis"
rm -rf guide
mv -f /tmp/first-mile-guide/* .
git add .
git commit -am "update WMO First Mile Data Collection Guide"
git push