From 9a2141ca3d78342a121823c75b87d7b01a67360e Mon Sep 17 00:00:00 2001 From: AmjadHD Date: Tue, 22 Apr 2025 01:22:30 +0100 Subject: [PATCH] Fix expand ARC/macro The default value for the `nimsuggestPath` setting is `"nimsuggest"` `getNimPath` returns an invalid path. --- ls.nim | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ls.nim b/ls.nim index ba2ad47..946b72d 100644 --- a/ls.nim +++ b/ls.nim @@ -508,7 +508,7 @@ proc getNimSuggestPathAndVersion( (nimsuggestPath, nimVersion) proc getNimPath*(conf: NlsConfig): Option[string] = - if conf.nimSuggestPath.isSome: + if conf.nimSuggestPath.isSome and conf.nimsuggestPath.get().fileExists(): some(conf.nimSuggestPath.get.parentDir / "nim") else: let path = findExe "nim"