mirror of
https://github.com/fastfetch-cli/fastfetch.git
synced 2026-09-13 02:42:09 +02:00
Binary: support Windows
This commit is contained in:
@@ -57,15 +57,15 @@ const char* ffDetectEditor(FFEditorResult* result)
|
||||
else
|
||||
{
|
||||
const char* error = ffFindExecutableInPath(result->name.chars, &result->path);
|
||||
if (error) return error;
|
||||
if (error) return NULL;
|
||||
}
|
||||
|
||||
if (!instance.config.general.detectVersion) return NULL;
|
||||
|
||||
char buf[PATH_MAX + 1];
|
||||
if (!realpath(result->path.chars, buf))
|
||||
return NULL;
|
||||
|
||||
// WIN32: Should we handle scoop shim exe here?
|
||||
|
||||
ffStrbufSetS(&result->path, buf);
|
||||
|
||||
{
|
||||
@@ -88,6 +88,8 @@ const char* ffDetectEditor(FFEditorResult* result)
|
||||
#endif
|
||||
}
|
||||
|
||||
if (!instance.config.general.detectVersion) return NULL;
|
||||
|
||||
if (ffStrbufEqualS(&result->exe, "nvim"))
|
||||
ffBinaryExtractStrings(buf, extractNvimVersion, &result->version);
|
||||
else if (ffStrbufEqualS(&result->exe, "vim"))
|
||||
|
||||
Reference in New Issue
Block a user