Skip to content

Updating the Talk Map locations

rjzupkoii edited this page Jan 4, 2025 · 1 revision

By default the Talk Map is disabled, but can be added to your website by updating your configuration and adding a GitHub Action to run the Jupter notebook which will scrape the talk locations every time you push changes to your repository.

  1. In _config.yml, on line 89 set the talkmap_link to true
  2. Create a dictionary for GitHub workflows: .github/workflows/
  3. In the directory, create the file scrape_talks.yml
  4. Open scrape_talks.yml and add the following:
name: Scrape Talk Locations
on:
  push:
    paths:
      - 'talks/**'
      - 'talkmap.ipynb'
jobs:
  build:
    runs-on: ubuntu-latest
    steps:
    - uses: actions/checkout@v2
    - name: Set up Python
      uses: actions/setup-python@v2
      with:
        python-version: '3.9'  # Specify the Python version you need
    - name: Install dependencies
      run: |
        pip install jupyter pandas requests beautifulsoup4 geopy  # Add other dependencies as needed
        pip install getorg --upgrade
    - name: Run Jupyter Notebook
      run: |
        jupyter nbconvert --to notebook --execute talkmap.ipynb --output talkmap_out.ipynb
    - name: Commit changes
      run: |
        git config user.name "github-actions[bot]"
        git config user.email "github-actions[bot]@users.noreply.github.com"
        git add .
        git commit -m "Automated update of talk locations" || echo "No changes to commit"
        git push
  1. Commit the changes, and push to GitHub

Once pushed, GitHub should detect the actions and run it automatically, thus updating your website.