Files
workflows/.gitea/actions/notify/action.yaml
2025-10-15 13:30:21 +03:00

43 lines
1.0 KiB
YAML
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

name: 'notify'
description: 'notify'
inputs:
result:
required: false
default: "failure"
type: string
name:
required: false
type: string
default: build
secrets:
required: false
type: string
runs:
using: 'composite'
runs-on: gpu
steps:
- name: Set icon
id: icon
shell: bash
run: |
case "${{ inputs.result }}" in
success) echo "ICON=✅" >> $GITHUB_ENV ;;
failure) echo "ICON=❌" >> $GITHUB_ENV ;;
canceled) echo "ICON=🤦" >> $GITHUB_ENV ;;
started) echo "ICON=⚠️" >> $GITHUB_ENV ;;
*) echo "ICON=" >> $GITHUB_ENV ;;
esac
- uses: dosymep/vk-teams-action@v1.0.0
with:
token: ${{ inputs.token }}
to: ${{ inputs.to }}
format: MarkdownV2
message: |
${{ github.repository }} [${{ inputs.name }}](${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_number }})
was ${{ inputs.result }} by ${{ github.event.sender.login }} ${{ env.ICON }}