Class: OmgPullRequest::Storage::Gist

Inherits:
Object
  • Object
show all
Defined in:
lib/omg_pull_request/storage/gist.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(attributes = {}) ⇒ Gist

Returns a new instance of Gist.



6
7
8
9
10
# File 'lib/omg_pull_request/storage/gist.rb', line 6

def initialize(attributes={})
  attributes.each do |attr, value|
    self.send("#{attr}=", value)
  end
end

Instance Attribute Details

#configurationObject

Returns the value of attribute configuration.



4
5
6
# File 'lib/omg_pull_request/storage/gist.rb', line 4

def configuration
  @configuration
end

#github_wrapperObject

Returns the value of attribute github_wrapper.



4
5
6
# File 'lib/omg_pull_request/storage/gist.rb', line 4

def github_wrapper
  @github_wrapper
end

Instance Method Details

#store(data, file_name) ⇒ Object

TODO test



13
14
15
# File 'lib/omg_pull_request/storage/gist.rb', line 13

def store(data, file_name)
  self.github_wrapper.make_gist(data.string, file_name)
end