def initialize
super 'webhook', "Register a webhook that will be called any time a gem is updated on Gemcutter."
option_text = "The URL of the webhook to"
add_option('-a', '--add URL', "#{option_text} add") do |value, options|
options[:send] = 'add'
options[:url] = value
end
add_option('-r', '--remove URL', "#{option_text} remove") do |value, options|
options[:send] = 'remove'
options[:url] = value
end
add_option('-f', '--fire URL', "#{option_text} testfire") do |value, options|
options[:send] = 'fire'
options[:url] = value
end
add_option('-g', '--global', "Apply hook globally") do |value, options|
options[:global] = true
end
add_proxy_option
end