Skip to content

Collect Bing.com daily images #1722

Collect Bing.com daily images

Collect Bing.com daily images #1722

Workflow file for this run

name: Collect Bing.com daily images
on:
schedule:
- cron: '0 1 * * *'
workflow_dispatch:
jobs:
# This workflow contains a single job called "build"
build:
# The type of runner that the job will run on
runs-on: ubuntu-latest
# 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@v4
- name: Download image and update README
run: |
bash generate_readme.sh
env:
OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }}
- name: Commit
run: |
git config user.name "github-actions[bot]"
git config user.email "41898282+github-actions[bot]@users.noreply.github.com"
git status
git add images/*.jpg README.md
if git diff-index --quiet HEAD --; then
echo "No changes to commit."
else
git commit -m "auto commit from github actions"
fi
- name: Push
uses: ad-m/github-push-action@master
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
branch: master