Merge pull request #46 from NIkenna1/topic/Update-Documents-For-SDK-C… #39
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: Notify Parent Repo | |
| on: | |
| push: | |
| branches: | |
| - main | |
| jobs: | |
| update-parent: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout current repository | |
| uses: actions/checkout@v6 | |
| with: | |
| fetch-depth: 0 | |
| - name: Checkout parent repository | |
| uses: actions/checkout@v6 | |
| with: | |
| repository: ${{ vars.PARENT_ORG }}/${{ vars.PARENT_REPO }} | |
| path: ${{ vars.PARENT_REPO }} | |
| token: ${{ secrets.PRIVATE_TOKEN }} | |
| submodules: recursive | |
| - name: Commit changes to parent repo | |
| run: | | |
| cp -r ./* ./${{ vars.PARENT_REPO }}/ | |
| cd ./${{ vars.PARENT_REPO }} | |
| git config user.name "github-actions[bot]" | |
| git config user.email "github-actions[bot]@users.noreply.github.com" | |
| git add --all | |
| git commit -m "Update submodules, triggered by ${GITHUB_REPOSITORY}" || echo "No changes to commit" | |
| git push https://${{ secrets.PRIVATE_TOKEN }}@github.com/${{ vars.PARENT_ORG }}/${{ vars.PARENT_REPO }}.git main |