Determine whether an R file exists regardless of case of extension.
extensionless_exists(filename)
filename | character. The filename to test (possibly without extension). |
---|
TRUE
or FALSE
if the filename exists regardless of
R extension.
not_run({ # Assume we have a file \code{"foo.R"}. The following all return \code{TRUE}. extensionless_exists('foo.R') extensionless_exists('foo.r') extensionless_exists('foo') })