Skip to content

Commit c12db96

Browse files
committed
Merge branch 'devel'
# Conflicts: # .github/workflows/GitHub_Actions_CI.yaml # RLumBuild.BuildResults/RLumBuild-TimingExamples.0.1.7.pdf # RLumBuild.BuildResults/RLumBuild_0.1.6.pdf # RLumBuild.BuildResults/RLumBuild_0.1.6.tar.gz
2 parents d7b5cb5 + b83bf3f commit c12db96

File tree

60 files changed

+347
-790
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

60 files changed

+347
-790
lines changed
Lines changed: 31 additions & 81 deletions
Original file line numberDiff line numberDiff line change
@@ -1,109 +1,59 @@
11
# CI GitHub Action ... adapted from usethis::use_github_actions()
22
on:
33
push:
4-
branches:
5-
- master
6-
- dev_*
7-
- devel
4+
branches: [master, devel]
5+
86
pull_request:
9-
branches:
10-
- master
11-
- dev_*
12-
- devel
7+
branches: [master, devel]
138

149
name: GitHub Actions CI
1510

11+
## change if caches needs to be refreshed
12+
env:
13+
cache-version: v2
14+
1615
jobs:
1716
R-CMD-check:
1817
runs-on: ${{ matrix.config.os }}
18+
1919
name: ${{ matrix.config.os }} (${{ matrix.config.r }})
20+
2021
strategy:
2122
fail-fast: false
2223
matrix:
2324
config:
24-
- {os: macOS-latest, r: 'release'}
25-
- {os: macOS-latest, r: 'oldrel'}
26-
- {os: ubuntu-16.04, r: 'devel', rspm: "https://packagemanager.rstudio.com/cran/__linux__/xenial/latest", http-user-agent: "R/4.0.0 (ubuntu-16.04) R (4.0.0 x86_64-pc-linux-gnu x86_64 linux-gnu) on GitHub Actions" }
27-
- {os: ubuntu-16.04, r: 'release', rspm: "https://packagemanager.rstudio.com/cran/__linux__/xenial/latest"}
28-
- {os: ubuntu-16.04, r: 'oldrel', rspm: "https://packagemanager.rstudio.com/cran/__linux__/xenial/latest"}
29-
- {os: windows-latest, r: 'devel'}
30-
- {os: windows-latest, r: 'release'}
31-
- {os: windows-latest, r: 'oldrel'}
32-
25+
- {os: windows-latest, r: 'oldrel', not_cran: 'true'}
26+
- {os: windows-latest, r: 'release', not_cran: 'true'}
27+
- {os: windows-latest, r: 'devel', not_cran: 'true'}
28+
- {os: windows-2019, r: 'oldrel', not_cran: 'true'}
29+
- {os: macos-12, r: 'release', not_cran: 'true'}
30+
- {os: macos-11, r: 'oldrel', not_cran: 'true'}
31+
- {os: ubuntu-latest, r: 'devel', not_cran: 'true'}
32+
- {os: ubuntu-latest, r: 'release', not_cran: 'true'} #OK
33+
- {os: ubuntu-latest, r: 'oldrel', not_cran: 'true'}
3334
env:
34-
R_REMOTES_NO_ERRORS_FROM_WARNINGS: true
35+
_R_CHECK_FORCE_SUGGESTS_: true
3536
RSPM: ${{ matrix.config.rspm }}
3637
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}
38+
R_KEEP_PKG_SOURCE: yes
3739

3840
steps:
39-
- uses: actions/checkout@v2
41+
- uses: actions/checkout@v3
42+
43+
- uses: r-lib/actions/setup-pandoc@v2
4044

41-
- uses: r-lib/actions/setup-r@v1
45+
- uses: r-lib/actions/setup-r@v2
4246
with:
4347
r-version: ${{ matrix.config.r }}
4448
http-user-agent: ${{ matrix.config.http-user-agent }}
49+
use-public-rspm: true
4550

46-
- uses: r-lib/actions/setup-pandoc@v1
47-
48-
- name: Query dependencies
49-
run: |
50-
install.packages('remotes')
51-
saveRDS(remotes::dev_package_deps(dependencies = TRUE), ".github/depends.Rds", version = 2)
52-
writeLines(sprintf("R-%i.%i", getRversion()$major, getRversion()$minor), ".github/R-version")
53-
shell: Rscript {0}
54-
55-
- name: Cache R packages
56-
if: runner.os != 'Windows'
57-
uses: actions/cache@v2
51+
- uses: r-lib/actions/setup-r-dependencies@v2
5852
with:
59-
path: ${{ env.R_LIBS_USER }}
60-
key: ${{ runner.os }}-${{ hashFiles('.github/R-version') }}-1-${{ hashFiles('.github/depends.Rds') }}
61-
restore-keys: ${{ runner.os }}-${{ hashFiles('.github/R-version') }}-1-
62-
63-
- name: Install system dependencies
64-
if: runner.os == 'Linux'
65-
run: |
66-
while read -r cmd
67-
do
68-
eval sudo $cmd
69-
done < <(Rscript -e 'writeLines(remotes::system_requirements("ubuntu", "16.04"))')
70-
71-
- name: Install jags (Linux)
72-
if: runner.os == 'Linux'
73-
run: sudo apt-get install jags
74-
- name: Install jags (macOS)
75-
if: runner.os == 'macOS'
76-
run: |
77-
brew install jags
78-
79-
- name: Install dependencies
80-
run: |
81-
remotes::install_deps(dependencies = TRUE)
82-
remotes::install_cran("rcmdcheck")
83-
remotes::install_cran("covr")
84-
shell: Rscript {0}
85-
86-
- name: Session info
87-
run: |
88-
options(width = 100)
89-
pkgs <- installed.packages()[, "Package"]
90-
sessioninfo::session_info(pkgs, include_base = TRUE)
91-
shell: Rscript {0}
92-
93-
- name: Check
94-
env:
95-
_R_CHECK_CRAN_INCOMING_: false
96-
run: rcmdcheck::rcmdcheck(args = c("--no-manual", "--as-cran"), error_on = "warning", check_dir = "check")
97-
shell: Rscript {0}
98-
99-
- name: Show testthat output
100-
if: always()
101-
run: find check -name 'testthat.Rout*' -exec cat '{}' \; || true
102-
shell: bash
53+
extra-packages: |
54+
any::rcmdcheck
55+
needs: check
10356

104-
- name: Upload check results
105-
if: failure()
106-
uses: actions/upload-artifact@main
57+
- uses: r-lib/actions/check-r-package@v2
10758
with:
108-
name: ${{ runner.os }}-r${{ matrix.config.r }}-results
109-
path: check
59+
upload-snapshots: true

DESCRIPTION

Lines changed: 20 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,39 +1,39 @@
11
Package: RLumBuild
22
Type: Package
33
Title: RLum Universe Package Building
4-
Version: 0.1.6
5-
Date: 2021-07-15
4+
Version: 0.1.7
5+
Date: 2024-02-12
66
Author: Sebastian Kreutzer [aut, cre] (<https://orcid.org/0000-0002-0734-2199>),
77
Christoph Burow [aut] (<https://orcid.org/0000-0002-5023-4046>)
88
Authors@R: c(
9-
person("Sebastian", "Kreutzer", role = c("aut", "cre"), email = "sebastian.kreutzer@aber.ac.uk", comment = c(ORCID = "0000-0002-0734-2199")),
9+
person("Sebastian", "Kreutzer", role = c("aut", "cre"), email = "sebastian.kreutzer@uni-heidelberg.de", comment = c(ORCID = "0000-0002-0734-2199")),
1010
person("Christoph", "Burow", role = c("aut"), comment = c(ORCID = "0000-0002-5023-4046")))
11-
Maintainer: Sebastian Kreutzer <sebastian.kreutzer@aber.ac.uk>
11+
Maintainer: Sebastian Kreutzer <sebastian.kreutzer@uni-heidelberg.de>
1212
Description: Build packages from the RLum-universe.
1313
A collection of tools and scripts to unify the building of packages.
1414
License: GPL-3
1515
BugReports: https://github.com/R-Lum/RLumBuild/issues
1616
URL: https://github.com/R-Lum/RLumBuild
1717
Depends:
18-
R (>= 4.0.0),
18+
R (>= 4.2.0),
1919
utils
2020
Imports:
21-
crayon (>= 1.4.1),
22-
rmarkdown (>= 2.9),
23-
cli (>= 3.0.0),
24-
codemetar (>= 0.3.1),
25-
devtools (>= 2.4.2),
26-
jsonlite (>= 1.7.2),
27-
miniCRAN (>= 0.2.14),
28-
pander (>= 0.6.4),
29-
pkgbuild (>= 1.2.0),
30-
roxygen2 (>= 7.1.1),
31-
Rcpp (>= 1.0.7),
32-
R2HTML (>= 2.3.2),
33-
stringi (>= 1.7.2),
34-
stringr (>= 1.4.0),
21+
crayon (>= 1.5.2),
22+
rmarkdown (>= 2.25),
23+
cli (>= 3.6.2),
24+
codemetar (>= 0.3.5),
25+
devtools (>= 2.4.5),
26+
jsonlite (>= 1.8.8),
27+
miniCRAN (>= 0.2.16),
28+
pander (>= 0.6.5),
29+
pkgbuild (>= 1.4.3),
30+
roxygen2 (>= 7.3.1),
31+
Rcpp (>= 1.0.12),
32+
R2HTML (>= 2.3.3),
33+
stringi (>= 1.8.3),
34+
stringr (>= 1.5.1),
3535
tools,
3636
xtable (>= 1.8-4)
3737
Encoding: UTF-8
3838
LazyData: true
39-
RoxygenNote: 7.1.1
39+
RoxygenNote: 7.3.1

NEWS.Rmd

Lines changed: 3 additions & 50 deletions
Original file line numberDiff line numberDiff line change
@@ -9,53 +9,6 @@ header-includes:
99
# News for package 'RLumBuild'
1010

1111
## Changes in version `r RLumBuild::.get_pkg_version()` (`r Sys.Date()`)
12-
* Add new import from the package `'jsonlite'`
13-
* Add support to automatically update relevant information in the `.zenodo.json` file
14-
(if such a file exists) which are: title, description and version number.
15-
* Remove `Rplot.pdf` files eventually produced by manual `'testthat'` runs
16-
17-
## Changes in version 0.1.5 (2020-12-06)
18-
* Minimum R version requirement >= 3.5.0
19-
* Make sure that we catch all `.Rhistory` and `.RData` files in the folder
20-
* `.Rbuildignore` knows about the zenodo
21-
22-
## Changes in version 0.1.4 (2020-05-25)
23-
24-
* Add new module to automatically update `data/datalist` if data are shipped with the package
25-
* Add support for code meta data: https://ropensci.github.io/codemetar
26-
* Swap order: install now comes after the outro
27-
* `.Rbuildignore` update to exclude log-files that needed to be excluded
28-
* Slightly improve `module_add_HowToCite()` to avoid missing whitespace between the package name and the package version
29-
* Add `module_compactVignette()` to ensure that the PDF vignettes are not larger in size than needed
30-
31-
## Changes in version 0.1.3 (2019-07-31)
32-
33-
* Remote checks were not activated by default if `as-cran` was `TRUE`, this
34-
led to less rigour tests.
35-
36-
## Changes in version 0.1.2 (2019-07-30)
37-
38-
### `module_add_HowToCite()`
39-
40-
* Silence warnings by removing the cause
41-
* Function now creates and addiational BIB-file with all the function citations in it
42-
* If now patter `URL` was set in the DESCRIPTION file this module did not work
43-
44-
## Changes in version 0.1.1 (2019-05-08)
45-
46-
* Add build order: NEWS and README are created after the documentation was
47-
created, this allows customised scripts in the RMD-files and the version number
48-
is always consistent with the number from the build.
49-
50-
* Update and complete documentation
51-
52-
* `module_add_HowToCite()` now checks the URL field in the DESCRIPTION file and double
53-
checks this URL
54-
55-
* `module_add_RLumTeam()` was never working and activated; now ok.
56-
57-
58-
## Changes in version 0.1.0 (2019-05-03)
59-
60-
* Initial version
61-
12+
* `module_add_HowToCite()`: remove argument defunct by `stringi`
13+
* `module_add_HowToCite()`: exclude `-package` file from parsing
14+
* `module_add_RLumTeam()`: exclude `-package` file from parsing

NEWS.md

Lines changed: 4 additions & 60 deletions
Original file line numberDiff line numberDiff line change
@@ -7,64 +7,8 @@
77

88
# News for package ‘RLumBuild’
99

10-
## Changes in version 0.1.6 (2021-07-15)
10+
## Changes in version 0.1.7 (2024-02-12)
1111

12-
- Add new import from the package `'jsonlite'`
13-
- Add support to automatically update relevant information in the
14-
`.zenodo.json` file (if such a file exists) which are: title,
15-
description and version number.
16-
- Remove `Rplot.pdf` files eventually produced by manual `'testthat'`
17-
runs
18-
19-
## Changes in version 0.1.5 (2020-12-06)
20-
21-
- Minimum R version requirement >= 3.5.0
22-
- Make sure that we catch all `.Rhistory` and `.RData` files in the
23-
folder
24-
- `.Rbuildignore` knows about the zenodo
25-
26-
## Changes in version 0.1.4 (2020-05-25)
27-
28-
- Add new module to automatically update `data/datalist` if data are
29-
shipped with the package
30-
- Add support for code meta data:
31-
<https://ropensci.github.io/codemetar>
32-
- Swap order: install now comes after the outro
33-
- `.Rbuildignore` update to exclude log-files that needed to be
34-
excluded
35-
- Slightly improve `module_add_HowToCite()` to avoid missing
36-
whitespace between the package name and the package version
37-
- Add `module_compactVignette()` to ensure that the PDF vignettes are
38-
not larger in size than needed
39-
40-
## Changes in version 0.1.3 (2019-07-31)
41-
42-
- Remote checks were not activated by default if `as-cran` was `TRUE`,
43-
this led to less rigour tests.
44-
45-
## Changes in version 0.1.2 (2019-07-30)
46-
47-
### `module_add_HowToCite()`
48-
49-
- Silence warnings by removing the cause
50-
- Function now creates and addiational BIB-file with all the function
51-
citations in it
52-
- If now patter `URL` was set in the DESCRIPTION file this module did
53-
not work
54-
55-
## Changes in version 0.1.1 (2019-05-08)
56-
57-
- Add build order: NEWS and README are created after the documentation
58-
was created, this allows customised scripts in the RMD-files and the
59-
version number is always consistent with the number from the build.
60-
61-
- Update and complete documentation
62-
63-
- `module_add_HowToCite()` now checks the URL field in the DESCRIPTION
64-
file and double checks this URL
65-
66-
- `module_add_RLumTeam()` was never working and activated; now ok.
67-
68-
## Changes in version 0.1.0 (2019-05-03)
69-
70-
- Initial version
12+
- `module_add_HowToCite()`: remove argument defunct by `stringi`
13+
- `module_add_HowToCite()`: exclude `-package` file from parsing
14+
- `module_add_RLumTeam()`: exclude `-package` file from parsing

R/build_package.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
#'
1111
#' @param as_cran [logical] (with default): enable/disable `--as-cran` check
1212
#'
13-
#' @author Sebastian Kreutzer, Geography & Earth Sciences, Aberystwyth University (United Kingdom)
13+
#' @author Sebastian Kreutzer, Institute of Geography, Heidelberg University (Germany)
1414
#'
1515
#'
1616
#' @section Function version: 0.1.0

R/helpers.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
#'@description Helper functions which are used internally to visualise the console output.
44
#'Those functions are not in the overview, but are, however, documented
55
#'
6-
#'@author Sebastian Kreutzer, Geography & Earth Sciences, Aberystwyth University (United Kingdom)
6+
#'@author Sebastian Kreutzer, Institute of Geography, Heidelberg University (Germany)
77
#'
88
#'@keywords internal
99
#'@md

R/module_add_HowToCite.R

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ module_add_HowToCite <- function(){
5858
str <- stringi::stri_replace_all_coll(str, pattern = "Author: ", replacement = "")
5959
# remove all role contributions given in square brackets
6060
str <- strtrim(str, min(unlist(gregexpr("\\[|<", str))) - 2)
61-
# remove all leading whitespaces
61+
# remote whitespace
6262
str <- stringi::stri_trim(str, "left")
6363

6464
# get surname
@@ -79,10 +79,12 @@ module_add_HowToCite <- function(){
7979
## -------------------------------------------------------------------------- ##
8080
## ADD CITATION ----
8181
## -------------------------------------------------------------------------- ##
82-
8382
##add citation section
8483
file.list.man <- list.files("man/", recursive = TRUE, include.dirs = FALSE, pattern = "\\.Rd")
8584

85+
## remove package Rd, this causes some problems
86+
file.list.man <- file.list.man[grepl("-package", file.list.man, fixed = TRUE)]
87+
8688
# build package citation
8789
pkg.authors <- character()
8890
author.list.authorsOnly <- author.list[which(author.list$author),]
@@ -115,9 +117,9 @@ module_add_HowToCite <- function(){
115117
paste(temp.file.man[title.start:c(title.end - 1)], collapse = " ")
116118
title <- stringi::stri_replace_all_regex(title, "\\\\title|\\{|\\}", "")
117119
title <-
118-
stringi::stri_replace_all_regex(title, "\\\\code", "", ignore.case = TRUE)
120+
stringi::stri_replace_all_regex(title, "\\\\code", "")
119121
title <-
120-
stringi::stri_replace_all_regex(title, '"', "'", ignore.case = TRUE)
122+
stringi::stri_replace_all_regex(title, '"', "'")
121123

122124
##search for start and end author field
123125
author.start <- which(grepl("\\\\author", temp.file.man))

0 commit comments

Comments
 (0)