From 55b884882b4ad9d9f2361c478329bd3d0bd25226 Mon Sep 17 00:00:00 2001 From: Diego H Date: Thu, 27 Oct 2022 14:56:18 +0000 Subject: [PATCH] Try fix actions --- .github/dependabot.yml | 15 ++++++++++ .github/workflows/pkgdown-gh-pages-clean.yaml | 22 ++++++++++----- .github/workflows/rostemplate-gh-pages.yaml | 22 ++++++++++----- .github/workflows/update-docs.yaml | 28 ++++++++++++------- 4 files changed, 63 insertions(+), 24 deletions(-) create mode 100644 .github/dependabot.yml diff --git a/.github/dependabot.yml b/.github/dependabot.yml new file mode 100644 index 00000000..a1761a3c --- /dev/null +++ b/.github/dependabot.yml @@ -0,0 +1,15 @@ +# To get started with Dependabot version updates, you'll need to specify which +# package ecosystems to update and where the package manifests are located. +# Please see the documentation for all configuration options: +# https://docs.github.com/github/administering-a-repository/configuration-options-for-dependency-updates + +# Basic set up for three package managers + +version: 2 +updates: + + # Maintain dependencies for GitHub Actions + - package-ecosystem: "github-actions" + directory: "/" + schedule: + interval: "weekly" diff --git a/.github/workflows/pkgdown-gh-pages-clean.yaml b/.github/workflows/pkgdown-gh-pages-clean.yaml index c11b07e5..cc18a859 100644 --- a/.github/workflows/pkgdown-gh-pages-clean.yaml +++ b/.github/workflows/pkgdown-gh-pages-clean.yaml @@ -5,17 +5,19 @@ name: Clean pkgdown manually jobs: pkgdown-gh-pages-manual: - runs-on: macos-latest + runs-on: ubuntu-latest env: GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }} + CURL_SSL_BACKEND: "openssl" steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - uses: r-lib/actions/setup-pandoc@v2 - uses: r-lib/actions/setup-r@v2 with: use-public-rspm: true + install-r: true - uses: r-lib/actions/setup-r-dependencies@v2 with: @@ -33,8 +35,14 @@ jobs: ropensci/rnaturalearthhires needs: website - - name: Deploy package - run: | - git config --local user.name "dieghernan" - git config --local user.email "dieghernan@users.noreply.github.com" - Rscript -e 'pkgdown::deploy_to_branch(new_process = FALSE, clean = TRUE, run_dont_run = TRUE)' + - name: Build site + run: pkgdown::build_site_github_pages(new_process = FALSE, run_dont_run = TRUE, clean = TRUE) + shell: Rscript {0} + + - name: Deploy to GitHub pages 🚀 + if: github.event_name != 'pull_request' + uses: JamesIves/github-pages-deploy-action@v4.4.1 + with: + clean: false + branch: gh-pages + folder: docs diff --git a/.github/workflows/rostemplate-gh-pages.yaml b/.github/workflows/rostemplate-gh-pages.yaml index ae39c8be..799f8878 100644 --- a/.github/workflows/rostemplate-gh-pages.yaml +++ b/.github/workflows/rostemplate-gh-pages.yaml @@ -11,17 +11,19 @@ name: rostemplate-gh-pages jobs: rostemplate-gh-pages: - runs-on: macos-latest + runs-on: ubuntu-latest env: GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }} + CURL_SSL_BACKEND: "openssl" steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - uses: r-lib/actions/setup-pandoc@v2 - uses: r-lib/actions/setup-r@v2 with: use-public-rspm: true + install-r: true - uses: r-lib/actions/setup-r-dependencies@v2 with: @@ -39,8 +41,14 @@ jobs: ropensci/rnaturalearthhires needs: website - - name: Deploy package - run: | - git config --local user.name "$GITHUB_ACTOR" - git config --local user.email "$GITHUB_ACTOR@users.noreply.github.com" - Rscript -e 'pkgdown::deploy_to_branch(new_process = FALSE, run_dont_run = TRUE)' + - name: Build site + run: pkgdown::build_site_github_pages(new_process = FALSE, run_dont_run = TRUE) + shell: Rscript {0} + + - name: Deploy to GitHub pages 🚀 + if: github.event_name != 'pull_request' + uses: JamesIves/github-pages-deploy-action@v4.4.1 + with: + clean: false + branch: gh-pages + folder: docs diff --git a/.github/workflows/update-docs.yaml b/.github/workflows/update-docs.yaml index f7ccea3f..c8562482 100644 --- a/.github/workflows/update-docs.yaml +++ b/.github/workflows/update-docs.yaml @@ -5,18 +5,20 @@ name: update-docs jobs: update-docs: - runs-on: macos-latest + runs-on: ubuntu-latest env: GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }} + CURL_SSL_BACKEND: "openssl" steps: - - uses: actions/checkout@v2 - + - uses: actions/checkout@v3 + - uses: r-lib/actions/setup-pandoc@v2 - uses: r-lib/actions/setup-r@v2 with: use-public-rspm: true - + install-r: true + - uses: r-lib/actions/setup-r-dependencies@v2 with: @@ -51,10 +53,16 @@ jobs: git push origin || echo "No changes to commit" - uses: r-lib/actions/check-r-package@v2 - - - name: Deploy package - run: | - git config --local user.name "$GITHUB_ACTOR" - git config --local user.email "$GITHUB_ACTOR@users.noreply.github.com" - Rscript -e 'pkgdown::deploy_to_branch(new_process = FALSE, run_dont_run = TRUE)' + + - name: Build site + run: pkgdown::build_site_github_pages(new_process = FALSE, run_dont_run = TRUE) + shell: Rscript {0} + + - name: Deploy to GitHub pages 🚀 + if: github.event_name != 'pull_request' + uses: JamesIves/github-pages-deploy-action@v4.4.1 + with: + clean: false + branch: gh-pages + folder: docs