Skip to content

Commit

Permalink
Merge pull request #19 from giannou/master
Browse files Browse the repository at this point in the history
version bump after bugfix ff2706e
  • Loading branch information
giannou committed Jul 6, 2023
2 parents ff2706e + 666ef64 commit c418a3d
Show file tree
Hide file tree
Showing 9 changed files with 70 additions and 51 deletions.
1 change: 1 addition & 0 deletions .Rbuildignore
Original file line number Diff line number Diff line change
Expand Up @@ -10,3 +10,4 @@
^codecov\.yml$
^\.github$
^Makefile$
^.*CITATION.cff$
2 changes: 1 addition & 1 deletion .buildlibrary
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
ValidationKey: '5743683'
ValidationKey: '5824112'
AutocreateReadme: yes
AcceptedWarnings:
- 'Warning: package ''.*'' was built under R version'
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Run CI for R using https://eddelbuettel.github.io/r-ci/

name: lucode2-check
name: check

on:
push:
Expand All @@ -14,11 +14,11 @@ env:
NO_BINARY_INSTALL_R_PACKAGES: 'c("madrat", "magclass", "citation", "gms", "goxygen", "GDPuc", "roxygen2")'

jobs:
lucode2-check:
check:
runs-on: ubuntu-latest

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

- name: Bootstrap
run: |
Expand All @@ -28,6 +28,7 @@ jobs:
curl -OLs https://eddelbuettel.github.io/r-ci/run.sh
chmod 0755 run.sh
./run.sh bootstrap
rm -f bspm_*.tar.gz
- name: Enable r-universe repo, modify bspm integration
run: |
Expand All @@ -48,17 +49,18 @@ jobs:
pkgs <- c(bspm::install_sys(pkgs[!pkgs %%in%% noBinaryInstallRPackages]),
pkgs[pkgs %%in%% noBinaryInstallRPackages])
}
type <- "source"
})
trace(utils::install.packages, expr, print = FALSE)
})
' "$NO_BINARY_INSTALL_R_PACKAGES" | sudo tee --append /etc/R/Rprofile.site >/dev/null
cat /etc/R/Rprofile.site
- name: Set up Pandoc
uses: r-lib/actions/setup-pandoc@v1
uses: r-lib/actions/setup-pandoc@v2

- name: Set up Python 3.9
uses: actions/setup-python@v2
uses: actions/setup-python@v4
with:
python-version: 3.9

Expand All @@ -67,9 +69,9 @@ jobs:
uses: pat-s/always-upload-cache@v3
with:
path: /usr/local/lib/R/
key: 2-${{ runner.os }}-usr-local-lib-R-${{ hashFiles('DESCRIPTION') }}
key: 3-${{ runner.os }}-usr-local-lib-R-${{ hashFiles('DESCRIPTION') }}
restore-keys: |
2-${{ runner.os }}-usr-local-lib-R-
3-${{ runner.os }}-usr-local-lib-R-
- name: Restore R library permissions
run: |
Expand Down
2 changes: 1 addition & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ repos:
- id: mixed-line-ending

- repo: https://github.com/lorenzwalthert/precommit
rev: v0.3.2.9003
rev: v0.3.2.9013
hooks:
- id: parsable-R
- id: deps-in-desc
Expand Down
28 changes: 0 additions & 28 deletions .zenodo.json

This file was deleted.

26 changes: 26 additions & 0 deletions CITATION.cff
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
cff-version: 1.2.0
message: If you use this software, please cite it using the metadata from this file.
type: software
title: 'iamc: IAMC Tools'
version: 0.29.8
date-released: '2023-07-06'
abstract: A collection of R tools provided by the Integrated Assessment Modeling Consortium
(IAMC) for data analysis and diagnostics.
authors:
- family-names: Dietrich
given-names: Jan Philipp
email: dietrich@pik-potsdam.de
- family-names: Auer
given-names: Cornelia
- family-names: Giannousakis
given-names: Anastasis
- family-names: Bertram
given-names: Christoph
- family-names: Benke
given-names: Falk
- family-names: Humpenoeder
given-names: Florian
- family-names: Baumstark
given-names: Lavinia
license: MIT

6 changes: 3 additions & 3 deletions DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
Package: iamc
Type: Package
Title: IAMC Tools
Version: 0.29.7
Date: 2022-12-13
Version: 0.29.8
Date: 2023-07-06
Authors@R: c(person("Jan Philipp", "Dietrich", email = "dietrich@pik-potsdam.de", role = c("aut","cre")),
person("Cornelia", "Auer", role = "aut"),
person("Anastasis", "Giannousakis", role = "aut"),
Expand All @@ -26,7 +26,7 @@ Imports: quitte(>= 0.3066),
writexl
Encoding: UTF-8
LazyData: true
RoxygenNote: 7.2.2
RoxygenNote: 7.2.3
Suggests:
covr,
knitr,
Expand Down
30 changes: 24 additions & 6 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.PHONY: help build check test lint format
.PHONY: help build check test lint lint-all format format-all install docs
.DEFAULT_GOAL = help

# extracts the help text and formats it nicely
Expand All @@ -11,18 +11,36 @@ HELP_PARSING = 'm <- readLines("Makefile");\
help: ## Show this help.
@Rscript -e $(HELP_PARSING)

build: ## Build the package using lucode2::buildLibrary()
Rscript -e 'lucode2::buildLibrary()'
build: ## Build the package using lucode2::buildLibrary(). You can pass the
## updateType with 'make build u=3'
Rscript -e 'lucode2::buildLibrary(updateType = "$(u)")'

check: ## Build documentation and vignettes, run testthat tests,
## and check if code etiquette is followed using lucode2::check()
## and check if code etiquette is followed using lucode2::check().
Rscript -e 'lucode2::check()'

test: ## Run testthat tests
Rscript -e 'devtools::test(show_report = TRUE)'

lint: ## Check if code etiquette is followed using lucode2::lint()
lint: ## Check if code etiquette is followed using lucode2::lint().
## Only checks files you changed.
Rscript -e 'lucode2::lint()'

format: ## Apply auto-formatting to changed files and lint afterwards
lint-all: ## Check if code etiquette is followed using lucode2::lint().
## Checks all files.
Rscript -e 'lucode2::lint(".")'

format: ## Apply auto-formatting to changed files and lint afterwards.
Rscript -e 'lucode2::autoFormat()'

format-all: ## Apply auto-formatting to all files and lint afterwards.
Rscript -e 'lucode2::autoFormat(files=list.files("./R", full.names = TRUE, pattern = "\\.R"))'

install: ## Install the package locally via devtools::install() after
## generating NAMESPACE and docs (see docs target).
Rscript -e 'roxygen2::roxygenize(); devtools::install(upgrade = "never")'

docs: ## Generate the package documentation (man/*.Rd files) and
## NAMESPACE via roxygen2::roxygenize(), view the generated
## documentation with `?package::function`.
Rscript -e 'roxygen2::roxygenize()'
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
# IAMC Tools

R package **iamc**, version **0.29.7**
R package **iamc**, version **0.29.8**

[![CRAN status](https://www.r-pkg.org/badges/version/iamc)](https://cran.r-project.org/package=iamc) [![R build status](https://github.com/orichters/iamc/workflows/check/badge.svg)](https://github.com/orichters/iamc/actions) [![codecov](https://codecov.io/gh/orichters/iamc/branch/master/graph/badge.svg)](https://app.codecov.io/gh/orichters/iamc) [![r-universe](https://pik-piam.r-universe.dev/badges/iamc)](https://pik-piam.r-universe.dev/ui#builds)
[![CRAN status](https://www.r-pkg.org/badges/version/iamc)](https://cran.r-project.org/package=iamc) [![R build status](https://github.com/giannou/iamc/workflows/check/badge.svg)](https://github.com/giannou/iamc/actions) [![codecov](https://codecov.io/gh/giannou/iamc/branch/master/graph/badge.svg)](https://app.codecov.io/gh/giannou/iamc) [![r-universe](https://pik-piam.r-universe.dev/badges/iamc)](https://pik-piam.r-universe.dev/builds)

## Purpose and Functionality

Expand Down Expand Up @@ -46,15 +46,15 @@ In case of questions / problems please contact Jan Philipp Dietrich <dietrich@pi

To cite package **iamc** in publications use:

Dietrich J, Auer C, Giannousakis A, Bertram C, Benke F, Humpenoeder F, Baumstark L (2022). _iamc: IAMC Tools_. R package version 0.29.7.
Dietrich J, Auer C, Giannousakis A, Bertram C, Benke F, Humpenoeder F, Baumstark L (2023). _iamc: IAMC Tools_. R package version 0.29.8.

A BibTeX entry for LaTeX users is

```latex
@Manual{,
title = {iamc: IAMC Tools},
author = {Jan Philipp Dietrich and Cornelia Auer and Anastasis Giannousakis and Christoph Bertram and Falk Benke and Florian Humpenoeder and Lavinia Baumstark},
year = {2022},
note = {R package version 0.29.7},
year = {2023},
note = {R package version 0.29.8},
}
```

0 comments on commit c418a3d

Please sign in to comment.