Skip to content

Commit dbb867e

Browse files
authored
Merge branch 'main' into f-558-prof
2 parents 38dca86 + bbc4eef commit dbb867e

22 files changed

+826
-120
lines changed

.github/workflows/check-full.yaml

+9-7
Original file line numberDiff line numberDiff line change
@@ -27,12 +27,12 @@ jobs:
2727
- {os: windows-latest, r: '3.6'}
2828

2929
# Use older ubuntu to maximise backward compatibility
30-
- {os: ubuntu-18.04, r: 'devel', http-user-agent: 'release'}
31-
- {os: ubuntu-18.04, r: 'release'}
32-
- {os: ubuntu-18.04, r: 'oldrel-1'}
33-
- {os: ubuntu-18.04, r: 'oldrel-2'}
34-
- {os: ubuntu-18.04, r: 'oldrel-3'}
35-
- {os: ubuntu-18.04, r: 'oldrel-4'}
30+
- {os: ubuntu-latest, r: 'devel', http-user-agent: 'release'}
31+
- {os: ubuntu-latest, r: 'release'}
32+
- {os: ubuntu-latest, r: 'oldrel-1'}
33+
- {os: ubuntu-latest, r: 'oldrel-2'}
34+
- {os: ubuntu-latest, r: 'oldrel-3'}
35+
- {os: ubuntu-latest, r: 'oldrel-4'}
3636

3737
env:
3838
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}
@@ -51,10 +51,12 @@ jobs:
5151

5252
- uses: r-lib/actions/setup-r-dependencies@v2
5353
with:
54-
extra-packages: any::rcmdcheck, data.tree=?ignore-before-r=3.5.0
54+
extra-packages: any::rcmdcheck
5555
needs: check
5656

5757
- uses: r-lib/actions/check-r-package@v2
58+
with:
59+
error-on: '"note"'
5860
env:
5961
_R_CHECK_FORCE_SUGGESTS_: false
6062

.github/workflows/pre-commit.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ on:
99

1010
jobs:
1111
pre-commit:
12-
runs-on: ubuntu-18.04
12+
runs-on: ubuntu-latest
1313
if: >-
1414
!contains(github.event.head_commit.message, 'ci skip') &&
1515
(

DESCRIPTION

+8-2
Original file line numberDiff line numberDiff line change
@@ -11,14 +11,19 @@ Authors@R:
1111
person(given = "Lorenz",
1212
family = "Walthert",
1313
role = c("cre", "aut"),
14-
email = "[email protected]"))
14+
email = "[email protected]"),
15+
person(given = "Indrajeet",
16+
family = "Patil",
17+
role = "ctb",
18+
email = "[email protected]",
19+
comment = c(ORCID = "0000-0003-1995-6531", Twitter = "@patilindrajeets")))
1520
Description: Pretty-prints R code without changing the user's formatting
1621
intent.
1722
License: MIT + file LICENSE
1823
URL: https://github.com/r-lib/styler, https://styler.r-lib.org
1924
BugReports: https://github.com/r-lib/styler/issues
2025
Depends:
21-
R (>= 3.4.0)
26+
R (>= 3.5.0)
2227
Imports:
2328
cli (>= 3.1.1),
2429
magrittr (>= 2.0.0),
@@ -48,6 +53,7 @@ Roxygen: list(markdown = TRUE, roclets = c("rd", "namespace", "collate",
4853
"pkgapi::api_roclet"))
4954
RoxygenNote: 7.2.1
5055
Config/testthat/edition: 3
56+
Config/testthat/parallel: true
5157
Collate:
5258
'addins.R'
5359
'communicate.R'

NEWS.md

+7-2
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,8 @@ editor_options:
1111
- `style_dir()` and `style_pkg()` now default to styling all supported file
1212
formats (`.R`, `.Rmd`, `.Rmarkdown`, `.Rnw`, and `.qmd`) in the (package)
1313
directory (\@IndrajeetPatil, #965).
14-
- `style_pkg()` now excludes the auto-generated `R/cpp11.R` file (#977).
14+
- `style_pkg()` now excludes the auto-generated `R/cpp11.R` file (#977).
15+
- Minimum needed R version is now bumped to `3.5` (\@IndrajeetPatil, #986).
1516

1617
**Features**
1718

@@ -49,6 +50,10 @@ editor_options:
4950

5051
**Other**
5152

53+
- \@IndrajeetPatil is now a contributor to {styler}. Welcome and thanks for
54+
everything you did so far! (#988).
55+
- Non-exported and unused functions `odd()` and `even()` were removed
56+
(\@IndrajeetPatil, #989).
5257
- Old (and outdated) vignettes have been removed (\@IndrajeetPatil, #955). To
5358
access them, do `git checkout v1.0.0`.
5459
- Upgrade testing infra to testthat 3e (\@IndrajeetPatil, #949).
@@ -628,7 +633,7 @@ Thanks to all contributors involved, in particular
628633
## Adaption
629634

630635
- styler is now available through the pre-commit hook `style-files` in
631-
<https://github.com/lorenzwalthert/pre-commit-hooks>.
636+
<https://github.com/lorenzwalthert/precommit>.
632637

633638
Thanks to all contributors involved, in particular
634639

R/expr-is.R

+1-1
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ is_subset_expr <- function(pd) {
103103
#' Identify comments that are shebangs
104104
#'
105105
#' Shebangs should be preserved and no space should be inserted between
106-
#' \# and !. A comment is a shebang if it is the first top level token
106+
#' `#` and `!`. A comment is a shebang if it is the first top level token
107107
#' (identified with `pos_id`) and if it starts with `#!`.
108108
#' @param pd A parse table.
109109
#' @examples

R/utils.R

-11
Original file line numberDiff line numberDiff line change
@@ -48,24 +48,13 @@ two_cols_match <- function(col1, col2, data) {
4848
all(unlist(data[col1]) == unlist(data[col2]))
4949
}
5050

51-
odd <- function(x) {
52-
x[odd_index(x)]
53-
}
54-
5551
odd_index <- function(x) {
5652
if (length(x) < 1) {
5753
return(NULL)
5854
}
5955
seq(1L, length(x), by = 2)
6056
}
6157

62-
even <- function(x) {
63-
if (length(x) < 2) {
64-
return(NULL)
65-
}
66-
x[even_index(x)]
67-
}
68-
6958
even_index <- function(x) {
7059
seq(2L, length(x), by = 2)
7160
}

cran-comments.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ Luke Tierney.
1010

1111
## Test environments
1212

13-
- ubuntu 18.04 (on GitHub Actions): R devel, R 4.1.2, R 4.0.5, R 3.6, R 3.5,
13+
- ubuntu 20.04 (on GitHub Actions): R devel, R 4.1.2, R 4.0.5, R 3.6, R 3.5,
1414
R 3.4
1515
- Windows Server 10 (on GitHub Actions): R 3.6, R 4.0.5
1616
- win-builder: R devel

inst/WORDLIST

+6
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ covr
3131
cpp
3232
cran
3333
cre
34+
ctb
3435
cynkra
3536
datastructures
3637
dec
@@ -75,6 +76,7 @@ ggplot
7576
ghclass
7677
github
7778
gitsum
79+
gmail
7880
grkstyle
7981
GSOC
8082
hashFiles
@@ -85,6 +87,7 @@ https
8587
icloud
8688
ifelse
8789
impl
90+
Indrajeet
8891
infinitively
8992
initializer
9093
inode
@@ -141,6 +144,9 @@ params
141144
paren
142145
parsable
143146
parsesum
147+
Patil
148+
patilindrajeet
149+
patilindrajeets
144150
pgkdown
145151
pkgapi
146152
pkgdown

man/is_shebang.Rd

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

man/styler-package.Rd

+5
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)