Skip to content

Commit

Permalink
only consider codegen/codegen rules
Browse files Browse the repository at this point in the history
  • Loading branch information
mmkal committed Mar 22, 2024
1 parent f65e6e1 commit 4aafe14
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/processor.ts
Expand Up @@ -18,7 +18,9 @@ export const createProcessor = (): eslint.Linter.Processor => {
],
postprocess(messageLists, filename) {
return [
...messageLists[0], // first one is the codegen-able file, the rest are from eslint-plugin-markdown
// first one is the codegen-able file, the rest are from eslint-plugin-markdown
// but we're only interested in the codegen messages, not formatting issues etc. - those can cause bogus "fixes" which delete real content
...messageLists[0].filter(m => m.ruleId === 'codegen/codegen'),
...eslintPluginMarkdownProcessor.postprocess!(messageLists.slice(1), filename),
]
},
Expand Down

0 comments on commit 4aafe14

Please sign in to comment.