Learn R Programming

document (version 3.3.4)

clean_description_file: Make a Default DESCRIPTION File Pass R CMD check

Description

utils::package.skeleton leaves us with a DESCRIPTION that throws a warning in R CMD check. Fix that.

Usage

clean_description_file(path)

Value

Invisibly NULL.

Arguments

path

Path to the DESCRIPTION file or the directory containing it.

Examples

Run this code
if (! exists("dummy")) assign("dummy", "dumb")
utils::package.skeleton(path = tempdir())
old <- readLines(file.path(tempdir(), "anRpackage", "DESCRIPTION"))
document:::clean_description_file(path = file.path(tempdir(), "anRpackage",
                                        "DESCRIPTION"))
new <- readLines(file.path(tempdir(), "anRpackage", "DESCRIPTION"))
setdiff(new, old)

Run the code above in your browser using DataLab