get_version {newsmd} | R Documentation |
Retrieve the version number of a NEWS.md file
Description
This function tries to extract the version number within a file. There are a few pitfalls:
* If the word "version" is within the text but denotes a dependency it is still detected. * If the files has a date before the version it will return the date instead of the version * It is assumed, that the NEWS.md files is updated from the top. Ergo the latest version is the first one.
Usage
get_version(file, latest = TRUE)
Arguments
file |
a path to a file |
latest |
a Boolean, if TRUE (default) only the latest version is returned |
Value
either a single string or a vector with version numbers
[Package newsmd version 0.5.1 Index]