2018-11-19 21:01:13 -05:00
|
|
|
# frozen_string_literal: true
|
|
|
|
|
2017-01-19 03:22:09 -05:00
|
|
|
module Gitlab
|
2017-05-31 01:50:53 -04:00
|
|
|
module SlashCommands
|
2017-01-19 03:22:09 -05:00
|
|
|
module Presenters
|
|
|
|
class Deploy < Presenters::Base
|
|
|
|
def present(from, to)
|
2017-07-28 04:56:50 -04:00
|
|
|
message = "Deployment started from #{from} to #{to}. " \
|
|
|
|
"[Follow its progress](#{resource_url})."
|
2017-01-10 13:43:58 -05:00
|
|
|
|
2017-01-19 03:22:09 -05:00
|
|
|
in_channel_response(text: message)
|
|
|
|
end
|
2017-01-10 13:43:58 -05:00
|
|
|
|
2017-07-28 04:56:50 -04:00
|
|
|
def action_not_found
|
2017-07-28 06:16:07 -04:00
|
|
|
ephemeral_response(text: "Couldn't find a deployment manual action.")
|
2017-01-19 03:22:09 -05:00
|
|
|
end
|
|
|
|
end
|
2017-01-10 13:43:58 -05:00
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|