From f8320ecd34a22d41e9b60b064dd3ab05d2887552 Mon Sep 17 00:00:00 2001 From: Nat Quayle Nelson Date: Fri, 17 Dec 2021 15:19:11 -0700 Subject: [PATCH] don't warn when editing ktxt2 file itself --- projects/kiss-vscode/config/KissConfig.kiss | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/projects/kiss-vscode/config/KissConfig.kiss b/projects/kiss-vscode/config/KissConfig.kiss index 36c769cf..864da19d 100644 --- a/projects/kiss-vscode/config/KissConfig.kiss +++ b/projects/kiss-vscode/config/KissConfig.kiss @@ -239,11 +239,12 @@ ->e (let [f e.document.fileName dir (FileSystem.readDirectory (f.directory))] - (doFor otherF dir - (whenLet [(Some _) (indexOf otherF (.withoutDirectory (f.withoutExtension))) - (Some _) (indexOf otherF (f.extension)) - true (otherF.endsWith ".ktxt2")] - (errorMessage "Editing file $(f.withoutDirectory) which is managed by $(otherF.withoutDirectory)")))))) + (unless (f.endsWith "ktxt2") + (doFor otherF dir + (whenLet [(Some _) (indexOf otherF (.withoutDirectory (f.withoutExtension))) + (Some _) (indexOf otherF (f.extension)) + true (otherF.endsWith ".ktxt2")] + (errorMessage "Editing file $(f.withoutDirectory) which is managed by $(otherF.withoutDirectory)"))))))) // TODO standardize this with KissInterp (function :Void prepareInterp []