From 114a73f100bf24be6170d9780b89763409ea34e1 Mon Sep 17 00:00:00 2001 From: soksanichenko Date: Sat, 15 Apr 2023 20:03:27 +0300 Subject: [PATCH] - gather-module can find modules through symlinks - Bump version - Update changelog --- pungi.spec | 5 ++++- pungi/scripts/gather_modules.py | 8 ++++++-- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/pungi.spec b/pungi.spec index 85e4e318..0f7dd2f4 100644 --- a/pungi.spec +++ b/pungi.spec @@ -2,7 +2,7 @@ Name: pungi Version: 4.3.7 -Release: 6%{?dist}.alma +Release: 7%{?dist}.alma Summary: Distribution compose tool License: GPL-2.0-only @@ -159,6 +159,9 @@ rm %{buildroot}%{_bindir}/pungi %changelog +* Thu Apr 13 2023 Stepan Oksanichenko - 4.3.7-7 +- gather-module can find modules through symlinks + * Thu Apr 13 2023 Stepan Oksanichenko - 4.3.7-6 - CLI option `--label` can be passed through a Pungi config file diff --git a/pungi/scripts/gather_modules.py b/pungi/scripts/gather_modules.py index 46e9d440..ee27cd37 100644 --- a/pungi/scripts/gather_modules.py +++ b/pungi/scripts/gather_modules.py @@ -2,6 +2,7 @@ import gzip import lzma import os from argparse import ArgumentParser, FileType +from glob import iglob from io import BytesIO from pathlib import Path from typing import List, AnyStr, Iterable, Union, Optional @@ -30,8 +31,11 @@ def grep_list_of_modules_yaml(repos_path: AnyStr) -> Iterable[BytesIO]: """ return ( - read_modules_yaml_from_specific_repo(repo_path=path.parent) - for path in Path(repos_path).rglob('repodata') + read_modules_yaml_from_specific_repo(repo_path=Path(path).parent) + for path in iglob( + str(Path(repos_path).joinpath('**/repodata')), + recursive=True + ) )