Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion .github/workflows/Lark-notification.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,10 @@ on:
jobs:
send-Lark-message:
runs-on: ubuntu-latest
# Secrets cannot be directly referenced in if: conditionals, so expose
# only the presence flag. The raw URL stays scoped to the action step.
env:
HAS_LARK_WEBHOOK: ${{ secrets.LARK_CHATBOT_HOOK_URL != '' }}
steps:
- uses: actions/checkout@v6

Expand All @@ -36,7 +40,8 @@ jobs:
} >> "$GITHUB_OUTPUT"

- name: Send message to Lark
if: ${{ contains(steps.message.outputs.content, ':') }}
# Fork PRs cannot access repository secrets, so skip instead of failing.
if: ${{ contains(steps.message.outputs.content, ':') && env.HAS_LARK_WEBHOOK == 'true' }}
uses: Open-Source-Bazaar/feishu-action@v3
with:
url: ${{ secrets.LARK_CHATBOT_HOOK_URL }}
Expand Down
Loading