description-functions | R Documentation |
Read, write and update the DESCRIPTION file. read.description
reads the
DESCRIPTION file in the current project directory and returns a named list.
write.description
writes the named list back to disk, overwriting the
current DESCRIPTION file. Finally, update_description
combines both functions
by reading the DESCRIPTION file, updating or creating a field and writing the result
back to disk.
read.description() write.description(description) update_description(fieldname, value, after = NULL)
description |
the DESCRIPTION file. |
fieldname |
the name of the field. |
value |
the new value. |
after |
if the field name is new, the name of the field after which the element is placed. |
The 'Depends', 'Imports' and 'Suggests' fields are sorted before writing the DESCRIPTION file.
## Not run: description = read.description() write.description(read.description()) #update date in description file update_description("Date", format(Sys.Date(), "%Y%-%m-%d")) ## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.