Create 3.3.5.yaml #40
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: Update README with Templates | |
on: | |
push: | |
branches: | |
- dev | |
paths: | |
- '**.yaml' | |
pull_request: | |
branches: | |
- dev | |
jobs: | |
update-readme: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout the repository | |
uses: actions/checkout@v4 | |
with: | |
submodules: true # Ensure submodules are initialized and updated | |
- name: Initialize and update submodules (if needed) | |
run: git submodule update --init --recursive | |
- name: Set up Python | |
uses: actions/setup-python@v4 | |
with: | |
python-version: '3.x' | |
- name: Run Python script to update README | |
run: python .github/scripts/update-readme.py | |
# Set up GPG for commit signing | |
- name: Set up GPG | |
run: | | |
echo "${{ secrets.GPG_PRIVATE_KEY }}" | gpg --batch --import | |
git config --global user.name "Signing Bot" | |
git config --global user.email "[email protected]" | |
git config --global commit.gpgSign true | |
git config --global user.signingkey ${{ secrets.GPG_KEY_ID }} | |
# Commit changes with GPG signing | |
- name: Commit changes if any | |
run: | | |
git add README.md | |
if ! git diff --cached --quiet; then | |
git commit -S -m "Update README table" | |
else | |
echo "No changes to commit" | |
fi | |
# Push changes | |
- name: Push changes | |
run: | | |
git pull origin dev --rebase | |
git push origin dev |