#![allow(dead_code)]
#![allow(unused_variables)]
#![allow(unused_imports)]
#![allow(unused_assignments)]
#![allow(unused_mut)]
#![allow(unused_parens)]
#![allow(unused_doc_comments)]
#![allow(unreachable_patterns)]
#![allow(deprecated)]
#![allow(unexpected_cfgs)]
#![allow(non_snake_case)]
#![allow(non_camel_case_types)]
#![allow(non_upper_case_globals)]
#![allow(function_casts_as_integer)]
#![allow(clippy::all)]
pub mod exec_jobs;
pub mod extensions;
pub mod ported;
pub use ported::*;
#[path = "extensions/aot.rs"] pub mod aot;
#[path = "extensions/arith_compiler.rs"] pub mod arith_compiler;
#[path = "extensions/autoload_cache.rs"] pub mod autoload_cache;
#[path = "extensions/script_cache.rs"] pub mod script_cache;
#[path = "extensions/compile_zsh.rs"] pub mod compile_zsh;
#[path = "extensions/completion.rs"] pub mod completion;
#[path = "extensions/bash_complete.rs"] pub mod bash_complete;
#[path = "extensions/config.rs"] pub mod config;
#[path = "extensions/canonical_apply.rs"] pub mod canonical_apply;
#[path = "extensions/overlay_snapshot.rs"] pub mod overlay_snapshot;
#[path = "extensions/daemon_presence.rs"] pub mod daemon_presence;
#[cfg(feature = "daemon")]
pub use zshrs_daemon as daemon;
#[cfg(not(feature = "daemon"))]
pub mod daemon {
pub mod builtins {
pub const ZSHRS_BUILTIN_NAMES: &[&str] = &[];
pub fn is_zshrs_builtin(_name: &str) -> bool {
false
}
pub fn try_dispatch(_name: &str, _argv: &[String]) -> Option<i32> {
None
}
pub fn dispatch(_name: &str, _args: &[String]) -> Option<i32> {
None
}
}
}
#[path = "extensions/ext_builtins.rs"] pub mod ext_builtins;
#[path = "extensions/func_body_fmt.rs"] pub mod func_body_fmt;
#[path = "extensions/fds.rs"] pub mod fds;
#[path = "extensions/fish_features.rs"] pub mod fish_features;
#[path = "extensions/ast_sexp.rs"] pub mod ast_sexp;
#[path = "extensions/dumpers.rs"] pub mod dumpers;
pub use ported::lex;
pub use ported::lex as tokens;
pub use ported::parse;
#[path = "extensions/history.rs"] pub mod history;
#[path = "extensions/heredoc_ast.rs"] pub mod heredoc_ast;
#[path = "extensions/zsh_ast.rs"] pub mod zsh_ast;
#[path = "extensions/log.rs"] pub mod log;
pub use modules::attr;
pub use modules::cap;
pub use modules::clone;
pub use modules::curses;
pub use modules::datetime;
pub use modules::db_gdbm;
pub use modules::example;
pub use modules::files;
pub use modules::hlgroup;
pub use modules::ksh93;
pub use modules::langinfo;
pub use modules::mapfile;
pub use modules::mathfunc;
pub use modules::nearcolor;
pub use modules::newuser;
pub use modules::param_private;
pub use modules::parameter;
pub use modules::pcre;
pub use modules::random;
pub use modules::random_real;
pub use modules::regex as regex_module;
pub use builtins::sched;
pub use modules::socket;
pub use modules::stat;
pub use modules::system;
pub use modules::tcp;
pub use modules::termcap;
pub use modules::terminfo;
pub use modules::watch;
pub use modules::zftp;
pub use modules::zprof;
pub use modules::zpty;
pub use modules::zselect;
pub use modules::zutil;
#[path = "extensions/plugin_cache.rs"] pub mod plugin_cache;
#[path = "extensions/recorder.rs"] pub mod recorder_ext;
#[path = "extensions/intercepts.rs"] pub mod intercepts;
#[path = "extensions/compinit_bg.rs"] pub mod compinit_bg;
pub mod fusevm_bridge;
#[cfg(feature = "recorder")]
pub mod recorder;
#[path = "extensions/regex_mod.rs"] pub mod regex_mod;
#[path = "extensions/stringsort.rs"] pub mod stringsort;
#[path = "extensions/worker.rs"] pub mod worker;
#[path = "extensions/zwc.rs"] pub mod zwc;
#[path = "extensions/zwc_decode.rs"] pub mod zwc_decode;
pub use builtins::rlimits;
pub mod exec;
pub use exec::ShellExecutor;
pub use fish_features::{
autosuggest_from_history,
colorize_line,
expand_abbreviation,
highlight_shell,
is_private_mode,
kill_add,
kill_replace,
kill_yank,
kill_yank_rotate,
set_private_mode,
validate_autosuggestion,
validate_command,
with_abbrs,
with_abbrs_mut,
AbbrPosition,
Abbreviation,
AbbreviationSet,
Autosuggestion,
HighlightRole,
HighlightSpec,
KillRing,
ValidationStatus,
};
pub use tokens::lextok;
use std::sync::OnceLock;
type StrykeHandler = Box<dyn Fn(&str) -> i32 + Send + Sync>;
static STRYKE_HANDLER: OnceLock<StrykeHandler> = OnceLock::new();
pub fn set_stryke_handler<F>(f: F)
where
F: Fn(&str) -> i32 + Send + Sync + 'static,
{
let _ = STRYKE_HANDLER.set(Box::new(f));
}
pub fn try_stryke_dispatch(code: &str) -> Option<i32> {
STRYKE_HANDLER.get().map(|f| f(code))
}