genai blog post generator #214
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: genai blog post generator | |
permissions: | |
actions: read | |
contents: write | |
pull-requests: write | |
models: read | |
on: | |
workflow_dispatch: | |
schedule: | |
- cron: "0 0 * * *" | |
concurrency: | |
group: blog-post-${{ github.workflow }}-${{ github.ref }} | |
cancel-in-progress: true | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
submodules: "recursive" | |
fetch-depth: 10 | |
ref: dev | |
- uses: actions/setup-node@v4 | |
with: | |
node-version: "22" | |
cache: yarn | |
- run: yarn install --frozen-lockfile | |
- name: compile | |
run: yarn compile | |
- name: generate blog post | |
run: yarn genai:blog-post -p github --out-trace $GITHUB_STEP_SUMMARY | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
- uses: stefanzweifel/git-auto-commit-action@v5 | |
with: | |
file_pattern: "docs/src/content/docs/blog/drafts/*.md" | |
commit_message: "[genai] generated blog posts" | |
commit_user_name: "genaiscript" |