From 668e6415c036b16f8e173f0e012eb09080d258d4 Mon Sep 17 00:00:00 2001 From: Anthony Sottile Date: Sat, 30 Mar 2019 14:05:24 -0700 Subject: [PATCH] Adjust messaging slightly --- pre_commit/commands/run.py | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/pre_commit/commands/run.py b/pre_commit/commands/run.py index ed5a0184..cfa62ee2 100644 --- a/pre_commit/commands/run.py +++ b/pre_commit/commands/run.py @@ -217,12 +217,13 @@ def _run_hooks(config, hooks, args, environ): if retval and args.show_diff_on_failure and git.has_diff(): if args.all_files: output.write_line( - 'Pre-commit hook(s) made changes. ' - 'If you are seeing this message on CI,' - ' reproduce locally with: pre-commit run --all-files', + 'pre-commit hook(s) made changes.\n' + 'If you are seeing this message in CI, ' + 'reproduce locally with: `pre-commit run --all-files`.\n' + 'To run `pre-commit` as part of git workflow, use ' + '`pre-commit install`.', ) - else: - output.write_line('All changes made by hooks:') + output.write_line('All changes made by hooks:') subprocess.call(('git', '--no-pager', 'diff', '--no-ext-diff')) return retval