Skip to content

Commit

Permalink
Merge pull request #73 from malcolmbarrett/add_pkgdown
Browse files Browse the repository at this point in the history
Add pkgdown
  • Loading branch information
ledell authored Oct 15, 2020
2 parents 1cc6b44 + ea9072b commit 06bb7ad
Show file tree
Hide file tree
Showing 6 changed files with 96 additions and 1 deletion.
3 changes: 3 additions & 0 deletions .Rbuildignore
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,6 @@
^\.github$
^\.httr-oauth$
^CODE_OF_CONDUCT\.md$
^_pkgdown\.yml$
^docs$
^pkgdown$
1 change: 1 addition & 0 deletions .github/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
*.html
46 changes: 46 additions & 0 deletions .github/workflows/pkgdown.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
on:
push:
branches: [main, master]

name: pkgdown

jobs:
pkgdown:
runs-on: macOS-latest
env:
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}
steps:
- uses: actions/checkout@v2

- uses: r-lib/actions/setup-r@v1

- uses: r-lib/actions/setup-pandoc@v1

- name: Query dependencies
run: |
install.packages('remotes')
saveRDS(remotes::dev_package_deps(dependencies = TRUE), ".github/depends.Rds", version = 2)
writeLines(sprintf("R-%i.%i", getRversion()$major, getRversion()$minor), ".github/R-version")
shell: Rscript {0}

- name: Cache R packages
uses: actions/cache@v2
with:
path: ${{ env.R_LIBS_USER }}
key: ${{ runner.os }}-${{ hashFiles('.github/R-version') }}-1-${{ hashFiles('.github/depends.Rds') }}
restore-keys: ${{ runner.os }}-${{ hashFiles('.github/R-version') }}-1-

- name: Install dependencies
run: |
remotes::install_deps(dependencies = TRUE)
install.packages("pkgdown", type = "binary")
shell: Rscript {0}

- name: Install package
run: R CMD INSTALL .

- name: Deploy package
run: |
git config --local user.email "[email protected]"
git config --local user.name "GitHub Actions"
Rscript -e 'pkgdown::deploy_to_branch(new_process = FALSE)'
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,3 +7,4 @@ vignettes/*.R
vignettes/*.html
.DS_Store
.httr-oauth
docs
44 changes: 44 additions & 0 deletions _pkgdown.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
reference:
- title: All functions
contents:
- '`find_groups`'
- '`get_boards`'
- '`get_event_attendees`'
- '`get_event_comments`'
- '`get_event_rsvps`'
- '`get_events`'
- '`get_meetup_attendees`'
- '`get_meetup_comments`'
- '`get_members`'
- '`meetup_auth`'
- '`meetup_deauth`'
articles:
- title: All vignettes
desc: null
contents: '`meetupr_vignette`'
navbar:
structure:
left:
- home
- intro
- reference
- articles
- tutorials
- news
right: github
components:
home:
icon: fas fa-home fa-lg
href: index.html
reference:
text: Reference
href: reference/index.html
news:
text: Changelog
href: news/index.html
articles:
text: Articles
menu:
- text: R-Ladies chapters on meetup.com
href: articles/meetupr_vignette.html

2 changes: 1 addition & 1 deletion vignettes/meetupr_vignette.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ author: "Claudia Vitolo"
date: "`r Sys.Date()`"
output: rmarkdown::html_vignette
vignette: >
%\VignetteIndexEntry{Vignette Title}
%\VignetteIndexEntry{R-Ladies chapters on meetup.com}
%\VignetteEngine{knitr::rmarkdown}
%\VignetteEncoding{UTF-8}
---
Expand Down

0 comments on commit 06bb7ad

Please sign in to comment.