Skip to content

Instantly share code, notes, and snippets.

@planetoftheweb
Created June 16, 2021 20:22
Show Gist options
  • Save planetoftheweb/f0af75305f9d69f3f1997037eb932f26 to your computer and use it in GitHub Desktop.
Save planetoftheweb/f0af75305f9d69f3f1997037eb932f26 to your computer and use it in GitHub Desktop.
name: Favorite Google Fonts
on:
push:
branches: [main]
jobs:
build:
runs-on: ubuntu-latest
env:
google_api_key: ${{secrets.GOOGLE_API_KEY}}
steps:
- uses: actions/checkout@v2
- name: Get the Font List
run: |
git config --global user.name "${GITHUB_ACTOR}"
git config --global user.email "${INPUT_EMAIL}"
curl -s --url https://www.googleapis.com/webfonts/v1/webfonts?key=${{secrets.GOOGLE_API_KEY}} >> fontsList.json
git add -A && git commit -m "Updated Fonts List"
git push --set-upstream origin main
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment