From c032cb1f4a06f0de41db61581368da39c72ea9ed Mon Sep 17 00:00:00 2001 From: Rhian Davies Date: Tue, 27 Feb 2024 21:53:24 +0000 Subject: [PATCH 1/4] chore: update github actions --- .github/workflows/R-CMD-check.yaml | 20 +++++++++------- .github/workflows/pkgdown.yaml | 35 +++++++++++++++++++--------- .github/workflows/test-coverage.yaml | 32 ++++++++++++++++++++----- 3 files changed, 62 insertions(+), 25 deletions(-) diff --git a/.github/workflows/R-CMD-check.yaml b/.github/workflows/R-CMD-check.yaml index 271d466..14159b7 100644 --- a/.github/workflows/R-CMD-check.yaml +++ b/.github/workflows/R-CMD-check.yaml @@ -1,4 +1,4 @@ -# Workflow derived from https://github.com/r-lib/actions/tree/master/examples +# Workflow derived from https://github.com/r-lib/actions/tree/v2/examples # Need help debugging build failures? Start at https://github.com/r-lib/actions#where-to-find-help on: push: @@ -18,7 +18,7 @@ jobs: fail-fast: false matrix: config: - - {os: macOS-latest, r: 'release'} + - {os: macos-latest, r: 'release'} - {os: windows-latest, r: 'release'} - {os: ubuntu-latest, r: 'devel', http-user-agent: 'release'} - {os: ubuntu-latest, r: 'release'} @@ -29,18 +29,22 @@ jobs: R_KEEP_PKG_SOURCE: yes steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - - uses: r-lib/actions/setup-pandoc@v1 + - uses: r-lib/actions/setup-pandoc@v2 - - uses: r-lib/actions/setup-r@v1 + - uses: r-lib/actions/setup-r@v2 with: r-version: ${{ matrix.config.r }} http-user-agent: ${{ matrix.config.http-user-agent }} use-public-rspm: true - - uses: r-lib/actions/setup-r-dependencies@v1 + - uses: r-lib/actions/setup-r-dependencies@v2 with: - extra-packages: rcmdcheck + extra-packages: any::rcmdcheck + needs: check - - uses: r-lib/actions/check-r-package@v1 + - uses: r-lib/actions/check-r-package@v2 + with: + upload-snapshots: true + build_args: 'c("--no-manual","--compact-vignettes=gs+qpdf")' diff --git a/.github/workflows/pkgdown.yaml b/.github/workflows/pkgdown.yaml index 63cbb18..a7276e8 100644 --- a/.github/workflows/pkgdown.yaml +++ b/.github/workflows/pkgdown.yaml @@ -1,8 +1,10 @@ -# Workflow derived from https://github.com/r-lib/actions/tree/master/examples +# Workflow derived from https://github.com/r-lib/actions/tree/v2/examples # Need help debugging build failures? Start at https://github.com/r-lib/actions#where-to-find-help on: push: branches: [main, master] + pull_request: + branches: [main, master] release: types: [published] workflow_dispatch: @@ -12,24 +14,35 @@ name: pkgdown jobs: pkgdown: runs-on: ubuntu-latest + # Only restrict concurrency for non-PR jobs + concurrency: + group: pkgdown-${{ github.event_name != 'pull_request' || github.run_id }} env: GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }} + permissions: + contents: write steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - - uses: r-lib/actions/setup-pandoc@v1 + - uses: r-lib/actions/setup-pandoc@v2 - - uses: r-lib/actions/setup-r@v1 + - uses: r-lib/actions/setup-r@v2 with: use-public-rspm: true - - uses: r-lib/actions/setup-r-dependencies@v1 + - uses: r-lib/actions/setup-r-dependencies@v2 with: - extra-packages: pkgdown + extra-packages: any::pkgdown, local::. 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)' + - name: Build site + run: pkgdown::build_site_github_pages(new_process = FALSE, install = FALSE) + shell: Rscript {0} + + - name: Deploy to GitHub pages 🚀 + if: github.event_name != 'pull_request' + uses: JamesIves/github-pages-deploy-action@v4.5.0 + with: + clean: false + branch: gh-pages + folder: docs diff --git a/.github/workflows/test-coverage.yaml b/.github/workflows/test-coverage.yaml index 3c0da1c..21b8a93 100644 --- a/.github/workflows/test-coverage.yaml +++ b/.github/workflows/test-coverage.yaml @@ -1,4 +1,4 @@ -# Workflow derived from https://github.com/r-lib/actions/tree/master/examples +# Workflow derived from https://github.com/r-lib/actions/tree/v2/examples # Need help debugging build failures? Start at https://github.com/r-lib/actions#where-to-find-help on: push: @@ -15,16 +15,36 @@ jobs: GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }} steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - - uses: r-lib/actions/setup-r@v1 + - uses: r-lib/actions/setup-r@v2 with: use-public-rspm: true - - uses: r-lib/actions/setup-r-dependencies@v1 + - uses: r-lib/actions/setup-r-dependencies@v2 with: - extra-packages: covr + extra-packages: any::covr + needs: coverage - name: Test coverage - run: covr::codecov() + run: | + covr::codecov( + quiet = FALSE, + clean = FALSE, + install_path = file.path(normalizePath(Sys.getenv("RUNNER_TEMP"), winslash = "/"), "package") + ) shell: Rscript {0} + + - name: Show testthat output + if: always() + run: | + ## -------------------------------------------------------------------- + find '${{ runner.temp }}/package' -name 'testthat.Rout*' -exec cat '{}' \; || true + shell: bash + + - name: Upload test results + if: failure() + uses: actions/upload-artifact@v4 + with: + name: coverage-test-failures + path: ${{ runner.temp }}/package From 8c15710b30b0aefde6735925ffdcaa615f056260 Mon Sep 17 00:00:00 2001 From: Rhian Davies Date: Tue, 27 Feb 2024 22:09:03 +0000 Subject: [PATCH 2/4] chore: update maintainer --- CODE_OF_CONDUCT.md | 2 +- DESCRIPTION | 10 +++++----- NEWS.md | 4 ++++ README.Rmd | 1 + 4 files changed, 11 insertions(+), 6 deletions(-) diff --git a/CODE_OF_CONDUCT.md b/CODE_OF_CONDUCT.md index e687005..24e042e 100644 --- a/CODE_OF_CONDUCT.md +++ b/CODE_OF_CONDUCT.md @@ -59,7 +59,7 @@ representative at an online or offline event. ## Enforcement Instances of abusive, harassing, or otherwise unacceptable behavior may be -reported to the community leaders responsible for enforcement at rhian@jumpingrivers.com. +reported to the community leaders responsible for enforcement at colin@jumpingrivers.com. All complaints will be reviewed and investigated promptly and fairly. All community leaders are obligated to respect the privacy and security of the diff --git a/DESCRIPTION b/DESCRIPTION index 82f35a3..3797493 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,11 +1,11 @@ Package: namer Title: Names Your 'R Markdown' Chunks -Version: 0.1.7 +Version: 0.1.8 Authors@R: - c(person(given = "Rhian", - family = "Davies", + c(person(given = "Colin", + family = "Gillespie", role = c("aut", "cre"), - email = "rhian@jumpingrivers.com"), + email = "colin@jumpingrivers.com"), person(given = "Steph", family = "Locke", role = c("aut"), @@ -59,4 +59,4 @@ VignetteBuilder: Encoding: UTF-8 Language: en-GB LazyData: true -RoxygenNote: 7.1.2 +RoxygenNote: 7.2.3 diff --git a/NEWS.md b/NEWS.md index ed32fb2..2e75b06 100644 --- a/NEWS.md +++ b/NEWS.md @@ -1,3 +1,7 @@ +# namer 0.1.8 + +* Update maintainer + # namer 0.1.7 * `name_dir_chunks()` now also names chunks in Quarto-Files. Note that Quarto chunks are labelled in the RMarkdown style (` ```{r mylabel} `), *not* in the Quarto style (see below): diff --git a/README.Rmd b/README.Rmd index b5f1c15..3bf2a7b 100644 --- a/README.Rmd +++ b/README.Rmd @@ -20,6 +20,7 @@ knitr::opts_chunk$set( [![R-CMD-check](https://github.com/jumpingrivers/namer/workflows/R-CMD-check/badge.svg)](https://github.com/jumpingrivers/namer/actions) [![CRAN status](https://www.r-pkg.org/badges/version/namer)](https://CRAN.R-project.org/package=namer) [![Codecov test coverage](https://codecov.io/gh/jumpingrivers/namer/branch/main/graph/badge.svg)](https://app.codecov.io/gh/jumpingrivers/namer?branch=main) +[![R-CMD-check](https://github.com/jumpingrivers/namer/actions/workflows/R-CMD-check.yaml/badge.svg)](https://github.com/jumpingrivers/namer/actions/workflows/R-CMD-check.yaml) ```{r child="man/rmdfragments/intro.Rmd"} From 9f86da0714bc73c5956bac736f1dd39507d6e3f9 Mon Sep 17 00:00:00 2001 From: Rhian Davies Date: Thu, 29 Feb 2024 11:33:22 +0000 Subject: [PATCH 3/4] chore: fix NEWS --- NEWS.md | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/NEWS.md b/NEWS.md index 2e75b06..88bdf77 100644 --- a/NEWS.md +++ b/NEWS.md @@ -9,14 +9,13 @@ ```` ```{r} #| label: mylabel -``` ```` # namer 0.1.6 * Update maintainer -# namer (development version) +# namer 0.1.5 * `name_chunks()` and `name_dir_chunks()` are now able to unname all chunks before naming them. This ensures a consistent naming for all chunks instead of just labelling unnamed chunks (@pat-s, #23). @@ -26,8 +25,6 @@ * added some `cli` verbosity (@pat-s, #23) -# namer 0.1.5 - * The tests using rmarkdown are now skipped if Pandoc 1.12.3 (minimal version for rmarkdown) is not available. * unname_all_chunks now accepts argument `chunk_name_prefix` with the prefix of the chunknames to be unnamed (@HanOostdijk, #22) From 3e6fa685f87685bf1309e029d3322872a4baefde Mon Sep 17 00:00:00 2001 From: Rhian Davies Date: Thu, 29 Feb 2024 11:33:34 +0000 Subject: [PATCH 4/4] chore: update comments for CRAN --- cran-comments.md | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/cran-comments.md b/cran-comments.md index f804f0c..858617d 100644 --- a/cran-comments.md +++ b/cran-comments.md @@ -1,11 +1,5 @@ ## R CMD check results -0 errors | 0 warnings | 0 note +0 errors | 0 warnings | 1 note -* This is a re-release of a package which came off CRAN. - -## Release Summary - -* We fixed failing tests. -* We have fixed documentations errors. -* Switched maintainer. +* This is a new release.