From b4d78004d40fa9dd4c0c1bf29df00b0240be4b60 Mon Sep 17 00:00:00 2001 From: Dmytro Hryshyn Date: Wed, 6 Dec 2023 17:00:31 +0200 Subject: [PATCH] fix --- src/codemods/types.ts | 2 ++ src/components/engineService.ts | 1 + src/data/codemodConfigSchema.ts | 5 +++++ 3 files changed, 8 insertions(+) diff --git a/src/codemods/types.ts b/src/codemods/types.ts index 28942db4..638b1780 100644 --- a/src/codemods/types.ts +++ b/src/codemods/types.ts @@ -40,6 +40,7 @@ export const codemodEntryCodec = t.union([ t.literal('jscodeshift'), t.literal('ts-morph'), t.literal('repomod-engine'), + t.literal('filemod'), t.literal('recipe'), ]), arguments: argumentsCodec, @@ -71,6 +72,7 @@ export const privateCodemodEntryCodec = buildTypeCodec({ t.literal('jscodeshift'), t.literal('ts-morph'), t.literal('repomod-engine'), + t.literal('filemod'), t.literal('recipe'), ]), permalink: t.union([t.string, t.null]), diff --git a/src/components/engineService.ts b/src/components/engineService.ts index eacd9015..3b67d633 100644 --- a/src/components/engineService.ts +++ b/src/components/engineService.ts @@ -353,6 +353,7 @@ export class EngineService { if ( config.engine === 'jscodeshift' || config.engine === 'ts-morph' || + config.engine === 'filemod' || config.engine === 'repomod-engine' || config.engine === 'recipe' ) { diff --git a/src/data/codemodConfigSchema.ts b/src/data/codemodConfigSchema.ts index 6b21d9a3..a2e114d2 100644 --- a/src/data/codemodConfigSchema.ts +++ b/src/data/codemodConfigSchema.ts @@ -69,6 +69,11 @@ export const codemodConfigSchema = S.union( engine: S.literal('ts-morph'), arguments: S.optional(argumentsSchema), }), + S.struct({ + schemaVersion: S.literal('1.0.0'), + engine: S.literal('filemod'), + arguments: S.optional(argumentsSchema), + }), S.struct({ schemaVersion: S.literal('1.0.0'), engine: S.literal('repomod-engine'),