Skip to content

Commit

Permalink
Merge pull request #1080 from r-lib/precommit_more_hooks
Browse files Browse the repository at this point in the history
Add more hooks to precommit config
  • Loading branch information
lorenzwalthert authored Dec 24, 2022
2 parents 3a72387 + b6bf038 commit 0314644
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 6 deletions.
9 changes: 8 additions & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ default_language_version:

repos:
- repo: https://github.com/lorenzwalthert/precommit
rev: v0.3.2.9003
rev: v0.3.2.9005
hooks:
- id: style-files
args:
Expand Down Expand Up @@ -97,11 +97,14 @@ repos:
tests/testthat/rnw/011-conditional-eval-out\.Rnw|
tests/testthat/.*\.R(md)?
)$
- id: pkgdown
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.3.0
hooks:
- id: check-added-large-files
args: ["--maxkb=200"]
- id: check-yaml
- id: mixed-line-ending
- id: file-contents-sorter
files: "\\.Rbuildignore$"
- id: end-of-file-fixer
Expand All @@ -125,3 +128,7 @@ repos:
language: fail
files: '\.Rhistory|\.RData|\.Rds|\.rds$'
# `exclude: <regex>` to allow committing specific files.

ci:
skip: [pkgdown]
autoupdate_schedule: monthly
10 changes: 5 additions & 5 deletions R/testing.R
Original file line number Diff line number Diff line change
Expand Up @@ -161,13 +161,13 @@ style_empty <- function(text, base_indention = 0L) {
transformers <- list(
# transformer functions
initialize = default_style_guide_attributes,
line_break = NULL,
space = NULL,
token = NULL,
line_break = NULL,
space = NULL,
token = NULL,
# transformer options
use_raw_indention = FALSE,
reindention = specify_reindention(),
indent_character = " ",
reindention = specify_reindention(),
indent_character = " ",
NULL
)
transformed_text <- parse_transform_serialize_r(text,
Expand Down

0 comments on commit 0314644

Please sign in to comment.