lolz/.github/workflows/fetch-now.yml

33 lines
926 B
YAML
Raw Normal View History

2024-03-06 20:01:17 -06:00
name: Fetch Now Page
on:
schedule:
- cron: "* */4 * * *"
workflow_dispatch:
defaults:
run:
shell: bash
jobs:
2024-03-06 20:13:31 -06:00
fetch-now-page:
2024-03-06 20:01:17 -06:00
runs-on: ubuntu-latest
2024-03-06 20:13:31 -06:00
permissions:
contents: write
2024-03-06 20:01:17 -06:00
steps:
- name: Checkout
2024-06-28 20:26:43 -05:00
uses: actions/checkout@v4
2024-03-06 20:01:17 -06:00
- name: Fetch Now Page
run: |
curl --location --header "Authorization: Bearer ${{ secrets.OMG_TOKEN }}" \
"https://api.omg.lol/address/${{ secrets.OMG_ADDR }}/now" | \
jq -r .response.now.content > now.md
- name: Commit Now Page
2024-06-28 20:26:43 -05:00
uses: stefanzweifel/git-auto-commit-action@v5
2024-03-06 20:13:31 -06:00
with:
commit_message: 'fetch /now page'
2024-08-13 16:33:24 -05:00
commit_author: 'github-actions[bot] <github-actions[bot]@users.noreply.github.com>'
commit_user_email: 'github-actions[bot]@users.noreply.github.com'
commit_user_name: 'github-actions[bot]'
2024-03-06 20:13:31 -06:00
file_pattern: 'now.md'