Style a file

style_file(file, configuration = list())

Arguments

file

(character) the file to format

configuration

(list) Configuration for formatting. Default list().

Value

No return value, called for side effects.

Details

To see possible configuration options, see get_default_config().

Examples

tmp <- tempfile()
file_conn <- file(tmp)
writeLines(c("function(){}", "A<-7"), file_conn)
close(file_conn)
style_file(file = tmp, configuration = list())
unlink(tmp)