Home
last modified time | relevance | path

Searched refs:new (Results 1 – 9 of 9) sorted by relevance

/NovaShell/src/shell/
H A Dmod.rs39 pub fn new() -> Shell { in new() method
45 history_commands: Vec::new(), in new()
47 printer: Printer::new(&Rc::new(RefCell::new(Vec::new()))), in new()
55 ThreadManager::new(|| { in create_backend_thread()
99 .unwrap_or(&Rc::new(RefCell::new(Vec::new()))) in exec()
104 .push(Rc::new(RefCell::new(command_bytes.clone()))); in exec()
119 let mut foreground_pipelines = Vec::new(); in exec_commands_in_line()
120 let mut backend_pipelines = Vec::new(); in exec_commands_in_line()
150 let mut history = Vec::new(); in read_commands()
151 for line in BufReader::new(match File::open(&self.history_path) { in read_commands()
[all …]
H A Dprinter.rs24 pub fn new(bytes: &Rc<RefCell<Vec<u8>>>) -> Self { in new() method
38 self.buf = Rc::new(RefCell::new(Vec::new())); in init_before_readline()
H A Dthread_manager.rs13 pub fn new<F>(f: impl FnOnce() -> (Sender<S>, Receiver<R>, F)) -> ThreadManager<S, R> in new() method
/NovaShell/src/
H A Dparser.rs45 pub fn new( in new() method
119 std::env::var(str).unwrap_or(String::new()) in parse_env()
123 let mut tokens = Vec::new(); in lexer()
126 let env_token = Regex::new(r#"\$\{(\w[\w\d_]*)\}"#).unwrap(); in lexer()
130 Regex::new(r#"([^'";|&$\s]+)|(["'].*?["'])|(&&|\|\||<<|>>|[<>|&;])"#).unwrap(); in lexer()
175 let mut commands = Vec::new(); in parser()
176 let mut current_command: Vec<String> = Vec::new(); in parser()
177 let mut pipelines = Vec::new(); in parser()
226 commands.push(Command::new(name, args, cmd_type, conn_type)); in parser()
230 pipelines.push(Pipeline::new(&commands, true)); in parser()
[all …]
H A Denv.rs30 if !Path::new(Self::ENV_FILE_PATH).exists() { in read_env()
35 let mut buf: Vec<u8> = Vec::new(); in read_env()
H A Dmain.rs21 let mut shell = Shell::new(); in main()
/NovaShell/src/shell/command/
H A Dhelp.rs26 HELP_MAP = Some(Mutex::new(HelpMap::new())); in init()
H A Dmod.rs43 BUILD_IN_CMD = Some(Arc::new(Mutex::new(CommandMap::new()))); in init()
111 match std::process::Command::new(real_path) in shell_cmd_exec()
186 let mut buf: Vec<u8> = Vec::new(); in shell_cmd_free()
/NovaShell/
H A DLICENSE26 in new free programs; and that you know you can do these things.
237 9. The Free Software Foundation may publish revised and/or new versions
238 of the General Public License from time to time. Such new versions will
240 address new problems or concerns.
284 If you develop a new program, and you want it to be of the greatest