Skip to content

Build EPG

Build EPG #1409

Workflow file for this run

name: Build EPG
on:
schedule:
- cron: '0 */8 * * *'
push:
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Get current date
id: date
run: echo "RUN_DATE=$(date +'%Y-%m-%d')" >> $GITHUB_ENV
- name: checkout repo content
uses: actions/checkout@v3
- name: pull changes
run: |
git pull
- name: Set up Python
uses: actions/setup-python@v3
with:
python-version: "3.10"
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
- name: execute py script
run: python main.py
- name: commit files
run: |
git config --local user.email "action@github.com"
git config --local user.name "GitHub Action"
git add -A
git diff-index --quiet HEAD || (git commit -a -m "Updated EPG listings on $RUN_DATE" --allow-empty)
- name: push changes
uses: ad-m/github-push-action@master
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
branch: master