From 14b0f24fc76004d1498fa7f85a6c2377b2fbd722 Mon Sep 17 00:00:00 2001 From: Saikari Date: Tue, 27 Jan 2026 00:44:11 +0300 Subject: add support for PowerShell in shell detection --- xmake/core/base/tty.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/xmake/core/base/tty.lua b/xmake/core/base/tty.lua index 39c4c0d31..51c301ab4 100644 --- a/xmake/core/base/tty.lua +++ b/xmake/core/base/tty.lua @@ -314,7 +314,7 @@ function tty.shell() if shell_name then shell_name = shell_name:gsub("^-", "") - for _, name in ipairs({"zsh", "bash", "fish", "nu", "elvish", "sh"}) do + for _, name in ipairs({"zsh", "bash", "fish", "nu", "elvish", "pwsh", "sh"}) do if shell_name == name then shell = name break @@ -335,7 +335,7 @@ function tty.shell() if not shell then shell = os.getenv("SHELL") if shell then - for _, shellname in ipairs({"zsh", "bash", "fish", "nu", "elvish", "sh"}) do + for _, shellname in ipairs({"zsh", "bash", "fish", "nu", "elvish", "pwsh", "sh"}) do if shell:find(shellname) then shell = shellname break -- cgit v1.3.1