Skip to content

Update Quote

Update Quote #31

Workflow file for this run

name: Update Quote
on:
workflow_dispatch: #Manually trigger the workflow
schedule:
- cron: '30 6 * * *' # Schedule daily at 12:01 AM Indian Time
permissions:
contents: write
jobs:
update-readme:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: 20
- name: Update Quote
run: node update-quote.js
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Commit and push changes
run: |
git add README.md
if git diff --cached --quiet; then
echo "No changes to commit"
exit 0
fi
git -c user.name='github-actions[bot]' -c user.email='41898282+github-actions[bot]@users.noreply.github.com' commit -m "Update README with daily quote"
git push