]> git.ipfire.org Git - pbs.git/commitdiff
config: Fix concatenating the configuration
authorMichael Tremer <michael.tremer@ipfire.org>
Sun, 23 Oct 2022 20:58:31 +0000 (20:58 +0000)
committerMichael Tremer <michael.tremer@ipfire.org>
Sun, 23 Oct 2022 20:58:31 +0000 (20:58 +0000)
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
src/buildservice/config.py
src/buildservice/distribution.py

index c70cef4aa351dc57ca3f3b33c319830c11cf4dff..0f738ceb41b689c0c9fe9d3a563c69b2ef9c7b81 100644 (file)
@@ -64,14 +64,16 @@ class PakfireConfig(base.Object):
                """
                        Generates the configuration file
                """
-               lines = []
+               parts = []
 
                # Add the distro configuration
                if self.distro:
-                       lines += self.distro._make_config(local=local)
+                       config = self.distro._make_config(local=local)
+                       parts.append(config)
 
                # Add the repository configurations
                for repo in self.repos:
-                       lines += repo._make_config(local=local)
+                       config = repo._make_config(local=local)
+                       parts.append(config)
 
-               return "\n".join(lines)
+               return "\n".join(parts)
index 2996771daab46fae7d56167cbd5aba777c2ec733..066cee47aae68ea245c97c039068950137b4bcca 100644 (file)
@@ -103,7 +103,7 @@ class Distribution(base.DataObject):
                                "### CUSTOM CONFIG END ###",
                        )
 
-               return lines
+               return "\n".join(lines)
 
        # Name