Skip to content

Commit

Permalink
Update docs
Browse files Browse the repository at this point in the history
  • Loading branch information
SWHL authored Apr 24, 2024
1 parent ba94424 commit c6d7282
Showing 1 changed file with 0 additions and 23 deletions.
23 changes: 0 additions & 23 deletions scripts/convert.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,26 +7,6 @@
import yaml


comment_js = """
<script src="https://giscus.app/client.js"
data-repo="SWHL/AI-Competition-Collections"
data-repo-id="MDEwOlJlcG9zaXRvcnkzNjI2NTQ0NDA="
data-category="Ideas"
data-category-id="DIC_kwDOFZ2q6M4Ce5Hv"
data-mapping="title"
data-strict="0"
data-reactions-enabled="1"
data-emit-metadata="0"
data-input-position="top"
data-theme="preferred_color_scheme"
data-lang="zh-CN"
data-loading="lazy"
crossorigin="anonymous"
async>
</script>
"""


class ConvertMDToHugo:
def __init__(self):
self.root_dir = Path(__file__).resolve().parent.parent
Expand Down Expand Up @@ -93,7 +73,6 @@ def convert_one_type(self, config):

short_line_idx = ori_md_data.index("---")
ori_md_data = ori_md_data[short_line_idx + 1 :]
ori_md_data.append(f'\n\n{comment_js}')

save_md_dir = self.save_dir / menu_title
self.mkdir(save_md_dir)
Expand Down Expand Up @@ -133,7 +112,6 @@ def convert_cv(
]

prefix_list.extend(md_content)
prefix_list.append(f'\n\n{comment_js}')
save_path = save_cv_dir / f"{md_name}.md"
self.write_txt(save_path, prefix_list)

Expand All @@ -152,7 +130,6 @@ def create_cv_index_md(self, save_path: str):
" ",
self.children,
" ",
comment_js
]

self.write_txt(str(save_path), prefix_content)
Expand Down

0 comments on commit c6d7282

Please sign in to comment.