| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -1,63 +1,32 @@ | |||
| 1 | + # Workflow derived from https://github.com/r-lib/actions/tree/master/examples | ||
| 2 | + # Need help debugging build failures? Start at https://github.com/r-lib/actions#where-to-find-help | ||
| 1 | 3 | on: | |
| 2 | 4 | push: | |
| 3 | - branches: | ||
| 4 | - - main | ||
| 5 | - - master | ||
| 6 | - tags: | ||
| 7 | - -'*' | ||
| 5 | + branches: [main, master] | ||
| 6 | + tags: ['*'] | ||
| 8 | 7 | ||
| 9 | 8 | name: pkgdown | |
| 10 | 9 | ||
| 11 | 10 | jobs: | |
| 12 | 11 | pkgdown: | |
| 13 | - runs-on: ubuntu-18.04 | ||
| 12 | + runs-on: ubuntu-latest | ||
| 14 | 13 | env: | |
| 15 | - RSPM: https://packagemanager.rstudio.com/cran/__linux__/bionic/latest | ||
| 16 | 14 | GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }} | |
| 17 | - | ||
| 18 | 15 | steps: | |
| 19 | 16 | - uses: actions/checkout@v2 | |
| 20 | 17 | ||
| 21 | - - uses: r-lib/actions/setup-r@v1 | ||
| 22 | - id: install-r | ||
| 23 | - | ||
| 24 | 18 | - uses: r-lib/actions/setup-pandoc@v1 | |
| 25 | 19 | ||
| 26 | - - name: Install pak and query dependencies | ||
| 27 | - run: | | ||
| 28 | - install.packages("pak", repos = "https://r-lib.github.io/p/pak/dev/") | ||
| 29 | - saveRDS(pak::pkg_deps("local::.", dependencies = TRUE), ".github/r-depends.rds") | ||
| 30 | - shell: Rscript {0} | ||
| 31 | - | ||
| 32 | - - name: Restore R package cache | ||
| 33 | - uses: actions/cache@v2 | ||
| 20 | + - uses: r-lib/actions/setup-r@v1 | ||
| 34 | 21 | with: | |
| 35 | - path: | | ||
| 36 | - ${{ env.R_LIBS_USER }}/* | ||
| 37 | - !${{ env.R_LIBS_USER }}/pak | ||
| 38 | - key: ubuntu-18.04-${{ steps.install-r.outputs.installed-r-version }}-1-${{ hashFiles('.github/r-depends.rds') }} | ||
| 39 | - restore-keys: ubuntu-18.04-${{ steps.install-r.outputs.installed-r-version }}-1- | ||
| 22 | + use-public-rspm: true | ||
| 40 | 23 | ||
| 41 | - - name: Install system dependencies | ||
| 42 | - if: runner.os == 'Linux' | ||
| 43 | - run: | | ||
| 44 | - pak::local_system_requirements(execute = TRUE) | ||
| 45 | - pak::pkg_system_requirements("pkgdown", execute = TRUE) | ||
| 46 | - shell: Rscript {0} | ||
| 47 | - | ||
| 48 | - - name: Install dependencies | ||
| 49 | - run: | | ||
| 50 | - pak::local_install(dependencies = FALSE) | ||
| 51 | - pak::local_install_dev_deps("cpp11test", dependencies = TRUE) | ||
| 52 | - install.packages("cpp11test", repos = NULL, INSTALL_opts = "--install-tests") | ||
| 53 | - pak::local_install(dependencies = TRUE) | ||
| 54 | - pak::pkg_install("pkgdown") | ||
| 55 | - shell: Rscript {0} | ||
| 56 | - | ||
| 57 | - - name: Install package | ||
| 58 | - run: R CMD INSTALL . | ||
| 24 | + - uses: r-lib/actions/setup-r-dependencies@v1 | ||
| 25 | + with: | ||
| 26 | + extra-packages: local::. local::cpp11test pkgdown | ||
| 27 | + needs: website | ||
| 59 | 28 | ||
| 60 | - - name: Build and deploy pkgdown site | ||
| 29 | + - name: Deploy package | ||
| 61 | 30 | env: | |
| 62 | 31 | CPP11_EVAL: true | |
| 63 | 32 | run: | | |
| Back | FazBrowse Home | New Git URL |
0 commit comments