Skip to content

Merge pull request #900 from snoop168/lava-output #40

Merge pull request #900 from snoop168/lava-output

Merge pull request #900 from snoop168/lava-output #40

name: Update Module Info
on:
push:
branches:
- lava-output
paths:
- 'scripts/artifacts/**'
workflow_dispatch:
permissions:
contents: write
jobs:
update-module-info:
# Only run on the main repository, not on forks
if: github.repository == 'abrignoni/iLEAPP'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.x'
- name: Run module_info script
run: python admin/scripts/module_info.py
- name: Check for changes
id: git-check
run: |
git diff --exit-code || echo "changes=true" >> $GITHUB_OUTPUT
- name: Commit changes
if: steps.git-check.outputs.changes == 'true'
run: |
git config --local user.email "action@github.com"
git config --local user.name "GitHub Action"
git add admin/docs/module_info.md
git commit -m "Update module_info.md"
- name: Push changes
if: steps.git-check.outputs.changes == 'true'
run: |
git push