Skip to content

🎉 citations

🎉 citations #15

Workflow file for this run

name: Compile the document
permissions:
contents: write
on:
push:
branches:
- main
pull_request:
jobs:
build:
name: Build the sources
runs-on: ubuntu-latest
strategy:
matrix:
julia-version: [1.8]
steps:
- uses: actions/checkout@v2
- name: Julia ${{ matrix.julia-version }}
uses: julia-actions/setup-julia@v1
with:
version: ${{ matrix.julia-version }}
arch: 'x64'
- name: Get the typesetter
run: |
wget https://github.com/gabrieldansereau/manuscript-typesetter/archive/refs/heads/ms_networks_opinion.tar.gz -O typesetter.tar.gz
tar -xvf typesetter.tar.gz
mv manuscript-typesetter-* .typesetter
- name: Julia packages
uses: julia-actions/julia-buildpkg@v1
with:
project: .typesetter
- name: Run the full project
run: julia --project=.typesetter .typesetter/scripts/00_build.jl
- name: "Word count in the build folder"
id: word-count
if: github.event_name == 'pull_request'
run: echo "::set-output name=count::Current word count (main text; no references) is approx. $(wc -w dist/rawtext.txt | cut -d' ' -f1)"
- name: "Comment on wordcount"
uses: thollander/actions-comment-pull-request@v1
if: github.event_name == 'pull_request'
with:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
message: ${{ steps.word-count.outputs.count }}
- name: Save artifacts
if: always()
uses: actions/upload-artifact@v4
with:
name: "dist"
path: dist
deploy:
name: Deploy to gh-pages
needs: build
runs-on: ubuntu-latest
if: github.ref == 'refs/heads/main'
steps:
- uses: actions/checkout@v4
- name: Download dist folder
uses: actions/download-artifact@v4
with:
name: "dist"
path: dist
- name: "Deploy!"
uses: JamesIves/[email protected]
with:
branch: gh-pages # The branch the action should deploy to.
folder: dist # The folder the action should deploy.