Add support for bzip and xz tar files, part of #122

This commit is contained in:
Jeremy Soller 2024-09-17 12:31:54 -06:00
parent ed2aeadc79
commit d0359af0b5
No known key found for this signature in database
GPG key ID: D02FD439211AF56F
4 changed files with 68 additions and 12 deletions

View file

@ -131,9 +131,18 @@ pub fn context_menu<'a>(
children.push(divider::horizontal::light().into());
let supported_archive_types = [
"application/gzip",
"application/x-compressed-tar",
"application/x-tar",
"application/zip",
#[cfg(feature = "bzip2")]
"application/x-bzip",
#[cfg(feature = "bzip2")]
"application/x-bzip-compressed-tar",
#[cfg(feature = "liblzma")]
"application/x-xz",
#[cfg(feature = "liblzma")]
"application/x-xz-compressed-tar",
]
.iter()
.filter_map(|mime_type| mime_type.parse::<Mime>().ok())