From e51a013eb583a90f280486a3a78fbbd0b78bd158 Mon Sep 17 00:00:00 2001 From: Haoran Date: Sun, 16 Aug 2026 22:49:10 +0800 Subject: [PATCH] ci: remove fork-only upstream sync workflow --- .github/workflows/sync-upstream.yml | 33 ----------------------------- 1 file changed, 33 deletions(-) delete mode 100644 .github/workflows/sync-upstream.yml diff --git a/.github/workflows/sync-upstream.yml b/.github/workflows/sync-upstream.yml deleted file mode 100644 index 0bd1d658..00000000 --- a/.github/workflows/sync-upstream.yml +++ /dev/null @@ -1,33 +0,0 @@ -name: Sync fork with upstream - -# 定时把本 fork 的 main 合入上游 shareAI-lab/learn-claude-code 的最新提交。 -# 因为这个 workflow 文件本身就在 main 上,main 与上游已分叉、无法 fast-forward, -# 所以用 merge 而非 gh repo sync。结果:main = 全部上游更新 + 本自动化提交。 -# 自己的改动请始终开新分支,不要直接提交到 main,否则可能与上游产生合并冲突。 - -on: - schedule: - - cron: '0 * * * *' # 每小时一次;想每天一次改成 '0 6 * * *' - workflow_dispatch: # 也可在仓库 Actions 页面手动触发 - -permissions: - contents: write # 合并后需要写权限 push 回 main - -jobs: - sync: - runs-on: ubuntu-latest - steps: - # actions/checkout@v6 —— 与本仓库其它 workflow 用同一 pin - - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd - with: - ref: main - fetch-depth: 0 # merge 需要完整历史 - - - name: Merge upstream/main into main - run: | - git config user.name "github-actions[bot]" - git config user.email "41898282+github-actions[bot]@users.noreply.github.com" - git remote add upstream https://github.com/shareAI-lab/learn-claude-code.git - git fetch upstream main - git merge --no-edit upstream/main - git push origin main