file_present: Checking Standardized File Names
Created by: williamschmitt21
The current version of the file_present
function requires knowing the entire file name if one wishes to check if a previous version of a file (i.e. named with the standardized file format, TXX-Description-MM_DD_YYYY-vX.X.X.ext
) exists in the current working directory.
One could, in theory, do a partial match, but this breaks down if files with the same description, but different extensions, exist in the working directory.
The file_present
function has been updated to include a new argument: std_name
that, if true, matches the tag and description of the string
argument to files in the working directory. This should offer a more robust approach for determining whether an (old version of a) file exists in the working directory.
Next steps:
- Update calls to
file_present
throughout the package to take advantage of this feature (as there are several other functions where this computation is performed).