add support for additional zip file extensions#244
add support for additional zip file extensions#244letuanhai wants to merge 1 commit intophiresky:masterfrom
Conversation
This commit allows the user to specify additional zip extensions in the config file. This is implemented by adding a new optional field to the config file, additional_extensions_zip, which is a list of strings. If this field is present, the program will use the specified extensions in addition to the default ones. Internally, the AdapterMeta struct that store file extension matchers is moved into the ZipAdapter struct, and the constructor for ZipAdapter is modified to take the additional extensions as a parameter. The AdapterMeta struct is then constructed with the default extensions and the additional extensions, if any.
|
@letuanhai Hello! I had been working in parallel on #247. I believe our two PRs have very similar goals. If you ever have the time, I would very much appreciate any feedback on #247 including whether you think the more generic approach it proposes would even be useful compared to the approach you took in this PR. I'm new to Rust, and open to any suggestions now matter how big or small. Thanks in advance! |
Hi. I took a look at your PR (#247) and really like the more generic approach you went with. I’m also pretty new to Rust, so I don’t have any extra feedback, but your solution seems great to me. I’m closing mine in favor of yours. Thanks for the great work! |
This commit allows the user to specify additional zip extensions in the config file. This is implemented by adding a new optional field to the config file,
additional_extensions_zip, which is a list of strings. If this field is present, the program will use the specified extensions in addition to the default ones.Internally, the
AdapterMetastruct that store file extension matchers is moved into theZipAdapterstruct, and the constructor forZipAdapteris modified to take the additional extensions as a parameter. TheAdapterMetastruct is then constructed with the default extensions and the additional extensions, if any.