Cherry-pick of #42085 to stable ---- Also respect the shell env for various commands again Should close https://github.com/zed-industries/zed/issues/42027 Release Notes: - Fixed remote server installation failing on some setups Co-authored-by: Lukas Wirth <lukas@zed.dev>