From 15a43a6b119ea8d51e972ad430b233b6454637f3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=8E=E9=80=9A=E6=B4=B2?= Date: Sat, 27 May 2023 21:25:32 +0800 Subject: [PATCH] TerminalShel (Windows): detect Tabby version with exe file version --- src/detection/terminalshell/terminalshell.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/src/detection/terminalshell/terminalshell.c b/src/detection/terminalshell/terminalshell.c index b0a98ac4a..940002dda 100644 --- a/src/detection/terminalshell/terminalshell.c +++ b/src/detection/terminalshell/terminalshell.c @@ -279,6 +279,13 @@ bool fftsGetTerminalVersion(FFstrbuf* processName, FF_MAYBE_UNUSED FFstrbuf* exe if(ffStrbufIgnCaseEqualS(processName, "kitty")) return getExeVersionGeneral(exe, version); //kitty 0.21.2 created by Kovid Goyal + if (ffStrbufIgnCaseEqualS(processName, "Tabby") && !ffProcessAppendStdOut(version, (char* const[]){ + exe->chars, + "--version", + NULL + })) + return true; + #endif if(ffStrbufStartsWithIgnCaseS(processName, "alacritty")) @@ -300,13 +307,6 @@ bool fftsGetTerminalVersion(FFstrbuf* processName, FF_MAYBE_UNUSED FFstrbuf* exe } } - if (ffStrbufIgnCaseEqualS(processName, "Tabby") && !ffProcessAppendStdOut(version, (char* const[]){ - exe->chars, - "--version", - NULL - })) - return true; - #ifdef _WIN32 return getFileVersion(exe->chars, version);