Skip to content

automation

automation #13

Workflow file for this run

name: automation
on:
schedule:
# Runs at 10:00 UTC every day.
# The original '0 0 10 * *' ran once a month.
- cron: '0 10 * * *'
workflow_dispatch: # Allows you to run it manually
# Required permissions for the built-in GITHUB_TOKEN to push changes
permissions:
contents: write
jobs:
scrape:
runs-on: ubuntu-latest
steps:
- name: Check out this repo
# This action automatically uses the properly-permissioned GITHUB_TOKEN
uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.x'
- name: Install necessary packages
run: |
# Note: sudo apt-get can be slow. If possible, manage dependencies
# with Python's pip where you can.
sudo apt-get update
sudo apt-get install -y chromium-browser
pip install requests beautifulsoup4 pandas webdriver-manager selenium
- name: Run the scraping script
run: python scraper.py
- name: Commit and push changes
# This action will automatically commit and push any new or modified files
uses: stefanzweifel/git-auto-commit-action@v5
with:
commit_message: "Automated data scrape"