Update Submodules #1
This file contains 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: Update Submodules | |
on: | |
workflow_dispatch: | |
jobs: | |
update-submodules: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout Repository | |
uses: actions/checkout@v3 | |
with: | |
token: ${{ secrets.GITHUB_TOKEN }} | |
submodules: true | |
fetch-depth: 0 | |
- name: Update Submodules | |
run: | | |
git submodule update --remote --merge | |
- name: Commit changes | |
run: | | |
git config user.name "GitHub Actions" | |
git config user.email "[email protected]" | |
git add . | |
git commit -m "Update submodules" || echo "No changes to commit" | |
- name: Push changes | |
uses: ad-m/github-push-action@master | |
with: | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
branch: main |