π¦ Script Feed-RSS #562
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: π¦ Script Feed-RSS | |
on: | |
schedule: | |
- cron: '0 8 * * *' | |
push: | |
branches: [ "develop" ] | |
permissions: | |
contents: write | |
jobs: | |
deployment: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
repo-token: ${{ secrets.GITHUB_TOKEN }} | |
- name: βοΈ Set up Python 3.11 | |
uses: actions/setup-python@v3 | |
with: | |
python-version: "3.11" | |
- name: βοΈ Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install -r requirements.txt --no-cache-dir | |
- name: β Run Script | |
run: | | |
python ./src/main.py | |
- name: π Git Config | |
run: | | |
git config --global user.email ${{secrets.EMAIL}} | |
git config --global user.name ${{secrets.USERNAME}} | |
shell: bash | |
- name: π Git Process | |
run: | | |
if [[ `git status --porcelain` ]]; then | |
git add --all | |
git commit -a -m "π» BOO: Update" | |
git push origin HEAD:master --force | |
else | |
echo "WARNING: No changes were detected. git commit push action aborted." | |
fi | |
shell: bash | |
continue-on-error: true |