Skip to content

Commit 9bf6062

Browse files
author
Bert Outtier
committed
allow extending or overriding the patching config from the userpatches folder
1 parent 0b14d56 commit 9bf6062

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

lib/tools/common/patching_config.py

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -52,11 +52,9 @@ def __str__(self):
5252
class PatchingConfig:
5353
def __init__(self, yaml_config_file_paths: list[str]):
5454
self.yaml_config_file_paths = yaml_config_file_paths
55-
if len(yaml_config_file_paths) == 0:
56-
self.yaml_config = {}
57-
else:
58-
# I'm lazy, single one for now.
59-
self.yaml_config = self.read_yaml_config(yaml_config_file_paths[0])["config"]
55+
self.yaml_config = {}
56+
for p in yaml_config_file_paths:
57+
self.yaml_config.update(self.read_yaml_config(p)["config"])
6058

6159
self.patches_to_git_config: PatchingToGitConfig = PatchingToGitConfig(self.yaml_config.get("patches-to-git", {}))
6260

0 commit comments

Comments
 (0)