feat: add infer and tree_magic_mini meta plugins, make zstd internal by default
- Add infer crate as meta plugin for MIME type detection - Add tree_magic_mini crate as alternative meta plugin for MIME type detection - Add zstd, infer, tree_magic_mini to default features - Fix static build script to use musl target instead of glibc+crt-static - Remove hardcoded shell list from --generate-completion help text - Fix update() in both new plugins to emit MIME metadata when buffer fills
This commit is contained in:
@@ -9,6 +9,8 @@ pub mod digest;
|
||||
pub mod env;
|
||||
pub mod exec;
|
||||
pub mod hostname;
|
||||
#[cfg(feature = "infer")]
|
||||
pub mod infer_plugin;
|
||||
pub mod keep_pid;
|
||||
pub mod magic_file;
|
||||
pub mod read_rate;
|
||||
@@ -18,6 +20,8 @@ pub mod shell_pid;
|
||||
pub mod text;
|
||||
#[cfg(feature = "tokens")]
|
||||
pub mod tokens;
|
||||
#[cfg(feature = "tree_magic_mini")]
|
||||
pub mod tree_magic_mini;
|
||||
pub mod user;
|
||||
|
||||
pub use digest::DigestMetaPlugin;
|
||||
@@ -28,11 +32,15 @@ pub use magic_file::MagicFileMetaPlugin;
|
||||
pub use cwd::CwdMetaPlugin;
|
||||
pub use env::EnvMetaPlugin;
|
||||
pub use hostname::HostnameMetaPlugin;
|
||||
#[cfg(feature = "infer")]
|
||||
pub use infer_plugin::InferMetaPlugin;
|
||||
pub use keep_pid::KeepPidMetaPlugin;
|
||||
pub use read_rate::ReadRateMetaPlugin;
|
||||
pub use read_time::ReadTimeMetaPlugin;
|
||||
pub use shell::ShellMetaPlugin;
|
||||
pub use shell_pid::ShellPidMetaPlugin;
|
||||
#[cfg(feature = "tree_magic_mini")]
|
||||
pub use tree_magic_mini::TreeMagicMiniMetaPlugin;
|
||||
pub use user::UserMetaPlugin;
|
||||
|
||||
#[cfg(not(feature = "magic"))]
|
||||
@@ -263,6 +271,8 @@ pub enum MetaPluginType {
|
||||
Exec,
|
||||
Env,
|
||||
Tokens,
|
||||
TreeMagicMini,
|
||||
Infer,
|
||||
}
|
||||
|
||||
/// Central function to handle metadata output with name mapping.
|
||||
|
||||
Reference in New Issue
Block a user