github.com/goreleaser/goreleaser@v1.25.1/www/docs/customization/announce/slack.md (about)

     1  # Slack
     2  
     3  For it to work, you'll need to [create a new Incoming Webhook](https://api.slack.com/messaging/webhooks), and set some
     4  environment variables on your pipeline:
     5  
     6  - `SLACK_WEBHOOK`
     7  
     8  Then, you can add something like the following to your `.goreleaser.yaml` config:
     9  
    10  ```yaml
    11  # .goreleaser.yaml
    12  announce:
    13    slack:
    14      # Whether its enabled or not.
    15      enabled: true
    16  
    17      # Message template to use while publishing.
    18      #
    19      # Default: '{{ .ProjectName }} {{ .Tag }} is out! Check it out at {{ .ReleaseURL }}'
    20      # Templates: allowed
    21      message_template: 'Awesome project {{.Tag}} is out!'
    22  
    23      # The name of the channel that the user selected as a destination for webhook messages.
    24      channel: '#channel'
    25  
    26      # Set your Webhook's user name.
    27      username: ''
    28  
    29      # Emoji to use as the icon for this message. Overrides icon_url.
    30      icon_emoji: ''
    31  
    32      # URL to an image to use as the icon for this message.
    33      icon_url: ''
    34  
    35      # Blocks for advanced formatting, see: https://api.slack.com/messaging/webhooks#advanced_message_formatting
    36      # and https://api.slack.com/messaging/composing/layouts#adding-blocks.
    37      #
    38      # Attention: goreleaser doesn't check the full structure of the Slack API: please make sure that
    39      # your configuration for advanced message formatting abides by this API.
    40      #
    41      # Templates: allowed
    42      blocks: []
    43  
    44      # Attachments, see: https://api.slack.com/reference/messaging/attachments
    45      #
    46      # Attention: goreleaser doesn't check the full structure of the Slack API: please make sure that
    47      # your configuration for advanced message formatting abides by this API.
    48      #
    49      # Templates: allowed
    50      attachments: []
    51  ```
    52  
    53  !!! tip
    54      Learn more about the [name template engine](/customization/templates/).