Skip to content
60 changes: 44 additions & 16 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -1,35 +1,63 @@
name: CI build of the standard
name: Update PDF Preview

on:
pull_request:
types: [opened, synchronize, reopened]
env:
doc_name: DataLink

on:
push:
branches:
- master

jobs:
build:

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v1

- name: Checkout the repository
uses: actions/checkout@v1
with:
submodules: true

- name: Setup dependencies
run: |
sudo add-apt-repository ppa:inkscape.dev/stable
sudo apt update
sudo apt install texlive-latex-base texlive-latex-recommended texlive-latex-extra texlive-fonts-recommended xsltproc ghostscript cm-super librsvg2-bin inkscape

sudo apt install texlive-latex-base texlive-latex-recommended texlive-latex-extra texlive-fonts-recommended xsltproc latexmk cm-super inkscape
sudo snap install pdftk

- name: Build the document
run: |
inkscape --version
make role_diagram.pdf biblio forcetex
make role_diagram.pdf ${{ env.doc_name }}-draft.pdf

- name: Check the output
run: |
test -f DataLink.pdf
test -f DataLink.bbl

- uses: actions/upload-artifact@v1
test -f ${{ env.doc_name }}-draft.pdf
test -f ${{ env.doc_name }}.bbl

- name: Move the auto-pdf-preview tag
uses: weareyipyip/walking-tag-action@v2
with:
tag-name: auto-pdf-preview
tag-message: |
Last commit taken into account for the automatically updated PDF preview of this IVOA document.
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Update the PDF preview
uses: Xotl/cool-github-releases@v1
with:
name: DataLink.pdf Preview
path: DataLink.pdf
mode: update
isPrerelease: true
tag_name: auto-pdf-preview
release_name: "Auto PDF Preview"
body_mrkdwn: |
This release aims to provide a PDF preview of the last commit applied on this repository.
It will be updated automatically after each merge of a PullRequest.
**DO NOT PUBLISH THIS PRE-RELEASE!**"
_Corresponding commit: ${{ github.sha }}_
assets: ${{ env.doc_name }}-draft.pdf
replace_assets: true
github_token: ${{ secrets.GITHUB_TOKEN }}
57 changes: 16 additions & 41 deletions .github/workflows/preview.yml
Original file line number Diff line number Diff line change
@@ -1,63 +1,38 @@
name: Update PDF Preview
name: CI build of the standard

env:
doc_name: DataLink

on:
push:
branches:
- master
on:
pull_request:
types: [opened, synchronize, reopened]

jobs:
build:

runs-on: ubuntu-latest

steps:

- name: Checkout the repository
uses: actions/checkout@v1
- uses: actions/checkout@v1
with:
submodules: true

- name: Setup dependencies
run: |
sudo add-apt-repository ppa:inkscape.dev/stable
sudo apt update
sudo apt install texlive-latex-base texlive-latex-recommended texlive-latex-extra texlive-fonts-recommended xsltproc latexmk cm-super inkscape
sudo snap install pdftk

sudo apt install texlive-latex-base texlive-latex-recommended texlive-latex-extra texlive-fonts-recommended xsltproc ghostscript cm-super librsvg2-bin inkscape

- name: Build the document
run: |
inkscape --version
make role_diagram.pdf ${{ env.doc_name }}-draft.pdf

make role_diagram.pdf biblio forcetex
- name: Check the output
run: |
test -f ${{ env.doc_name }}-draft.pdf
test -f ${{ env.doc_name }}.bbl

- name: Move the auto-pdf-preview tag
uses: weareyipyip/walking-tag-action@v2
with:
tag-name: auto-pdf-preview
tag-message: |
Last commit taken into account for the automatically updated PDF preview of this IVOA document.
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Update the PDF preview
uses: Xotl/cool-github-releases@v1
test -f DataLink.pdf
test -f DataLink.bbl

- uses: actions/upload-artifact@v1
with:
mode: update
isPrerelease: true
tag_name: auto-pdf-preview
release_name: "Auto PDF Preview"
body_mrkdwn: |
This release aims to provide a PDF preview of the last commit applied on this repository.
It will be updated automatically after each merge of a PullRequest.
**DO NOT PUBLISH THIS PRE-RELEASE!**"
_Corresponding commit: ${{ github.sha }}_
name: DataLink.pdf Preview
path: DataLink.pdf
assets: ${{ env.doc_name }}-draft.pdf
replace_assets: true
github_token: ${{ secrets.GITHUB_TOKEN }}
4 changes: 2 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,10 @@ DOCNAME = DataLink
DOCVERSION = 1.1

# Publication date, ISO format; update manually for "releases"
DOCDATE = 2023-11-08
DOCDATE = 2023-12-15

# What is it you're writing: NOTE, WD, PR, REC, PEN, or EN
DOCTYPE = PR
DOCTYPE = REC

# An e-mail address of the person doing the submission to the document
# repository (can be empty until a make upload is being made)
Expand Down