Sha256: dde25e7910d8001dbf9de6f2f26af6324cfe9a3c46a25ba39ea9a459e0d9dfa4

Contents?: true

Size: 588 Bytes

Versions: 26

Compression:

Stored size: 588 Bytes

Contents

Houston::Slack.config do
  overhear(/cve[\s:](?<number>\d+)\b/i) do |e|
    alert = Houston::Alerts::Alert.where(type: "cve", number: e.match[:number]).first
    e.unfurl slack_alert_attachment(alert)
  end

  overhear(/(?:err|exception)[\s:](?<number>\d+)\b/i) do |e|
    alert = Houston::Alerts::Alert.where(type: "err", number: e.match[:number]).first
    e.unfurl slack_alert_attachment(alert)
  end

  overhear(/alert (?<number>\d+)\b/i) do |e|
    Houston::Alerts::Alert.where(number: e.match[:number]).each do |alert|
      e.unfurl slack_alert_attachment(alert)
    end
  end
end

Version data entries

26 entries across 26 versions & 1 rubygems

Version Path
houston-core-0.5.6 templates/new-instance/config/conversations/mentions/unfurl_alerts.rb
houston-core-0.5.5 templates/new-instance/config/conversations/mentions/unfurl_alerts.rb
houston-core-0.5.4 templates/new-instance/config/conversations/mentions/unfurl_alerts.rb
houston-core-0.5.3 templates/new-instance/config/conversations/mentions/unfurl_alerts.rb
houston-core-0.5.2 templates/new-instance/config/conversations/mentions/unfurl_alerts.rb
houston-core-0.5.1 templates/new-instance/config/conversations/mentions/unfurl_alerts.rb