Class: GitWebhook::Core

Inherits:
Object
  • Object
show all
Defined in:
lib/git-webhook/core.rb

Instance Method Summary collapse

Constructor Details

#initialize(old, new, ref, repository_path, options = {}) ⇒ Core

Returns a new instance of Core.



8
9
10
# File 'lib/git-webhook/core.rb', line 8

def initialize(old, new, ref, repository_path, options = {})
  @data_hash = GitWebhook::Builder.new(old, new, ref, repository_path, options).data_hash
end

Instance Method Details

#notify(url) ⇒ Object



12
13
14
15
# File 'lib/git-webhook/core.rb', line 12

def notify(url)
  notifier = GitWebhook::Notifier.new(@data_hash)
  notifier.notify(url)
end