Skip to content

Commit 1f5ec3b

Browse files
committed
chore(pdf): KTL-1507: drop test page from pdf
1 parent 963abde commit 1f5ec3b

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/pdf.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,10 @@ def transform_book_content(path_file):
7272
node['src'] = node["src"][7:]
7373
node['data-dark-src'] = node["data-dark-src"][7:]
7474

75+
for page in soup.select('[id="test-page.md"], [id="kotlin-brand-assets.md-kotlin-night-brand-assets"]'):
76+
print("Drop %s" % page['id'])
77+
page.find_parent('section').decompose()
78+
7579
result_file = get_tmp_filename(path_file)
7680

7781
with open(result_file, "w", encoding='utf-8') as output:

0 commit comments

Comments
 (0)