tidyverse: Helpers for tidyverse development

Description Usage Arguments Details use_tidy_style()

Description

These helpers follow tidyverse conventions which are generally a little stricter than the defaults, reflecting the need for greater rigor in commonly used packages.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21

Arguments

path

A path. If it exists, it is used. If it does not exist, it is created, provided that the parent path exists.

copyright_holder

Name of the copyright holder or holders. This defaults to "package name authors"; you should only change this if you use a CLA to assign copyright to a single entity.

strict

Boolean indicating whether or not a strict version of styling should be applied. See styler::tidyverse_style() for details.

Details

use_tidy_style()

Uses the styler package package to style all code in a package, project, or directory, according to the tidyverse style guide.

Warning: This function will overwrite files! It is strongly suggested to only style files that are under version control or to first create a backup copy.

Invisibly returns a data frame with one row per file, that indicates whether styling caused a change.


usethis documentation built on Feb. 10, 2021, 5:08 p.m.