cloudfoundry-community / slack-notification-resource

Concourse CI resource for sending notifications to Slack.
MIT License
75 stars 82 forks source link

Interpolate the 'text' field in attachments. #27

Closed jhunt closed 7 years ago

jhunt commented 7 years ago

Fixes #25.

The gist of this change is to iterate over the attachments, pulling out the text' field and eval/printfing it, and then merging them back together using jq's*' operator. This may not be the right way to do this. This may not be the best way to do this, but it does seem to work, and that's got to count for something.

@dennisjbell / @geofffranks your jq-fu is most appreciated in a review of this PR...

analytically commented 7 years ago

Can we get this merged?

jhunt commented 7 years ago

Does it work for you @analytically ?

leeola commented 7 years ago

Ran into #25 this morning.

Your changes are confirmed working here, ty!

jhunt commented 7 years ago

Works for me!