Class: FIR::Util::Publisher
- Includes:
- FIR::Util
- Defined in:
- lib/fir/util/publisher.rb
Instance Attribute Summary collapse
-
#args ⇒ Object
Returns the value of attribute args.
-
#options ⇒ Object
Returns the value of attribute options.
Instance Method Summary collapse
-
#initialize(args, options) ⇒ Publisher
constructor
A new instance of Publisher.
Methods included from ActiveSupport::Concern
#append_features, #class_methods, extended, #included
Constructor Details
#initialize(args, options) ⇒ Publisher
Returns a new instance of Publisher.
10 11 12 13 14 15 16 17 18 19 |
# File 'lib/fir/util/publisher.rb', line 10 def initialize(args, ) @file_path = File.absolute_path(args.first.to_s) @file_type = File.extname(@file_path).delete('.') @token = [:token] || current_token @changelog = read_changelog([:changelog]).to_s.to_utf8 @short = [:short].to_s @passwd = [:password].to_s @is_opened = @passwd.blank? ? [:open] : false @export_qrcode = !![:qrcode] end |