From b63f20f035088b198c4566c471e3edbcf7cf4199 Mon Sep 17 00:00:00 2001 From: Dominik Forster Date: Mon, 21 Jun 2021 10:07:34 +0200 Subject: [PATCH] fix: change prettier files selection --- src/prettier/index.ts | 4 ++-- src/prettier/index_spec.ts | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/prettier/index.ts b/src/prettier/index.ts index 2ae01d4..27b5c83 100644 --- a/src/prettier/index.ts +++ b/src/prettier/index.ts @@ -85,8 +85,8 @@ function addLintScript(): Rule { ? packageJson.scripts.lint.split('&&') : []; - if (!lintScripts.includes('prettier -c *')) { - lintScripts.push('prettier -c *'); + if (!lintScripts.includes('prettier -c .')) { + lintScripts.push('prettier -c .'); } packageJson.scripts.lint = lintScripts diff --git a/src/prettier/index_spec.ts b/src/prettier/index_spec.ts index 2210e35..b40ab45 100644 --- a/src/prettier/index_spec.ts +++ b/src/prettier/index_spec.ts @@ -42,6 +42,6 @@ describe('prettier', () => { .toPromise(); const content = tree.readContent('/package.json'); - expect(content).toMatch('prettier -c *'); + expect(content).toContain('prettier -c .'); }); });