Sync Codetree Subtree #143
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Sync Codetree Subtree | |
| on: | |
| schedule: | |
| - cron: '0 16 * * *' # 매일 KST 1시 | |
| workflow_dispatch: | |
| jobs: | |
| sync: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout algorithm repo | |
| uses: actions/checkout@v4 | |
| with: | |
| fetch-depth: 0 # subtree 병합에 필요한 커밋 이력 확보 | |
| - name: Set Git config | |
| run: | | |
| git config user.name "github-actions[bot]" | |
| git config user.email "github-actions[bot]@users.noreply.github.com" | |
| - name: Add codetree remote | |
| run: | | |
| git remote add codetree https://github.com/junest66/codetree-solutions.git | |
| git fetch codetree | |
| - name: Pull codetree subtree | |
| run: | | |
| git subtree pull --prefix=codetree codetree main -m "chore(subtree): sync codetree" | |
| - name: Push updated subtree | |
| run: | | |
| git push origin main |