Skip to content
Latchkey

Notify workflow (ueberdosis/tiptap)

The Notify workflow from ueberdosis/tiptap, explained and optimized by Latchkey.

B

CI health: B - good

Point runs-on at Latchkey and get job timeouts, SHA-pinned actions, self-healing for flaky steps, and up to 58% lower cost, applied automatically.

Grade your own workflow free or run it on Latchkey →
Source: ueberdosis/tiptap.github/workflows/notify.ymlLicense MITView source

What it does

This is the Notify workflow from the ueberdosis/tiptap repository, a real project running GitHub Actions. It is shown here with attribution under its MIT license.

Below, Latchkey shows a faster, safer version produced by its optimization engine.

The workflow

workflow (.yml)
name: Notify

on:
  release:
    types: [published]

jobs:
  discord_notify:
    name: Send release to Discord
    if: github.event_name == 'release'
    runs-on: ubuntu-latest
    permissions:
      contents: read
    steps:
      - name: Post release to Discord (tsickert/discord-webhook)
        uses: tsickert/discord-webhook@v7.0.0
        with:
          webhook-url: ${{ secrets.DISCORD_RELEASES_STABLE_WEBHOOK }}
          embed-title: ${{ github.event.release.name || github.event.release.tag_name }}
          embed-description: ${{ github.event.release.body }}
          embed-url: ${{ github.event.release.html_url }}
          wait: true

  slack_release_notify:
    name: Send release to Slack
    if: github.event_name == 'release'
    runs-on: ubuntu-latest
    permissions: {}
    steps:
      - name: Send Slack release notification
        uses: slackapi/slack-github-action@v3.0.3
        with:
          webhook: ${{ secrets.SLACK_WEBHOOK_URL }}
          webhook-type: webhook-trigger
          payload: |
            {
              "message": ${{ toJSON(format('[Tiptap Editor {0}]: {1}\nRelease title: {2}\n{3}', github.event.release.prerelease && 'Pre-release' || 'Release', github.event.release.name || github.event.release.tag_name, github.event.release.html_url, github.event.release.body || 'No release notes provided.')) }}
            }
        env:
          SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}

The same workflow, on Latchkey

Removes redundant runs and caps runaway jobs. Added and changed lines are highlighted.

name: Notify
 
on:
  release:
    types: [published]
 
jobs:
  discord_notify:
    timeout-minutes: 30
    name: Send release to Discord
    if: github.event_name == 'release'
    runs-on: latchkey-small
    permissions:
      contents: read
    steps:
      - name: Post release to Discord (tsickert/discord-webhook)
        uses: tsickert/discord-webhook@v7.0.0
        with:
          webhook-url: ${{ secrets.DISCORD_RELEASES_STABLE_WEBHOOK }}
          embed-title: ${{ github.event.release.name || github.event.release.tag_name }}
          embed-description: ${{ github.event.release.body }}
          embed-url: ${{ github.event.release.html_url }}
          wait: true
 
  slack_release_notify:
    timeout-minutes: 30
    name: Send release to Slack
    if: github.event_name == 'release'
    runs-on: latchkey-small
    permissions: {}
    steps:
      - name: Send Slack release notification
        uses: slackapi/slack-github-action@v3.0.3
        with:
          webhook: ${{ secrets.SLACK_WEBHOOK_URL }}
          webhook-type: webhook-trigger
          payload: |
            {
              "message": ${{ toJSON(format('[Tiptap Editor {0}]: {1}\nRelease title: {2}\n{3}', github.event.release.prerelease && 'Pre-release' || 'Release', github.event.release.name || github.event.release.tag_name, github.event.release.html_url, github.event.release.body || 'No release notes provided.')) }}
            }
        env:
          SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
 

What changed

2 third-party actions are referenced by a movable tag. Pin them to the commit SHA (Latchkey resolves and applies this automatically) so a repointed tag cannot change what runs.

This workflow runs 2 jobs per trigger. On Latchkey the same minutes cost up to 58% less than GitHub-hosted, with zero queue time.

Actions used in this workflow