check-commit: use raw string for regular expression
authorGregory Szorc <gregory.szorc@gmail.com>
Mon, 04 Feb 2019 09:31:19 -0800
changeset 41539 45a4789d3ff2
parent 41538 b5642239fb32
child 41540 17a6e063c886
check-commit: use raw string for regular expression Avoids SyntaxWarning on Python 3.8. Differential Revision: https://phab.mercurial-scm.org/D5824
contrib/check-commit
--- a/contrib/check-commit	Mon Feb 04 09:13:05 2019 -0800
+++ b/contrib/check-commit	Mon Feb 04 09:31:19 2019 -0800
@@ -47,7 +47,7 @@
      "adds a function with foo_bar naming"),
 ]
 
-word = re.compile('\S')
+word = re.compile(r'\S')
 def nonempty(first, second):
     if word.search(first):
         return first