Open 39555 opened 1 month ago
It's because a subshell is not a new process?
Yes, that's the main reason. It's been a source of friction along the way, but in practice, actual interactions with the filesystem have been relatively limited to I/O redirection, the source
builtin, cd
/pushd
/popd
, and a few other places.
If you look for everywhere the shell
object can get cloned--and there's more places than would be ideal--you'll see where we leverage this.
I've started working on correctly handling symlinked paths and have some questions about
cwd
implementation details.Shell.working_dir
instead of the system'sstd::env::set_current_dir/get_current_dir
? It's because a subshell is not a new process?