Skip to content
This repository was archived by the owner on Sep 9, 2025. It is now read-only.

automate

automate #70

Workflow file for this run

name: automate
on:
schedule:
- cron: '0 10 * * *'
workflow_dispatch:
permissions:
contents: write
jobs:
auto-commit:
runs-on: ubuntu-latest
steps:
- name: Cloner le dépôt
uses: actions/checkout@v3
with:
token: ${{ secrets.GITHUB_TOKEN }}
ref: discord
- name: update calandar
run: |
DATE=$(date -u +"%d/%m/%Y")
LINE="Today $DATE"
if grep -q "Today" README.md; then
sed -i "s|Today.*|$LINE|" README.md
else
echo -e "\n$LINE" >> README.md
fi
- name: Commit et push
run: |
git config user.name "github-actions[bot]"
git config user.email "github-actions[bot]@users.noreply.github.com"
git add .
git commit -m "README.md" || echo "Pas de changements"
git push