Skip to content

Commit 5f5a9d3

Browse files
authored
Move pkgdown building and deployment to GH action (#802)
Automatically build and deploy pkgdown website via GH actions. New `pkgdown.yaml` CI workflow to build and deploy on commit to `main` or a GH release. Deployment occurs via a new `gh-pages` branch Also, remove the existing pkgdown website from the `main` branch, and add the `docs/` directory to `.gitignore` to prevent it from being re-checked in to `main` [SC-62380](https://app.shortcut.com/tiledb-inc/story/62380) resolves #798
1 parent ae0674d commit 5f5a9d3

File tree

549 files changed

+56
-94244
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

549 files changed

+56
-94244
lines changed

.Rbuildignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,3 +28,4 @@
2828
^codecov.yml
2929
^notes.md
3030
^pkgdown
31+
^\.github$

.github/.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
*.html

.github/workflows/pkgdown.yaml

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
# Workflow derived from https://github.com/r-lib/actions/tree/v2/examples
2+
# Need help debugging build failures? Start at https://github.com/r-lib/actions#where-to-find-help
3+
on:
4+
push:
5+
branches: [main]
6+
pull_request:
7+
branches: [main]
8+
release:
9+
types: [published]
10+
workflow_dispatch:
11+
12+
name: pkgdown.yaml
13+
14+
permissions: read-all
15+
16+
jobs:
17+
pkgdown:
18+
runs-on: ubuntu-latest
19+
# Only restrict concurrency for non-PR jobs
20+
concurrency:
21+
group: pkgdown-${{ github.event_name != 'pull_request' || github.run_id }}
22+
env:
23+
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}
24+
permissions:
25+
contents: write
26+
steps:
27+
- uses: actions/checkout@v4
28+
- uses: r-lib/actions/setup-pandoc@v2
29+
- uses: r-lib/actions/setup-r@v2
30+
with:
31+
use-public-rspm: true
32+
- uses: r-lib/actions/setup-r-dependencies@v2
33+
with:
34+
extra-packages: any::pkgdown, local::.
35+
- name: Build vignettes
36+
run: cd vignettes/ && make
37+
- name: Build site
38+
run: pkgdown::build_site_github_pages(new_process = FALSE, install = FALSE)
39+
shell: Rscript {0}
40+
- name: Deploy to GitHub pages
41+
if: github.event_name != 'pull_request'
42+
uses: JamesIves/[email protected]
43+
with:
44+
clean: false
45+
branch: gh-pages
46+
folder: docs

.gitignore

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,15 @@
77
TileDB-R.Rproj
88
# Example code in package build process
99
*-Ex.R
10+
# pkgdown artifacts
11+
docs/
1012
# Build artifacts
1113
src/*.o
14+
src/*/*.o
1215
src/*.so
1316
src/*.dll
17+
inst/lib/*/*.dll
18+
inst/tiledb
1419
# Output files from R CMD build
1520
/*.tar.gz
1621
# Output files from R CMD check

docs/.nojekyll

Whitespace-only changes.

docs/404.html

Lines changed: 0 additions & 97 deletions
This file was deleted.

docs/LICENSE-text.html

Lines changed: 0 additions & 71 deletions
This file was deleted.

docs/apple-touch-icon-120x120.png

-1.35 KB
Binary file not shown.

docs/apple-touch-icon-152x152.png

-1.51 KB
Binary file not shown.

docs/apple-touch-icon-180x180.png

-1.71 KB
Binary file not shown.

0 commit comments

Comments
 (0)