Patchwork [2,of,5,BLACKGNAROK] formatting: remove the data-ogre from the config example

mail settings
Submitter Pierre-Yves David
Date Oct. 7, 2019, 4:15 p.m.
Message ID <>
Download mbox | patch
Permalink /patch/42064/
State Accepted
Headers show


Pierre-Yves David - Oct. 7, 2019, 4:15 p.m.
# HG changeset patch
# User Pierre-Yves David <>
# Date 1570463314 14400
#      Mon Oct 07 11:48:34 2019 -0400
# Node ID 99946ed8e49657d0678426b9fda3958bd102ed67
# Parent  f243703025e2ba5a53feb6f8ca8f029b6e186194
# EXP-Topic blackgnarok-bytemageddon
# Available At
#              hg pull -r 99946ed8e496
formatting: remove the data-ogre from the config example

Without he final `-`, black ignore the stdin and just looks at file provided as
command line argument.

Since `hg fix` feeds the file content through stdin and does not pass file
argument, this meant black happily exited successful (all files passed as
argument were formatted) without any output. Fix picked this "no output" as the
new file content, deleting all previous content.

I appreciate the fact this effectively removed all buggy code in any files
processing that way, but this also ate all my data.

The example config is now fixed in that regards.


diff --git a/contrib/examples/fix.hgrc b/contrib/examples/fix.hgrc
--- a/contrib/examples/fix.hgrc
+++ b/contrib/examples/fix.hgrc
@@ -11,5 +11,5 @@  rustfmt:pattern = set:**.rs
 # git+
 # to have the dependencies for grey.
-# black:command = python3.7 contrib/ --skip-string-normalization
+# black:command = python3.7 contrib/ --skip-string-normalization -
 # black:pattern = set:**.py - hgext/fsmonitor/pywatchman/** - mercurial/thirdparty/** - "contrib/python-zstandard/**"