No description
  • Python 74.1%
  • Makefile 20.6%
  • Dockerfile 5.3%
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
2026-11-16 00:13:53 +00:00
.forgejo feat: rewrite the action as a python package that posts a message with inline links 2026-10-08 15:05:24 -04:00
src/bluesky_post_action fix: exit 0 from the console script by discarding main's return value 2026-10-08 17:21:46 -04:00
tests fix: exit 0 from the console script by discarding main's return value 2026-10-08 17:21:46 -04:00
.coveragerc.toml feat: rewrite the action as a python package that posts a message with inline links 2026-10-08 15:05:24 -04:00
.dockerignore feat: rewrite the action as a python package that posts a message with inline links 2026-10-08 15:05:24 -04:00
.editorconfig feat: rewrite the action as a python package that posts a message with inline links 2026-10-08 15:05:24 -04:00
.env.example feat: rewrite the action as a python package that posts a message with inline links 2026-10-08 15:05:24 -04:00
.gitignore feat: rewrite the action as a python package that posts a message with inline links 2026-10-08 15:05:24 -04:00
.hadolint.yaml feat: rewrite the action as a python package that posts a message with inline links 2026-10-08 15:05:24 -04:00
.prettierignore feat: rewrite the action as a python package that posts a message with inline links 2026-10-08 15:05:24 -04:00
.python-version feat: rewrite the action as a python package that posts a message with inline links 2026-10-08 15:05:24 -04:00
action.yml feat: rewrite the action as a python package that posts a message with inline links 2026-10-08 15:05:24 -04:00
AGENTS.md fix: exit 0 from the console script by discarding main's return value 2026-10-08 17:21:46 -04:00
CLAUDE.md feat: rewrite the action as a python package that posts a message with inline links 2026-10-08 15:05:24 -04:00
Dockerfile fix: exit 0 from the console script by discarding main's return value 2026-10-08 17:21:46 -04:00
LICENSE feat: rewrite the action as a python package that posts a message with inline links 2026-10-08 15:05:24 -04:00
Makefile chore(make): remove ty's cache on clean 2026-10-08 17:31:02 -04:00
pyproject.toml fix: exit 0 from the console script by discarding main's return value 2026-10-08 17:21:46 -04:00
pytest.toml feat: rewrite the action as a python package that posts a message with inline links 2026-10-08 15:05:24 -04:00
README.md feat: rewrite the action as a python package that posts a message with inline links 2026-10-08 15:05:24 -04:00
ruff.toml feat: rewrite the action as a python package that posts a message with inline links 2026-10-08 15:05:24 -04:00
ty.toml feat: rewrite the action as a python package that posts a message with inline links 2026-10-08 15:05:24 -04:00
uv.lock build(deps): lock file maintenance (#11) 2026-11-16 00:13:53 +00:00

Bluesky Post

Forgejo Action that posts a message to Bluesky over the AT Protocol. Links written inline as |label|url| become clickable text in the published post.

Usage

name: Announce
on:
    push:
        branches: [main]

jobs:
    post:
        runs-on: docker
        steps:
            - name: Post to Bluesky
              uses: https://code.modernleft.org/ModernLeft/bluesky-post-action@main
              with:
                  handle: ${{ secrets.BLUESKY_HANDLE }}
                  app-password: ${{ secrets.BLUESKY_APP_PASSWORD }}
                  pds-host: https://bsky.social
                  message: >-
                      New commit on |bluesky-post-action|https://code.modernleft.org/ModernLeft/bluesky-post-action| ${{
                      github.sha }}

The action runs as a Docker container, so the job needs a runner that can build and run container actions. The container installs the published bluesky-post-action wheel from this repository's releases and runs it as its entrypoint.

Input Required Default Description
handle yes Bluesky handle of the posting account.
app-password yes App password for the account (use a repo secret, not your main password).
message yes Post text. Write a link as |label|url| and it becomes a clickable label.
pds-host no https://bsky.social Base URL of the PDS. Defaults to the main Bluesky PDS.

Every |label|url| in the message becomes a link whose visible text is the label. Neither the label nor the URL may contain |, and both must be non-empty. Text outside the markers is posted as plain text with no other formatting, so a bare URL stays unlinked. The label counts toward the post length, the URL does not.

Bluesky enforces a 300 grapheme limit per post. The action does not check length before sending, so an oversized message is rejected by the server and the step fails.

Setup

  1. Create an app password for the posting account in its Bluesky settings.
  2. Add BLUESKY_HANDLE and BLUESKY_APP_PASSWORD as repository secrets. Add BLUESKY_PDS_HOST as well if the account lives on a self-hosted PDS, and pass it to pds-host; otherwise omit pds-host to use https://bsky.social.
  3. Reference the action as in the snippet above.

On success the action prints the new post's at:// URI and CID to the job log. It declares no outputs, so later steps cannot read them. If the PDS rejects the credentials, the error is printed and the step exits with status 1. If the PDS rejects the post, for example because it is over the grapheme limit, the error is printed and the step exits with status 1 in the same way. Any other failure, such as an unreachable PDS, surfaces as an uncaught exception and also fails the step.