use crate::ported::exec::dispatch_function_call;
pub fn _command() -> i32 {
let _fn_scope = crate::compsys::ported::shared::FnScope::enter("_command");
let mut argv: Vec<String> = Vec::new();
if !crate::extensions::emulation_startup::emulating_592() {
argv.extend(["-S".to_string(), ":".to_string()]); }
argv.extend([
"-v[indicate result of command search]:*:command:_path_commands".to_string(),
"-V[show result of command search in verbose form]:*:command:_path_commands"
.to_string(),
"(-)-p[use default PATH to find command]".to_string(),
"*:: : _normal -p $service".to_string(),
]);
dispatch_function_call("_arguments", &argv).unwrap_or(1)
}
#[cfg(test)]
mod tests {
use super::*;
#[test]
fn returns_one_without_executor() {
let _g = crate::test_util::global_state_lock();
assert_eq!(_command(), 1);
}
}