generated from rpodcast/r_dev_projects
-
Notifications
You must be signed in to change notification settings - Fork 0
62 lines (52 loc) · 1.73 KB
/
publish.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
on:
push:
branches: [main]
schedule:
- cron: "5 9 * * 0"
workflow_dispatch:
name: Quarto Publish
jobs:
build-deploy:
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- name: Check out repository
uses: actions/checkout@v4
- name: Install jq for parsing system dependencies
id: install-jq-step
uses: awalsh128/cache-apt-pkgs-action@latest
with:
packages: jq
version: 1.0
- name: Install system dependencies
id: install-deps-step
uses: awalsh128/cache-apt-pkgs-action@latest
env:
DEPS_ENV: ${{ steps.parse-dep-step.DEPS_ENV }}
with:
packages: libarchive-dev libcurl4-openssl-dev libssl-dev make
- name: Setup r2u
id: r2u-step
uses: eddelbuettel/github-actions/r2u-setup@master
- name: SessionInfo
id: sessioninfo-step
run: R -q -e 'sessionInfo()'
- name: Install deps R package
id: r-pkg-deps-step
run: Rscript -e 'install.packages("deps")'
- name: Package Dependencies
id: r-package-dependencies-step
# takes advantage of r2u to install the named CRAN packages as binaries
# in the r2u context we could also use script 'install.r'
#run: Rscript -e 'install.packages(c("tinyspotifyr", "ggplot2", "anytime", "data.table", "tinythemes"))'
run: Rscript -e 'deps::install()'
- name: Set up Quarto
uses: quarto-dev/quarto-actions/setup@v2
- name: Render and Publish
uses: quarto-dev/quarto-actions/publish@v2
with:
target: gh-pages
path: quarto_dashboard
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}