From dc0840a425aa5a2b2217f164a75d323dbf027de8 Mon Sep 17 00:00:00 2001 From: Maximilian Franzke <787658+mfranzke@users.noreply.github.com> Date: Wed, 20 Nov 2024 23:05:08 +0100 Subject: [PATCH] fix(prettier): windows environments (#293) --- .config/.lintstagedrc-prettier.js | 3 +++ .husky/pre-commit | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) create mode 100644 .config/.lintstagedrc-prettier.js diff --git a/.config/.lintstagedrc-prettier.js b/.config/.lintstagedrc-prettier.js new file mode 100644 index 0000000..655bfb5 --- /dev/null +++ b/.config/.lintstagedrc-prettier.js @@ -0,0 +1,3 @@ +export default { + '**/*': 'prettier --write --ignore-unknown' +}; diff --git a/.husky/pre-commit b/.husky/pre-commit index f210f6b..70d36e5 100755 --- a/.husky/pre-commit +++ b/.husky/pre-commit @@ -1,2 +1,2 @@ -prettier $(git diff --cached --name-only --diff-filter=ACMR | sed 's|( |&)|\\ |g') --write --ignore-unknown +lint-staged --config .config/.lintstagedrc-prettier.js git update-index --again