From 04c7ba5ca01485e0ce87ebe2a480064ca265bb40 Mon Sep 17 00:00:00 2001 From: Nahor Date: Thu, 28 May 2026 09:40:09 -0700 Subject: [PATCH] Cygwin: include other MSYS2 environments than just MSYS --- share/functions/__fish_is_cygwin.fish | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/share/functions/__fish_is_cygwin.fish b/share/functions/__fish_is_cygwin.fish index a81f24824..f1c9e1b56 100644 --- a/share/functions/__fish_is_cygwin.fish +++ b/share/functions/__fish_is_cygwin.fish @@ -1,4 +1,6 @@ # localization: skip(private) function __fish_is_cygwin - __fish_uname | string match -qr "^(MSYS|CYGWIN)" + # Based on https://github.com/msys2/msys2-runtime/blob/01d6c708f9221334d18ab332621b6d87eb12d37e/winsup/cygwin/uname.cc#L28 + # and https://cygwin.com/git/?p=newlib-cygwin.git;a=blob;f=winsup/cygwin/uname.cc;h=c08e30f97da9e6e30ec011dfdc40f37d14fb6465;hb=daabea98682f3f4bef0044829a8d24226135bb71#l40 + __fish_uname | string match -qr "^(MSYS|MINGW64|MINGW32|CYGWIN)" end