Sha256: 1e61b95dc866cf9bd9e584821a26131f84b9b6c988c9d221ec47845445514658
Contents?: true
Size: 864 Bytes
Versions: 14
Compression:
Stored size: 864 Bytes
Contents
class EcoRake module Lib module Notify class Mailer < EcoRake::Lib::BaseTask option '-t', '--to EMAIL', String, 'Destination recipient', required: true option '-s', '--subject SUBJECT', String, 'Subject of the email', required: true option '-m', '--body MESSAGE', String, 'The message of the email', required: true option '-c', '--cc EMAIL', String, 'CCing someone else' option '-b', '--bcc EMAIL', String, 'BCCing someone else' def task(*_args) kargs = { to: options[:to], subject: options[:subject], body: options[:body] } kargs.merge!(cc: options[:cc]) if options[:cc] kargs.merge!(bcc: options[:bcc]) if options[:bcc] mailer.mail(**kargs) end end end end end
Version data entries
14 entries across 14 versions & 1 rubygems