mirror of
https://github.com/Moepchi/webspeak3.git
synced 2026-12-01 00:42:49 +08:00
Posts the first paragraph of the release notes plus the link. Notes with <!-- no-social --> are skipped; a manual run defaults to a dry run that only logs in and prints the post. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Hu2cuPLqpuKVfd9wWFFakU
40 lines
1.1 KiB
YAML
40 lines
1.1 KiB
YAML
name: Announce release
|
|
|
|
on:
|
|
release:
|
|
types: [published]
|
|
workflow_dispatch:
|
|
inputs:
|
|
tag:
|
|
description: Release tag to announce
|
|
required: true
|
|
dry_run:
|
|
description: Only log in and print the post, don't publish it
|
|
type: boolean
|
|
default: true
|
|
|
|
permissions:
|
|
contents: read
|
|
|
|
jobs:
|
|
bluesky:
|
|
name: Post to Bluesky
|
|
runs-on: ubuntu-latest
|
|
timeout-minutes: 5
|
|
|
|
steps:
|
|
- name: Check out repository
|
|
uses: actions/checkout@fbc6f3992d24b796d5a048ff273f7fcc4a7b6c09 # v5
|
|
|
|
- name: Post release
|
|
# Tag passed via env, never spliced into the script (user-controlled text).
|
|
env:
|
|
GH_TOKEN: ${{ github.token }}
|
|
TAG: ${{ github.event.release.tag_name || inputs.tag }}
|
|
DRY_RUN: ${{ inputs.dry_run && 'true' || 'false' }}
|
|
BLUESKY_HANDLE: moepchi.bsky.social
|
|
BLUESKY_APP_PASSWORD: ${{ secrets.BLUESKY_APP_PASSWORD }}
|
|
run: |
|
|
gh release view "$TAG" -R "$GITHUB_REPOSITORY" --json tagName,url,body \
|
|
| python3 .github/scripts/announce-release.py
|