changeset 51160:3c5b66d03c37

setup: make debug simpler by adding a `__repr__` to `hgcommand` This help when trying to debug this logic.
author Pierre-Yves David <pierre-yves.david@octobus.net>
date Fri, 01 Dec 2023 22:13:37 +0100
parents ac3859a8b796
children f816ca29a285
files setup.py
diffstat 1 files changed, 4 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/setup.py	Wed Nov 15 18:43:03 2023 +0000
+++ b/setup.py	Fri Dec 01 22:13:37 2023 +0100
@@ -221,6 +221,9 @@
         self.cmd = cmd
         self.env = env
 
+    def __repr__(self):
+        return f"<hgcommand cmd={self.cmd} env={self.env}>"
+
     def run(self, args):
         cmd = self.cmd + args
         returncode, out, err = runcmd(cmd, self.env)
@@ -1821,5 +1824,5 @@
             'welcome': 'contrib/packaging/macosx/Welcome.html',
         },
     },
-    **extra
+    **extra,
 )