From 554ccac70da4fcc9735eeb6863dc95d5c867657c Mon Sep 17 00:00:00 2001 From: Hugo Gruson <10783929+Bisaloo@users.noreply.github.com> Date: Mon, 6 May 2024 16:07:52 +0200 Subject: [PATCH 1/2] Re-order Rbuildignore --- .Rbuildignore | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/.Rbuildignore b/.Rbuildignore index d797cd8..22cfd42 100644 --- a/.Rbuildignore +++ b/.Rbuildignore @@ -1,14 +1,14 @@ +^.*\.Rproj$ +^CITATION\.cff$ ^LICENSE\.md$ -^\.github$ +^Meta$ ^README\.Rmd$ -^codecov\.yml$ +^\.Rproj\.user$ +^\.github$ +^\.lintr$ ^_pkgdown\.yml$ +^codecov\.yml$ +^doc$ ^docs$ ^pkgdown$ -^\.lintr$ -^.*\.Rproj$ -^\.Rproj\.user$ -^CITATION\.cff$ ^tools$ -^doc$ -^Meta$ From 067b8beaea241ef274436639e8e7279c1caee860 Mon Sep 17 00:00:00 2001 From: Hugo Gruson <10783929+Bisaloo@users.noreply.github.com> Date: Mon, 6 May 2024 16:08:03 +0200 Subject: [PATCH 2/2] Add minimal Rbuildignore --- .Rbuildignore | 1 + .pre-commit-config.yaml | 24 ++++++++++++++++++++++++ 2 files changed, 25 insertions(+) create mode 100644 .pre-commit-config.yaml diff --git a/.Rbuildignore b/.Rbuildignore index 22cfd42..bfe7068 100644 --- a/.Rbuildignore +++ b/.Rbuildignore @@ -6,6 +6,7 @@ ^\.Rproj\.user$ ^\.github$ ^\.lintr$ +^\.pre-commit-config\.yaml$ ^_pkgdown\.yml$ ^codecov\.yml$ ^doc$ diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml new file mode 100644 index 0000000..0da7464 --- /dev/null +++ b/.pre-commit-config.yaml @@ -0,0 +1,24 @@ +# All available hooks: https://pre-commit.com/hooks.html +# R specific hooks: https://github.com/lorenzwalthert/precommit +repos: +- repo: https://github.com/lorenzwalthert/precommit + rev: v0.4.2 + hooks: + - id: style-files + args: [--style_pkg=styler, --style_fun=tidyverse_style] + - id: roxygenize + - id: use-tidy-description + - id: parsable-R + - id: no-browser-statement + - id: no-debug-statement + - id: deps-in-desc + - id: pkgdown +- repo: https://github.com/pre-commit/pre-commit-hooks + rev: v4.6.0 + hooks: + - id: check-added-large-files + args: ['--maxkb=700'] + - id: file-contents-sorter + files: '^\.Rbuildignore$' + - id: end-of-file-fixer + exclude: '\.Rd'