From 054e23984dcf2d917dfc4923d888f96d6c60ebce Mon Sep 17 00:00:00 2001 From: Jan Nicklas Date: Thu, 17 Jan 2019 23:21:15 +0100 Subject: [PATCH] feat: add --bail option which fails on fix (#52) (#60) --- README.md | 4 ++++ bin/pretty-quick.js | 21 +++++++++++++-------- src/__tests__/scm-git.test.js | 27 +++++++++++++++++++++++++++ src/__tests__/scm-hg.test.js | 16 ++++++++++++++++ src/index.js | 12 ++++++++++++ 5 files changed, 72 insertions(+), 8 deletions(-) diff --git a/README.md b/README.md index b64e1ed..a48c5de 100644 --- a/README.md +++ b/README.md @@ -97,6 +97,10 @@ For example `pretty-quick --pattern "**/*.*(js|jsx)"` or `pretty-quick --pattern Outputs the name of each file right before it is proccessed. This can be useful if Prettier throws an error and you can't identify which file is causing the problem. +## `--bail` + +Prevent `git commit` if any files are fixed. +