From a551d75d7bae7aaca3f1621e342c0a7b81e6f48a Mon Sep 17 00:00:00 2001 From: Steve C Date: Thu, 28 Nov 2024 21:34:52 -0500 Subject: [PATCH] Create update-submodules.yml --- .github/workflows/update-submodules.yml | 30 +++++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 .github/workflows/update-submodules.yml diff --git a/.github/workflows/update-submodules.yml b/.github/workflows/update-submodules.yml new file mode 100644 index 0000000..f35a13d --- /dev/null +++ b/.github/workflows/update-submodules.yml @@ -0,0 +1,30 @@ +name: Update Submodules + +on: + schedule: + - cron: '0 0 * * 0' # Every Sunday at midnight UTC + workflow_dispatch: # Allows manual triggering + +jobs: + update-submodules: + runs-on: ubuntu-latest + + steps: + - name: Checkout repository + uses: actions/checkout@v3 + with: + submodules: true + + - name: Update submodules + run: | + git submodule update --remote --merge + + - name: Commit and push changes + run: | + git config user.name "GitHub Actions" + git config user.email "actions@github.com" + git add . + git commit -m "Update submodules" + git push + env: + GITHUB_TOKEN: ${{ github.token }}