cron #380
This file contains hidden or 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: cron | |
| on: | |
| push: | |
| branches: | |
| - gh-pages | |
| schedule: | |
| - cron: "35 3 * * *" | |
| jobs: | |
| build-and-deploy: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: 🍽️ Get working copy | |
| uses: actions/checkout@v2 | |
| with: | |
| fetch-depth: 0 | |
| - name: 🐍 Set up Python 3.8 | |
| uses: actions/setup-python@v2 | |
| with: | |
| python-version: '3.8' | |
| - name: 💿 Install feedparser pytz datetime | |
| run: pip install feedparser pytz datetime | |
| - name: 🍳 Update newsletter.md | |
| run: | | |
| cd ${GITHUB_WORKSPACE}/src/ | |
| python newsletter.py | |
| - name: 🚀 Deploy | |
| run: | | |
| git config user.name "${GITHUB_ACTOR}" | |
| git config user.email "${GITHUB_ACTOR}@users.noreply.github.com" | |
| git add . | |
| git commit -am "feat(auto generate): Updated content" | |
| git push --all -f https://${{ secrets.GITHUB_TOKEN }}@github.com/${GITHUB_REPOSITORY}.git |