mirror of
https://github.com/nushell/nushell.git
synced 2025-08-09 08:36:10 +02:00
Refactor the CLI code a bit (#12782)
# Description Refactors the code in `nu-cli`, `main.rs`, `run.rs`, and few others. Namely, I added `EngineState::generate_nu_constant` function to eliminate some duplicate code. Otherwise, I changed a bunch of areas to return errors instead of calling `std::process::exit`. # User-Facing Changes Should be none.
This commit is contained in:
@ -41,7 +41,6 @@ pub fn report_error_new(
|
||||
error: &(dyn miette::Diagnostic + Send + Sync + 'static),
|
||||
) {
|
||||
let working_set = StateWorkingSet::new(engine_state);
|
||||
|
||||
report_error(&working_set, error);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user