Check Games List.json #3
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: Check Games List.json | |
on: | |
schedule: | |
- cron: '0 0 * * 0' # Ejecuta a las 00:00 UTC cada domingo | |
workflow_dispatch: # Permite ejecución manual si lo deseas | |
jobs: | |
check-links: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Check out the repository | |
uses: actions/checkout@v2 | |
- name: Set up Python | |
uses: actions/setup-python@v3 | |
with: | |
python-version: '3.x' | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install requests pillow | |
- name: Run script | |
run: | | |
python scripts/games-list-autocreate.py link_status.md | |
- name: Update README with status | |
run: | | |
sed -i '/## Games List.json Status/,/|.*|.*|.*|/d' README.md | |
echo -e "## Games List.json Status\n\n$(cat link_status.md)" >> README.md | |
git config user.name "github-actions[bot]" | |
git config user.email "github-actions[bot]@users.noreply.github.com" | |
git add README.md | |
git diff --cached --quiet || git commit -m "Update README with game cover link status" | |
git push | |