|
4 | 4 | import markdown
|
5 | 5 |
|
6 | 6 | # Specify the directory path
|
7 |
| -dir_path = pathlib.Path('specs/') |
| 7 | +#dir_path = pathlib.Path('specs/') |
| 8 | +dir_path = pathlib.Path('.') |
8 | 9 |
|
9 | 10 | # Use glob to retrieve a list of files
|
10 |
| -files = dir_path.glob('**/*.spec') # only match .spec files |
| 11 | +#files = dir_path.glob('**/*.spec') # only match .spec files |
| 12 | +files = dir_path.glob('specs/**/*.spec') # only match .spec files |
11 | 13 |
|
12 | 14 | # Sort the files by filename (natural sort)
|
13 | 15 | sorted_files = sorted(files, key=lambda x: x.name)
|
|
39 | 41 |
|
40 | 42 | <details open>
|
41 | 43 |
|
42 |
| -<summary>Status badges on COPR builds</summary>\n |
| 44 | +<summary>Status badges on COPR builds</summary> |
43 | 45 | """
|
44 | 46 |
|
45 | 47 | for name, url in name_url_pairs:
|
46 | 48 | readme_content += f"""
|
47 | 49 | ### {name}
|
48 | 50 |
|
49 |
| - |
50 |
| -[Upstream]({url})\n |
51 |
| - """ |
| 51 | + |
| 52 | +[Upstream]({url}) |
| 53 | +""" |
52 | 54 |
|
53 | 55 | # Convert markdown content to HTML (optional, for further use)
|
54 | 56 | #html_content = markdown.markdown(markdown_content)
|
55 | 57 |
|
56 | 58 | # Write markdown content to README.md
|
57 |
| -readme_path = pathlib.Path("../README.md") |
| 59 | +#readme_path = pathlib.Path("../README.md") |
| 60 | +readme_path = pathlib.Path("README.md") |
58 | 61 | with readme_path.open("w", encoding="utf-8") as readme_file:
|
59 | 62 | readme_file.write(readme_content)
|
60 | 63 |
|
|
0 commit comments