To facilitate filtering files vs directories, exposing glob options is essential. The underlying glob library has an option called onlyFiles but this is not available via this plug-in. It is not possible to distinguish files and directories using glob patterns alone.
Feature Use Case
glob('*') should be able to match only files, without manually excluding every directory by name. Sometimes it is possible to distinguish files from directories if we can assume files always contain a dot (.) and directories never do (glob('*.*')), but this is not always the case and never guaranteed.
Feature Proposal
To facilitate filtering files vs directories, exposing glob options is essential. The underlying glob library has an option called
onlyFiles
but this is not available via this plug-in. It is not possible to distinguish files and directories using glob patterns alone.Feature Use Case
glob('*')
should be able to match only files, without manually excluding every directory by name. Sometimes it is possible to distinguish files from directories if we can assume files always contain a dot (.
) and directories never do (glob('*.*')
), but this is not always the case and never guaranteed.