Skip to content

Commit ba81117

Browse files
committed
Update build workflow to move output files and enhance HTML generation with repository links
1 parent ac70d06 commit ba81117

2 files changed

Lines changed: 7 additions & 6 deletions

File tree

.github/workflows/build_packages_info.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -150,7 +150,7 @@ jobs:
150150
- name: build html page
151151
run: |
152152
python3 build_packages_page.py
153-
mv table.html gh-pages/index.html
153+
mv output/* gh-pages/
154154
155155
- name: Upload static files as artifact
156156
id: deployment

web_pages/build_packages_page.py

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -36,18 +36,19 @@ def main(csv_file_path, html_file_path):
3636
row_count += 1
3737
html_file.write('<tr>')
3838
html_file.write('<td>' + str(row_count) + '</td>') # Row number
39-
html_file.write('<td>' + row[0] + '</td>') # Name
39+
#html_file.write('<td>' + row[0] + '</td>') # Name
40+
if len(row[5]) > 0:
41+
html_file.write('<td><a href="' + row[5] + '" target="blank">' + row[0] + '</a></td>') # GH repository link with name
42+
else:
43+
html_file.write('<td>' + row[0] + '</td>')
4044
html_file.write('<td>' + row[1] + '</td>') # Description
4145
if len(row[2]) > 0:
4246
html_file.write('<td><a href="' + row[2] + '" target="blank">Link</a></td>') # CRAN link
4347
else:
4448
html_file.write('<td></td>')
4549
html_file.write('<td>' + row[3] + '</td>') # CRAN version
4650
html_file.write('<td>' + row[4] + '</td>') # CRAN license
47-
if len(row[5]) > 0:
48-
html_file.write('<td><a href="' + row[5] + '" target="blank">Link</a></td>') # GH repository
49-
else:
50-
html_file.write('<td></td>')
51+
5152
html_file.write('<td>' + row[6] + '</td>') # GH last update
5253
html_file.write('<td>' + row[7] + '</td>') # GH version
5354
html_file.write('<td>' + row[8] + '</td>') # GH license

0 commit comments

Comments
 (0)