Skip to content

Add and commit new Google Custom Search (GCS) data for 2024Q4 #9

Add and commit new Google Custom Search (GCS) data for 2024Q4

Add and commit new Google Custom Search (GCS) data for 2024Q4 #9

Workflow file for this run

name: Debug
on:
push:
branches:
- debug
workflow_dispatch:
jobs:
debug-fetch:
runs-on: ubuntu-latest
steps:
- name: Configure git
id: setup
run: |
git config --global init.defaultBranch main
echo quarter="$(date +%Y)Q$(( ($(date +%-m)-1)/3+1 ))" \
>> "${GITHUB_OUTPUT}"
- name: Checkout repository
uses: actions/checkout@v4
with:
fetch-depth: 0
# sparse-checkout: |
# data/${{ steps.setup.outputs.quarter }}/1-fetch
# scripts/1-fetch
token: ${{ secrets.BOT_TOKEN }}
- name: Configure git
run: |
git config user.name "${{ secrets.BOT_NAME }}"
git config user.email "${{ secrets.BOT_EMAIL }}"
- name: Setup Python
uses: actions/setup-python@v5
with:
python-version: '3.11'
- name: Install Python dependencies
run: |
pip install --upgrade pip
pip install pipenv
pipenv sync --system
echo "PYTHONPATH=./scripts" >> "${GITHUB_ENV}"
- name: Fetch from Google Custom Search (GCS)
run: |
./scripts/1-fetch/gcs_fetch.py \
--limit=100 --enable-save --enable-git --dev
env:
GCS_DEVELOPER_KEY: ${{ secrets.GCS_DEVELOPER_KEY }}
GCS_CX: ${{ secrets.GCS_CX }}
GIT_PYTHON_TRACE: full