Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
84 changes: 19 additions & 65 deletions .github/workflows/R-CMD-check.yaml
Original file line number Diff line number Diff line change
@@ -1,11 +1,13 @@
on:
push:
branches:
- main
- master
- development
- LandWeb
pull_request:
branches:
- main
- master
- development

Expand All @@ -24,81 +26,33 @@ jobs:
- {os: macOS-latest, r: 'release'}
- {os: windows-latest, r: 'devel'}
- {os: windows-latest, r: 'release'}
- {os: windows-latest, r: '3.6'}
- {os: ubuntu-18.04, r: 'devel', rspm: "https://packagemanager.rstudio.com/cran/__linux__/bionic/latest", http-user-agent: "R/4.0.0 (ubuntu-18.04) R (4.0.0 x86_64-pc-linux-gnu x86_64 linux-gnu) on GitHub Actions" }
- {os: ubuntu-18.04, r: 'release', rspm: "https://packagemanager.rstudio.com/cran/__linux__/bionic/latest"}
- {os: ubuntu-18.04, r: 'oldrel', rspm: "https://packagemanager.rstudio.com/cran/__linux__/bionic/latest"}
- {os: windows-latest, r: 'oldrel'}
- {os: ubuntu-latest, r: 'devel'}
- {os: ubuntu-latest, r: 'release'}
- {os: ubuntu-latest, r: 'oldrel'}

env:
R_REMOTES_NO_ERRORS_FROM_WARNINGS: true
RSPM: ${{ matrix.config.rspm }}
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4

- uses: r-lib/actions/setup-r@master
- uses: r-lib/actions/setup-pandoc@v2

- uses: r-lib/actions/setup-r@v2
with:
Ncpus: 2
r-version: ${{ matrix.config.r }}
http-user-agent: ${{ matrix.config.http-user-agent }}

- uses: r-lib/actions/setup-pandoc@master
use-public-rspm: false

- 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
if: runner.os != 'Windows'
uses: actions/cache@v1
- uses: r-lib/actions/setup-r-dependencies@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 system dependencies
if: runner.os == 'Linux'
run: |
while read -r cmd
do
eval sudo $cmd
done < <(Rscript -e 'cat(remotes::system_requirements("ubuntu", "18.04"), sep = "\n")')
sudo apt-get install -y hunspell-en-ca

- name: Install dependencies
run: |
if (R.version$major < 4) {
remotes::install_cran("versions")
versions::install.versions("XML", "3.99-0.3")
}
remotes::install_deps(dependencies = TRUE)
remotes::install_cran("rcmdcheck")
shell: Rscript {0}

- name: Session info
run: |
options(width = 100)
pkgs <- installed.packages()[, "Package"]
sessioninfo::session_info(pkgs, include_base = TRUE)
shell: Rscript {0}

- name: Check
env:
_R_CHECK_CRAN_INCOMING_: false
run: rcmdcheck::rcmdcheck(args = c("--no-manual", "--as-cran"), error_on = "warning", check_dir = "check")
shell: Rscript {0}

- name: Show testthat output
if: always()
run: find check -name 'testthat.Rout*' -exec cat '{}' \; || true
shell: bash
extra-packages: |
any::rcmdcheck
any::Rcpp
needs: check

- name: Upload check results
if: failure()
uses: actions/upload-artifact@main
- uses: r-lib/actions/check-r-package@v2
with:
name: ${{ runner.os }}-r${{ matrix.config.r }}-results
path: check
upload-snapshots: true
34 changes: 11 additions & 23 deletions .github/workflows/test-coverage.yaml
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
on:
push:
branches:
- main
- master
- development
pull_request:
branches:
- main
- master
- development

Expand All @@ -13,37 +15,23 @@ name: test-coverage
jobs:
test-coverage:
runs-on: macOS-latest

env:
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}

steps:
- uses: actions/checkout@v2

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

- uses: r-lib/actions/setup-pandoc@master
- uses: actions/checkout@v4

- 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}
- uses: r-lib/actions/setup-pandoc@v2

- name: Cache R packages
uses: actions/cache@v1
- uses: r-lib/actions/setup-r@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-
Ncpus: 2
use-public-rspm: false

- name: Install dependencies
run: |
install.packages(c("remotes"))
remotes::install_deps(dependencies = TRUE)
remotes::install_cran("covr")
shell: Rscript {0}
- uses: r-lib/actions/setup-r-dependencies@v2
with:
extra-packages: |
any::covr

- name: Test coverage
run: covr::codecov()
Expand Down
39 changes: 19 additions & 20 deletions DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,29 +1,28 @@
Package: peutils
Type: Package
Package: peutils
Title: Utilities Developed by the Predictive Ecology Group
Version: 0.1.0
Version: 0.1.1
Date: 2026-01-26
Authors@R: c(
person("Eliot J B", "McIntire", email = "eliot.mcintire@canada.ca",
role = c("aut", "cre"), comment=c(ORCID = "0000-0002-6914-8316")),
person("Alex M", "Chubaty", email = "achubaty@for-cast.ca",
role = c("aut"), comment = c(ORCID = "0000-0001-7146-8135")),
person("Her Majesty the Queen in Right of Canada, as represented by the Minister of Natural Resources Canada",
role = "cph")
)
Description: Dependency-free utilities developed by the Predictive Ecology Group
(<http://predictiveecology.org>). (Do not depend on contributed R packages).
URL:
http://peutils.predictiveecology.org,
https://github.com/PredictiveEcology/peutils
Date: 2020-08-28
Encoding: UTF-8
Language: en-CA
person("Eliot J B", "McIntire", , "eliot.mcintire@canada.ca", role = c("aut", "cre"),
comment = c(ORCID = "0000-0002-6914-8316")),
person("Alex M", "Chubaty", , "achubaty@for-cast.ca", role = "aut",
comment = c(ORCID = "0000-0001-7146-8135")),
person("His Majesty the Queen in Right of Canada, as represented by the Minister of Natural Resources Canada", role = "cph")
)
Description: Dependency-free utilities developed by the Predictive Ecology
Group (<http://predictiveecology.org>). (Do not depend on contributed
R packages).
License: GPL-3
URL: http://peutils.predictiveecology.org,
https://github.com/PredictiveEcology/peutils
BugReports: https://github.com/PredictiveEcology/peutils/issues
ByteCompile: yes
LazyData: true
RoxygenNote: 7.1.1
Suggests:
covr,
spelling,
testthat
ByteCompile: yes
Encoding: UTF-8
Language: en-CA
LazyData: true
RoxygenNote: 7.3.3
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,5 @@ These are intended to be _dependency-free_ (i.e., do not import from contributed

<!-- badges: start -->
[![R build status](https://github.com/PredictiveEcology/peutils/workflows/R-CMD-check/badge.svg)](https://github.com/PredictiveEcology/peutils/actions)
[![Codecov test coverage](https://codecov.io/gh/PredictiveEcology/peutils/branch/master/graph/badge.svg)](https://codecov.io/gh/PredictiveEcology/peutils?branch=master)
[![Codecov test coverage](https://codecov.io/gh/PredictiveEcology/peutils/branch/master/graph/badge.svg)](https://app.codecov.io/gh/PredictiveEcology/peutils?branch=master)
<!-- badges: end -->