Try zsh, bash then sh (#1000)

This commit is contained in:
Solomon
2025-10-13 09:51:34 +01:00
committed by GitHub
parent 63a935a63f
commit 735bbcfeff

View File

@@ -9,8 +9,10 @@ pub fn get_shell_command() -> (&'static str, &'static str) {
if cfg!(windows) {
("cmd", "/C")
} else {
// Prefer bash if available, fallback to sh
if std::path::Path::new("/bin/bash").exists() {
// Prefer zsh or bash if available, fallback to sh
if std::path::Path::new("/bin/zsh").exists() {
("zsh", "-c")
} else if std::path::Path::new("/bin/bash").exists() {
("bash", "-c")
} else {
("sh", "-c")