Skip to content

Commit 2c7a9df

Browse files
committed
ci: add render ci
1 parent 534752a commit 2c7a9df

File tree

1 file changed

+86
-0
lines changed

1 file changed

+86
-0
lines changed

.github/workflows/main.yml

Lines changed: 86 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,86 @@
1+
on:
2+
push:
3+
branches:
4+
- master
5+
workflow_dispatch:
6+
7+
name: Render and Publish
8+
9+
# you need these permissions to publish to GitHub pages
10+
permissions:
11+
contents: write
12+
pages: write
13+
14+
jobs:
15+
build-deploy:
16+
runs-on: ubuntu-latest
17+
18+
steps:
19+
- name: Check out repository
20+
uses: actions/checkout@v4
21+
22+
- name: Set up Quarto
23+
uses: quarto-dev/quarto-actions/setup@v2
24+
env:
25+
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
26+
with:
27+
# To install LaTeX to build PDF book
28+
tinytex: true
29+
# uncomment below and fill to pin a version
30+
# version: SPECIFIC-QUARTO-VERSION-HERE
31+
32+
# add software dependencies here and any libraries
33+
34+
# From https://github.com/actions/setup-python
35+
# - name: Setup Python
36+
# uses: actions/setup-python@v3
37+
38+
# From https://github.com/r-lib/actions/tree/v2-branch/setup-r
39+
# - name: Setup R
40+
# uses: r-lib/actions/setup-r@v2
41+
42+
# From https://github.com/julia-actions/setup-julia
43+
# - name: Setup Julia
44+
# uses: julia-actions/setup-julia@v1
45+
46+
# See more at https://github.com/quarto-dev/quarto-actions/blob/main/examples/example-03-dependencies.md
47+
48+
# To publish to Netlify, RStudio Connect, or GitHub Pages, uncomment
49+
# the appropriate block below
50+
51+
# - name: Publish to Netlify (and render)
52+
# uses: quarto-dev/quarto-actions/publish@v2
53+
# with:
54+
# target: netlify
55+
# NETLIFY_AUTH_TOKEN: ${{ secrets.NETLIFY_AUTH_TOKEN }}
56+
57+
# - name: Publish to RStudio Connect (and render)
58+
# uses: quarto-dev/quarto-actions/publish@v2
59+
# with:
60+
# target: connect
61+
# CONNECT_SERVER: enter-the-server-url-here
62+
# CONNECT_API_KEY: ${{ secrets.CONNECT_API_KEY }}
63+
64+
# NOTE: If Publishing to GitHub Pages, set the permissions correctly (see top of this yaml)
65+
- name: Render Book project
66+
uses: quarto-dev/quarto-actions/render@v2
67+
with:
68+
to: html
69+
70+
- name: Publish HTML book
71+
uses: quarto-dev/quarto-actions/publish@v2
72+
with:
73+
target: gh-pages
74+
render: false
75+
env:
76+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # this secret is always available for github actions
77+
78+
# - name: Publish to confluence
79+
# uses: quarto-dev/quarto-actions/publish@v2
80+
# with:
81+
# target: confluence
82+
# env:
83+
# CONFLUENCE_USER_EMAIL: ${{ secrets.CONFLUENCE_USER_EMAIL }}
84+
# CONFLUENCE_AUTH_TOKEN: ${{ secrets.CONFLUENCE_AUTH_TOKEN }}
85+
# CONFLUENCE_DOMAIN: ${{ secrets.CONFLUENCE_DOMAIN }}
86+

0 commit comments

Comments
 (0)