]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
samba-tool: Command.message() can print multiple lines
authorDouglas Bagnall <douglas.bagnall@catalyst.net.nz>
Wed, 13 Aug 2025 04:21:14 +0000 (16:21 +1200)
committerDouglas Bagnall <dbagnall@samba.org>
Wed, 20 Aug 2025 04:34:37 +0000 (04:34 +0000)
Signed-off-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
Reviewed-by: Gary Lockyer <gary@catalyst.net.nz>
python/samba/netcmd/__init__.py

index 0647ed621d6085e8711fabe52d74e381f19248c5..fc8bf96f19c0e920bc6a1f15fbdb93de78769f3a 100644 (file)
@@ -300,8 +300,9 @@ class Command(object):
 
         return parser, optiongroups
 
-    def message(self, text):
-        self.outf.write(text + "\n")
+    def message(self, *text):
+        for t in text:
+            print(t, file=self.outf)
 
     def _resolve(self, path, *argv, outf=None, errf=None):
         """This is a leaf node, the command that will actually run."""