diff --git a/.gitea/workflows/update-readme.yml b/.gitea/workflows/update-readme.yml new file mode 100644 index 0000000..ccf645d --- /dev/null +++ b/.gitea/workflows/update-readme.yml @@ -0,0 +1,29 @@ +name: Auto-update README + +on: + push: + branches: [main] + +jobs: + update-readme: + runs-on: ubuntu-latest + steps: + - name: Клонировать репозиторий + uses: actions/checkout@v4 + with: + token: ${{ secrets.ACTIONS_TOKEN }} + + - name: Запустить Python-скрипт + run: python3 scripts/update_readme.py + + - name: Закоммитить изменения, если есть + run: | + git config user.name "README Bot" + git config user.email "bot@example.com" + if git diff --quiet README.md; then + echo "Изменений нет" + else + git add README.md + git commit -m "Автообновление README [skip ci]" + git push + fi \ No newline at end of file