fn collect_files_in_dir(path: impl AsRef<Path>) -> Result<Vec<PathBuf>, Error>
Expand description
Collects all regular files in a directory in the order of an OpenPGP Transferable Public Key.
All top-level regular files in the directory are considered first. Afterwards, all regular files located in the following list of directories (if they exist) are considered, in the following order:
revocation
: for Revocation Signature packetsdirectkey
: for Direct Key Signature packetsuid
: for User ID or User Attribute packetssubkey
: for Subkey packets
ยงErrors
Returns an error if
- entries in
path
cannot be retrieved, - reading an entry in
path
fails, - or recursively collecting regular files in any of the subdirectories (
revocation
,directkey
,uid
orsubkey
) fails.