account for startup commands in the scope. (#3261)

* Revert "Impl one configurable function to run scripts (#3242)"
* pass config startup.
This commit is contained in:
Andrés N. Robalino
2021-04-04 00:14:58 -05:00
committed by GitHub
parent 4c09716ad8
commit 00acf22f5f
18 changed files with 220 additions and 306 deletions

View File

@ -1,13 +1,10 @@
use crate::prelude::*;
use nu_engine::basic_evaluation_context;
use nu_engine::whole_stream_command;
use nu_engine::{basic_evaluation_context, filesystem::filesystem_shell::FilesystemShellMode};
use std::error::Error;
pub fn create_default_context(
mode: FilesystemShellMode,
interactive: bool,
) -> Result<EvaluationContext, Box<dyn Error>> {
let context = basic_evaluation_context(mode)?;
pub fn create_default_context(interactive: bool) -> Result<EvaluationContext, Box<dyn Error>> {
let context = basic_evaluation_context()?;
{
use crate::commands::*;