From 2079b2e7e19aa2fe327f2ae66d1b5eba988b9b0a Mon Sep 17 00:00:00 2001 From: wendrul <53628737+wendrul@users.noreply.github.com> Date: Mon, 21 Oct 2024 17:44:16 +0200 Subject: [PATCH] fix: Do not ignore file resources with json file ext (#4562) --- cli/sync.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cli/sync.ts b/cli/sync.ts index ce539b7a1f..342dda3162 100644 --- a/cli/sync.ts +++ b/cli/sync.ts @@ -618,8 +618,8 @@ export async function elementsToMap( for await (const entry of readDirRecursiveWithIgnore(ignore, els)) { if (entry.isDirectory || entry.ignored) continue; const path = entry.path; - if (json && path.endsWith(".yaml")) continue; - if (!json && path.endsWith(".json")) continue; + if (json && path.endsWith(".yaml") && !isFileResource(path)) continue; + if (!json && path.endsWith(".json") && !isFileResource(path)) continue; const ext = json ? ".json" : ".yaml"; if (!skips.includeSchedules && path.endsWith(".schedule" + ext)) continue; if (!skips.includeUsers && path.endsWith(".user" + ext)) continue;