Skip to content

feat(portfolio): curar los 8 Proyectos Principales (Featured Portfoli… #10

feat(portfolio): curar los 8 Proyectos Principales (Featured Portfoli…

feat(portfolio): curar los 8 Proyectos Principales (Featured Portfoli… #10

name: Medalcode Agent Tasks
on:
schedule:
- cron: '0 0 1 * *' # El día 1 de cada mes
workflow_dispatch: # Permite ejecución manual
permissions:
contents: write
jobs:
agent-tasks:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Update Last Updated Date
run: |
# Generar fecha en español de forma agnóstica al SO/locale
CURRENT_DATE=$(python3 -c "
import datetime

Check failure on line 22 in .github/workflows/agent-scheduler.yml

View workflow run for this annotation

GitHub Actions / .github/workflows/agent-scheduler.yml

Invalid workflow file

You have an error in your yaml syntax on line 22
months = ['Enero', 'Febrero', 'Marzo', 'Abril', 'Mayo', 'Junio', 'Julio', 'Agosto', 'Septiembre', 'Octubre', 'Noviembre', 'Diciembre']
now = datetime.datetime.now(datetime.timezone.utc)
print(f'{months[now.month - 1]} {now.year}')
")
echo "Fecha formateada: $CURRENT_DATE"
sed -i -E "s/(<!-- DATE_START -->).*?(<!-- DATE_END -->)/\1${CURRENT_DATE}\2/g" README.md
- name: Audit Assets
run: |
chmod +x generate-assets.sh
./generate-assets.sh check || echo "Asset audit completed"
- name: Commit changes
run: |
git config --global user.name "Medalcode-Agent"
git config --global user.email "jonatthan.medalla@gmail.com"
git add README.md
if ! git diff --cached --quiet; then
git commit -m "docs(agent): actualizar fecha del perfil a ${CURRENT_DATE}"
git push
else
echo "No changes to commit."
fi