Skip to content

Update Research-Methodology Submodule #7474

Update Research-Methodology Submodule

Update Research-Methodology Submodule #7474

name: Update Research-Methodology Submodule
on:
schedule:
# Runs at the start of every hour
- cron: '0 * * * *'
workflow_dispatch:
permissions:
contents: write
jobs:
update-submodule:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v2
with:
# Fetches all history for all tags and branches, including submodules
fetch-depth: 0
submodules: 'recursive'
- name: Configure git settings
run: |
git config --global pull.rebase false
git config --global user.email "[email protected]"
git config --global user.name "Breno Farias da Silva"
- name: Forcefully update Research-Methodology submodule to latest
run: |
cd Research-Methodology
git fetch origin main
git reset --hard origin/main
- name: Commit and push if changes are detected
run: |
git add Research-Methodology
git diff --cached --quiet || git commit -m "UPDATE: Automatically Updating the Research-Methodology SubModule to Latest Version."
git push || echo "No changes to push."