Skip to content

Merge branch 'main' of github.com:sparkfun/sparkfun.github.io #25

Merge branch 'main' of github.com:sparkfun/sparkfun.github.io

Merge branch 'main' of github.com:sparkfun/sparkfun.github.io #25

Workflow file for this run

name: List of repos that contain SparkFun Getting Started Guines
on:
push:
branches:
- "main"
schedule:
# Daily at 8:20 UTC
- cron: '20 8 * * *'
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
# This workflow contains a single job called "build"
build-gsg-repos:
# The type of runner that the job will run on
runs-on: ubuntu-latest
permissions:
contents: write
# Steps represent a sequence of tasks that will be executed as part of the job
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v3
# Run our gh command to find repos - only finds public repos with the given tag
- name: gh command
run: |
gh search repos topic:sparkfun-tutorial --owner sparkfun --json name,url,homepage,description > gsg.json
- name: Check for updates
id: has_updates
run: |
git config --global user.name 'SparkFun Automated Action'
git config --global user.email '[email protected]'
git diff --exit-code gsg.json
continue-on-error: true
- name: Check-in gsg updates
if: steps.has_updates.outcome != 'success'
run: |
git add gsg.json
git commit -m "daily update"
git push