From 1b17f5b3440c40ccc1949ab27b1bd7cfbaf50c7c Mon Sep 17 00:00:00 2001 From: Boyu Gou <103808989+boyugou@users.noreply.github.com> Date: Thu, 19 Dec 2024 22:10:14 -0500 Subject: [PATCH] Update main.yml --- .github/workflows/main.yml | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index dd40970..4a13915 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -3,12 +3,12 @@ name: Update README with Sorted Papers Content on: push: paths: - - 'update_template_or_data/update_paper_list.md' # 监听 update_paper_list.md 文件的更新 - - 'update_template_or_data/utils/scripts/sort_by_date.py' # 监听 update_template_or_data/utils/scripts/sort_by_date.py 脚本的更新 - - 'update_template_or_data/update_readme_template.md' # 监听 update_template_or_data/utils/scripts/sort_by_date.py 脚本的更新 + - 'update_template_or_data/update_paper_list.md' # listen to update_paper_list.md + - 'update_template_or_data/utils/scripts/sort_by_date.py' # listen to update_template_or_data/utils/scripts/sort_by_date.py + - 'update_template_or_data/update_readme_template.md' # listen to update_template_or_data/utils/scripts/sort_by_date.py - '.github/workflows/main.yml' # schedule: - # - cron: '0 0 * * *' # 每天定时运行(0点) + # - cron: '0 0 * * *' # everyday jobs: update-readme: @@ -85,10 +85,8 @@ jobs: - name: Update temp_readme.md with sorted papers content run: | - # 读取更新后的 update_template_or_data/update_paper_list.md 内容 CONTENT=$(cat update_template_or_data/update_paper_list.md) - # 使用 sed 插入 content 到 temp_readme.md 的占位符位置 sed -i '/{{insert_all_papers_here}}/{ r /dev/stdin d @@ -99,7 +97,7 @@ jobs: - name: Overwrite README.md with updated temp_readme.md run: | - # 覆盖 README.md + # overwrite README.md cp update_template_or_data/update_readme_template.md README.md - name: Commit changes