webmaster 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- data/.document +5 -0
- data/Gemfile +24 -0
- data/Gemfile.lock +85 -0
- data/LICENSE.txt +20 -0
- data/README.md +94 -0
- data/Rakefile +46 -0
- data/lib/webmaster.rb +66 -0
- data/lib/webmaster/api/authorization.rb +59 -0
- data/lib/webmaster/api/connection.rb +87 -0
- data/lib/webmaster/api/request.rb +62 -0
- data/lib/webmaster/base.rb +159 -0
- data/lib/webmaster/client.rb +15 -0
- data/lib/webmaster/configuration.rb +111 -0
- data/lib/webmaster/core_ext/hash.rb +87 -0
- data/lib/webmaster/core_ext/object.rb +9 -0
- data/lib/webmaster/core_ext/string.rb +9 -0
- data/lib/webmaster/errors.rb +21 -0
- data/lib/webmaster/host.rb +154 -0
- data/lib/webmaster/hosts/crawling.rb +24 -0
- data/lib/webmaster/hosts/verification.rb +77 -0
- data/lib/webmaster/request/oauth2.rb +26 -0
- data/lib/webmaster/response/hashify.rb +59 -0
- data/lib/webmaster/version.rb +12 -0
- data/test/helper.rb +18 -0
- data/test/test_webmaster.rb +7 -0
- data/webmaster.gemspec +196 -0
- metadata +796 -0
@@ -0,0 +1,21 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
|
3
|
+
module Webmaster
|
4
|
+
module Errors
|
5
|
+
class WebmasterError < StandardError
|
6
|
+
attr_reader :data
|
7
|
+
|
8
|
+
def initialize(data)
|
9
|
+
@data = data
|
10
|
+
super
|
11
|
+
end
|
12
|
+
end
|
13
|
+
|
14
|
+
class UnauthorizedError < WebmasterError; end
|
15
|
+
class GeneralError < WebmasterError; end
|
16
|
+
class AccessDeniedError < WebmasterError; end
|
17
|
+
class NoTokenError < WebmasterError; end
|
18
|
+
class NotFoundError < WebmasterError; end
|
19
|
+
class ResourceError < WebmasterError; end
|
20
|
+
end
|
21
|
+
end
|
@@ -0,0 +1,154 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
|
3
|
+
require 'forwardable'
|
4
|
+
|
5
|
+
module Webmaster
|
6
|
+
class Host < Base
|
7
|
+
extend Forwardable
|
8
|
+
include Virtus
|
9
|
+
|
10
|
+
attribute :href, String
|
11
|
+
attribute :name, String
|
12
|
+
attribute :virused, Boolean
|
13
|
+
attribute :last_access, DateTime
|
14
|
+
attribute :tcy, Integer
|
15
|
+
|
16
|
+
attribute :url_count, Integer
|
17
|
+
attribute :url_errors, Integer
|
18
|
+
|
19
|
+
attribute :index_count, Integer
|
20
|
+
attribute :last_week_index_urls, Array
|
21
|
+
|
22
|
+
attribute :internal_links_count, Integer
|
23
|
+
|
24
|
+
attribute :links_count, Integer
|
25
|
+
attribute :last_week_links, Array
|
26
|
+
|
27
|
+
attr_reader :crawling
|
28
|
+
|
29
|
+
delegate :verified? => :verification
|
30
|
+
|
31
|
+
# Id of the host
|
32
|
+
# @return [Integer]
|
33
|
+
#
|
34
|
+
def id
|
35
|
+
return @id if defined?(@id)
|
36
|
+
@id = self.href.match(/\/(\d+)\z/)[1].to_i
|
37
|
+
end
|
38
|
+
|
39
|
+
# Load information about resources that are available for the host
|
40
|
+
# @return [Hash]
|
41
|
+
#
|
42
|
+
def resources
|
43
|
+
return @resources if defined?(@resources)
|
44
|
+
|
45
|
+
@resources = self.fetch_value(self.request(:get, self.href), :link).inject({}) do |h, resource|
|
46
|
+
h[resource[:rel].underscore.to_sym] = resource[:href]; h
|
47
|
+
end
|
48
|
+
end
|
49
|
+
|
50
|
+
# Delete information about the host from Yandex.Market
|
51
|
+
# [RU] http://api.yandex.ru/webmaster/doc/dg/reference/hosts-delete.xml
|
52
|
+
# [EN] http://api.yandex.com/webmaster/doc/dg/reference/hosts-delete.xml
|
53
|
+
#
|
54
|
+
def delete
|
55
|
+
response = self.request(:delete, self.href)
|
56
|
+
# @deleted = true if response.status.to_i == 204
|
57
|
+
@deleted = true if response.status.to_i == 405
|
58
|
+
self
|
59
|
+
end
|
60
|
+
|
61
|
+
# @return [Boolean]
|
62
|
+
#
|
63
|
+
def deleted?
|
64
|
+
!!@deleted
|
65
|
+
end
|
66
|
+
|
67
|
+
# Load information about verification for the host
|
68
|
+
#
|
69
|
+
def verify(type)
|
70
|
+
self.validate_resource!(:verify_host)
|
71
|
+
|
72
|
+
status = self.verification.run(type)
|
73
|
+
@verification = nil
|
74
|
+
|
75
|
+
status
|
76
|
+
end
|
77
|
+
|
78
|
+
# Information about verification for the host
|
79
|
+
# @return [Webmaster::Hosts::Verification]
|
80
|
+
# [RU] http://api.yandex.ru/webmaster/doc/dg/reference/hosts-verify.xml
|
81
|
+
# [EN] http://api.yandex.com/webmaster/doc/dg/reference/hosts-verify.xml
|
82
|
+
def verification(reload = false)
|
83
|
+
@verification = nil if reload
|
84
|
+
|
85
|
+
if @verification.nil?
|
86
|
+
self.validate_resource!(:verify_host)
|
87
|
+
self.verification = self.fetch_value(self.request(:get, self.resources[:verify_host]), :verification)
|
88
|
+
end
|
89
|
+
|
90
|
+
@verification
|
91
|
+
end
|
92
|
+
|
93
|
+
# Load stats for the host
|
94
|
+
# @return [Webmaster::Host]
|
95
|
+
# [RU] http://api.yandex.ru/webmaster/doc/dg/reference/hosts-stats.xml
|
96
|
+
# [EN] http://api.yandex.com/webmaster/doc/dg/reference/hosts-stats.xml
|
97
|
+
#
|
98
|
+
def stats
|
99
|
+
self.validate_resource!(:host_information)
|
100
|
+
|
101
|
+
self.attributes = self.request(:get, self.resources[:host_information]).body
|
102
|
+
self
|
103
|
+
end
|
104
|
+
|
105
|
+
# Load information about indexed urls for the host
|
106
|
+
# @return [Webmaster::Host]
|
107
|
+
# [RU] http://api.yandex.ru/webmaster/doc/dg/reference/hosts-indexed.xml
|
108
|
+
# [EN] http://api.yandex.com/webmaster/doc/dg/reference/hosts-indexed.xml
|
109
|
+
#
|
110
|
+
def indexed_urls
|
111
|
+
self.validate_resource!(:indexed_urls)
|
112
|
+
|
113
|
+
self.attributes = self.request(:get, self.resources[:indexed_urls]).body
|
114
|
+
self
|
115
|
+
end
|
116
|
+
|
117
|
+
# Load information about incoming links for the host
|
118
|
+
# @return [Webmaster::Host]
|
119
|
+
# [RU] http://api.yandex.ru/webmaster/doc/dg/reference/host-links.xml
|
120
|
+
# [EN] http://api.yandex.com/webmaster/doc/dg/reference/host-links.xml
|
121
|
+
#
|
122
|
+
def incoming_links
|
123
|
+
self.validate_resource!(:incoming_links)
|
124
|
+
|
125
|
+
self.attributes = self.request(:get, self.resources[:incoming_links]).body
|
126
|
+
self
|
127
|
+
end
|
128
|
+
|
129
|
+
protected
|
130
|
+
|
131
|
+
def validate_resource!(resource)
|
132
|
+
unless self.resources.keys.include?(resource)
|
133
|
+
raise Webmaster::Errors::ResourceError.new("Resource '#{resource.to_s}' is not available for the host")
|
134
|
+
end
|
135
|
+
end
|
136
|
+
|
137
|
+
private
|
138
|
+
|
139
|
+
def verification=(value)
|
140
|
+
@verification = value.is_a?(Webmaster::Hosts::Verification) ? value : Webmaster::Hosts::Verification.new(value)
|
141
|
+
@verification.host = self
|
142
|
+
@verification.configuration = self.configuration
|
143
|
+
@verification
|
144
|
+
end
|
145
|
+
|
146
|
+
def crawling=(value)
|
147
|
+
@crawling = Webmaster::Hosts::Crawling.new(value)
|
148
|
+
@crawling.host = self
|
149
|
+
@crawling.configuration = self.configuration
|
150
|
+
@crawling
|
151
|
+
end
|
152
|
+
|
153
|
+
end
|
154
|
+
end
|
@@ -0,0 +1,24 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
|
3
|
+
module Webmaster
|
4
|
+
module Hosts
|
5
|
+
class Crawling < Base
|
6
|
+
include Virtus
|
7
|
+
|
8
|
+
STATES = [
|
9
|
+
'indexed',
|
10
|
+
'not_indexed',
|
11
|
+
'waiting'
|
12
|
+
].freeze
|
13
|
+
|
14
|
+
attribute :state, String
|
15
|
+
|
16
|
+
attr_accessor :host
|
17
|
+
|
18
|
+
def state=(value)
|
19
|
+
value = value.downcase.underscore
|
20
|
+
@state = value if STATES.include?(value)
|
21
|
+
end
|
22
|
+
end
|
23
|
+
end
|
24
|
+
end
|
@@ -0,0 +1,77 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
|
3
|
+
require 'xml/libxml'
|
4
|
+
|
5
|
+
module Webmaster
|
6
|
+
module Hosts
|
7
|
+
class Verification < Base
|
8
|
+
include Virtus
|
9
|
+
|
10
|
+
STATES = [
|
11
|
+
'in_progress',
|
12
|
+
'never_verified',
|
13
|
+
'verification_failed',
|
14
|
+
'verified',
|
15
|
+
'waiting'
|
16
|
+
].freeze
|
17
|
+
|
18
|
+
CHECKABLE_TYPES = [
|
19
|
+
'dns_record',
|
20
|
+
'html_file',
|
21
|
+
'meta_tag',
|
22
|
+
'txt_file',
|
23
|
+
'whois'
|
24
|
+
].freeze
|
25
|
+
|
26
|
+
NON_CHECKABLE_TYPES = [
|
27
|
+
'auto',
|
28
|
+
'manual',
|
29
|
+
'pdd',
|
30
|
+
'pdd_external',
|
31
|
+
'delegation'
|
32
|
+
].freeze
|
33
|
+
|
34
|
+
TYPES = (CHECKABLE_TYPES + NON_CHECKABLE_TYPES).flatten.freeze
|
35
|
+
|
36
|
+
attribute :state, String
|
37
|
+
attribute :type, String
|
38
|
+
|
39
|
+
attribute :possible_to_cancel, Boolean
|
40
|
+
attribute :date, Date
|
41
|
+
attribute :uin, String
|
42
|
+
|
43
|
+
attr_accessor :host
|
44
|
+
|
45
|
+
def initialize(attributes = {})
|
46
|
+
super(attributes)
|
47
|
+
|
48
|
+
self.state ||= 'never_verified'
|
49
|
+
end
|
50
|
+
|
51
|
+
# @return [Boolean]
|
52
|
+
#
|
53
|
+
def verified?
|
54
|
+
self.state == 'verified'
|
55
|
+
end
|
56
|
+
|
57
|
+
def run(type)
|
58
|
+
raise ArgumentError if !CHECKABLE_TYPES.include?(type.underscore.downcase)
|
59
|
+
|
60
|
+
# data = XML::Document.string("<host><type>#{type.underscore.upcase}</type></host>").to_s
|
61
|
+
data = "<host><type>#{type.underscore.upcase}</type></host>"
|
62
|
+
response = self.request(:put, self.host.resources[:verify_host], :data => data)
|
63
|
+
# return true if response.status.to_i == 204
|
64
|
+
end
|
65
|
+
|
66
|
+
def state=(value)
|
67
|
+
value = value.downcase.underscore
|
68
|
+
@state = value if STATES.include?(value)
|
69
|
+
end
|
70
|
+
|
71
|
+
def type=(value)
|
72
|
+
value = value.downcase.underscore
|
73
|
+
@type = value if TYPES.include?(value)
|
74
|
+
end
|
75
|
+
end
|
76
|
+
end
|
77
|
+
end
|
@@ -0,0 +1,26 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
|
3
|
+
require 'faraday'
|
4
|
+
|
5
|
+
module Webmaster
|
6
|
+
module Request
|
7
|
+
class OAuth2 < Faraday::Middleware
|
8
|
+
|
9
|
+
AUTH_HEADER = 'Authorization'.freeze
|
10
|
+
|
11
|
+
dependency 'oauth2'
|
12
|
+
|
13
|
+
def call(env)
|
14
|
+
env[:request_headers].merge!(AUTH_HEADER => "OAuth #{@token}") if @token.present?
|
15
|
+
|
16
|
+
@app.call env
|
17
|
+
end
|
18
|
+
|
19
|
+
def initialize(app, *args)
|
20
|
+
super app
|
21
|
+
@app = app
|
22
|
+
@token = args.shift
|
23
|
+
end
|
24
|
+
end
|
25
|
+
end
|
26
|
+
end
|
@@ -0,0 +1,59 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
|
3
|
+
require 'faraday'
|
4
|
+
require 'xml/libxml'
|
5
|
+
|
6
|
+
module Webmaster
|
7
|
+
class Response::Hashify < Faraday::Response::Middleware
|
8
|
+
def parse(body)
|
9
|
+
self.from_xml(body) if body.present?
|
10
|
+
end
|
11
|
+
|
12
|
+
def from_xml(xml, strict = true)
|
13
|
+
begin
|
14
|
+
XML.default_load_external_dtd = false
|
15
|
+
XML.default_pedantic_parser = strict
|
16
|
+
result = XML::Parser.string(xml).parse
|
17
|
+
return xml_node_to_hash(result.root)
|
18
|
+
rescue Exception => e
|
19
|
+
# raise custom exception here
|
20
|
+
end
|
21
|
+
end
|
22
|
+
|
23
|
+
def xml_node_to_hash(node)
|
24
|
+
if node.element?
|
25
|
+
if node.children? || node.attributes?
|
26
|
+
result_hash = {}
|
27
|
+
|
28
|
+
node.each_child do |child|
|
29
|
+
result = xml_node_to_hash(child)
|
30
|
+
|
31
|
+
if child.name == "text"
|
32
|
+
if !child.next? and !child.prev?
|
33
|
+
return result
|
34
|
+
end
|
35
|
+
elsif result_hash[child.name.underscore.to_sym]
|
36
|
+
if result_hash[child.name.underscore.to_sym].is_a?(Object::Array)
|
37
|
+
result_hash[child.name.underscore.to_sym] << result
|
38
|
+
else
|
39
|
+
result_hash[child.name.underscore.to_sym] = [result_hash[child.name.to_sym]] << result
|
40
|
+
end
|
41
|
+
else
|
42
|
+
result_hash[child.name.underscore.to_sym] = result
|
43
|
+
end
|
44
|
+
end
|
45
|
+
|
46
|
+
node.each_attr do |attr|
|
47
|
+
result_hash[attr.name.underscore.to_sym] = attr.value
|
48
|
+
end
|
49
|
+
|
50
|
+
return result_hash
|
51
|
+
else
|
52
|
+
return nil
|
53
|
+
end
|
54
|
+
else
|
55
|
+
return node.content.to_s
|
56
|
+
end
|
57
|
+
end
|
58
|
+
end
|
59
|
+
end
|
data/test/helper.rb
ADDED
@@ -0,0 +1,18 @@
|
|
1
|
+
require 'rubygems'
|
2
|
+
require 'bundler'
|
3
|
+
begin
|
4
|
+
Bundler.setup(:default, :development)
|
5
|
+
rescue Bundler::BundlerError => e
|
6
|
+
$stderr.puts e.message
|
7
|
+
$stderr.puts "Run `bundle install` to install missing gems"
|
8
|
+
exit e.status_code
|
9
|
+
end
|
10
|
+
require 'test/unit'
|
11
|
+
require 'shoulda'
|
12
|
+
|
13
|
+
$LOAD_PATH.unshift(File.join(File.dirname(__FILE__), '..', 'lib'))
|
14
|
+
$LOAD_PATH.unshift(File.dirname(__FILE__))
|
15
|
+
require 'webmaster'
|
16
|
+
|
17
|
+
class Test::Unit::TestCase
|
18
|
+
end
|
data/webmaster.gemspec
ADDED
@@ -0,0 +1,196 @@
|
|
1
|
+
# Generated by jeweler
|
2
|
+
# DO NOT EDIT THIS FILE DIRECTLY
|
3
|
+
# Instead, edit Jeweler::Tasks in Rakefile, and run 'rake gemspec'
|
4
|
+
# -*- encoding: utf-8 -*-
|
5
|
+
|
6
|
+
Gem::Specification.new do |s|
|
7
|
+
s.name = "webmaster"
|
8
|
+
s.version = "0.1.0"
|
9
|
+
|
10
|
+
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
|
+
s.authors = ["Igor Alexandrov"]
|
12
|
+
s.date = "2013-04-29"
|
13
|
+
s.email = "igor.alexandrov@gmail.com"
|
14
|
+
s.extra_rdoc_files = [
|
15
|
+
"LICENSE.txt",
|
16
|
+
"README.md"
|
17
|
+
]
|
18
|
+
s.files = [
|
19
|
+
".document",
|
20
|
+
"Gemfile",
|
21
|
+
"Gemfile.lock",
|
22
|
+
"LICENSE.txt",
|
23
|
+
"README.md",
|
24
|
+
"Rakefile",
|
25
|
+
"lib/webmaster.rb",
|
26
|
+
"lib/webmaster/api/authorization.rb",
|
27
|
+
"lib/webmaster/api/connection.rb",
|
28
|
+
"lib/webmaster/api/request.rb",
|
29
|
+
"lib/webmaster/base.rb",
|
30
|
+
"lib/webmaster/client.rb",
|
31
|
+
"lib/webmaster/configuration.rb",
|
32
|
+
"lib/webmaster/core_ext/hash.rb",
|
33
|
+
"lib/webmaster/core_ext/object.rb",
|
34
|
+
"lib/webmaster/core_ext/string.rb",
|
35
|
+
"lib/webmaster/errors.rb",
|
36
|
+
"lib/webmaster/host.rb",
|
37
|
+
"lib/webmaster/hosts/crawling.rb",
|
38
|
+
"lib/webmaster/hosts/verification.rb",
|
39
|
+
"lib/webmaster/request/oauth2.rb",
|
40
|
+
"lib/webmaster/response/hashify.rb",
|
41
|
+
"lib/webmaster/version.rb",
|
42
|
+
"test/helper.rb",
|
43
|
+
"test/test_webmaster.rb",
|
44
|
+
"webmaster.gemspec"
|
45
|
+
]
|
46
|
+
s.homepage = "http://github.com/igor-alexandrov/webmaster"
|
47
|
+
s.licenses = ["MIT"]
|
48
|
+
s.require_paths = ["lib"]
|
49
|
+
s.rubygems_version = "1.8.24"
|
50
|
+
s.summary = "Ruby wrapper for Yandex.Webmaster API"
|
51
|
+
|
52
|
+
if s.respond_to? :specification_version then
|
53
|
+
s.specification_version = 3
|
54
|
+
|
55
|
+
if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then
|
56
|
+
s.add_runtime_dependency(%q<faraday>, [">= 0"])
|
57
|
+
s.add_runtime_dependency(%q<oauth2>, [">= 0"])
|
58
|
+
s.add_runtime_dependency(%q<libxml-ruby>, [">= 0"])
|
59
|
+
s.add_runtime_dependency(%q<virtus>, [">= 0"])
|
60
|
+
s.add_runtime_dependency(%q<webmaster>, [">= 0"])
|
61
|
+
s.add_development_dependency(%q<shoulda>, [">= 0"])
|
62
|
+
s.add_development_dependency(%q<rdoc>, [">= 0"])
|
63
|
+
s.add_development_dependency(%q<bundler>, [">= 0"])
|
64
|
+
s.add_development_dependency(%q<jeweler>, [">= 0"])
|
65
|
+
s.add_development_dependency(%q<shoulda>, [">= 0"])
|
66
|
+
s.add_development_dependency(%q<rdoc>, [">= 0"])
|
67
|
+
s.add_development_dependency(%q<bundler>, [">= 0"])
|
68
|
+
s.add_development_dependency(%q<jeweler>, [">= 0"])
|
69
|
+
s.add_development_dependency(%q<shoulda>, [">= 0"])
|
70
|
+
s.add_development_dependency(%q<rdoc>, [">= 0"])
|
71
|
+
s.add_development_dependency(%q<bundler>, [">= 0"])
|
72
|
+
s.add_development_dependency(%q<jeweler>, [">= 0"])
|
73
|
+
s.add_development_dependency(%q<shoulda>, [">= 0"])
|
74
|
+
s.add_development_dependency(%q<rdoc>, [">= 0"])
|
75
|
+
s.add_development_dependency(%q<bundler>, [">= 0"])
|
76
|
+
s.add_development_dependency(%q<jeweler>, [">= 0"])
|
77
|
+
s.add_development_dependency(%q<shoulda>, [">= 0"])
|
78
|
+
s.add_development_dependency(%q<rdoc>, [">= 0"])
|
79
|
+
s.add_development_dependency(%q<bundler>, [">= 0"])
|
80
|
+
s.add_development_dependency(%q<jeweler>, [">= 0"])
|
81
|
+
s.add_development_dependency(%q<shoulda>, [">= 0"])
|
82
|
+
s.add_development_dependency(%q<rdoc>, [">= 0"])
|
83
|
+
s.add_development_dependency(%q<bundler>, [">= 0"])
|
84
|
+
s.add_development_dependency(%q<jeweler>, [">= 0"])
|
85
|
+
s.add_development_dependency(%q<shoulda>, [">= 0"])
|
86
|
+
s.add_development_dependency(%q<rdoc>, [">= 0"])
|
87
|
+
s.add_development_dependency(%q<bundler>, [">= 0"])
|
88
|
+
s.add_development_dependency(%q<jeweler>, [">= 0"])
|
89
|
+
s.add_development_dependency(%q<shoulda>, [">= 0"])
|
90
|
+
s.add_development_dependency(%q<rdoc>, [">= 0"])
|
91
|
+
s.add_development_dependency(%q<bundler>, [">= 0"])
|
92
|
+
s.add_development_dependency(%q<jeweler>, [">= 0"])
|
93
|
+
s.add_development_dependency(%q<shoulda>, [">= 0"])
|
94
|
+
s.add_development_dependency(%q<rdoc>, [">= 0"])
|
95
|
+
s.add_development_dependency(%q<bundler>, [">= 0"])
|
96
|
+
s.add_development_dependency(%q<jeweler>, [">= 0"])
|
97
|
+
s.add_development_dependency(%q<shoulda>, [">= 0"])
|
98
|
+
s.add_development_dependency(%q<rdoc>, [">= 0"])
|
99
|
+
s.add_development_dependency(%q<bundler>, [">= 0"])
|
100
|
+
s.add_development_dependency(%q<jeweler>, [">= 0"])
|
101
|
+
else
|
102
|
+
s.add_dependency(%q<faraday>, [">= 0"])
|
103
|
+
s.add_dependency(%q<oauth2>, [">= 0"])
|
104
|
+
s.add_dependency(%q<libxml-ruby>, [">= 0"])
|
105
|
+
s.add_dependency(%q<virtus>, [">= 0"])
|
106
|
+
s.add_dependency(%q<webmaster>, [">= 0"])
|
107
|
+
s.add_dependency(%q<shoulda>, [">= 0"])
|
108
|
+
s.add_dependency(%q<rdoc>, [">= 0"])
|
109
|
+
s.add_dependency(%q<bundler>, [">= 0"])
|
110
|
+
s.add_dependency(%q<jeweler>, [">= 0"])
|
111
|
+
s.add_dependency(%q<shoulda>, [">= 0"])
|
112
|
+
s.add_dependency(%q<rdoc>, [">= 0"])
|
113
|
+
s.add_dependency(%q<bundler>, [">= 0"])
|
114
|
+
s.add_dependency(%q<jeweler>, [">= 0"])
|
115
|
+
s.add_dependency(%q<shoulda>, [">= 0"])
|
116
|
+
s.add_dependency(%q<rdoc>, [">= 0"])
|
117
|
+
s.add_dependency(%q<bundler>, [">= 0"])
|
118
|
+
s.add_dependency(%q<jeweler>, [">= 0"])
|
119
|
+
s.add_dependency(%q<shoulda>, [">= 0"])
|
120
|
+
s.add_dependency(%q<rdoc>, [">= 0"])
|
121
|
+
s.add_dependency(%q<bundler>, [">= 0"])
|
122
|
+
s.add_dependency(%q<jeweler>, [">= 0"])
|
123
|
+
s.add_dependency(%q<shoulda>, [">= 0"])
|
124
|
+
s.add_dependency(%q<rdoc>, [">= 0"])
|
125
|
+
s.add_dependency(%q<bundler>, [">= 0"])
|
126
|
+
s.add_dependency(%q<jeweler>, [">= 0"])
|
127
|
+
s.add_dependency(%q<shoulda>, [">= 0"])
|
128
|
+
s.add_dependency(%q<rdoc>, [">= 0"])
|
129
|
+
s.add_dependency(%q<bundler>, [">= 0"])
|
130
|
+
s.add_dependency(%q<jeweler>, [">= 0"])
|
131
|
+
s.add_dependency(%q<shoulda>, [">= 0"])
|
132
|
+
s.add_dependency(%q<rdoc>, [">= 0"])
|
133
|
+
s.add_dependency(%q<bundler>, [">= 0"])
|
134
|
+
s.add_dependency(%q<jeweler>, [">= 0"])
|
135
|
+
s.add_dependency(%q<shoulda>, [">= 0"])
|
136
|
+
s.add_dependency(%q<rdoc>, [">= 0"])
|
137
|
+
s.add_dependency(%q<bundler>, [">= 0"])
|
138
|
+
s.add_dependency(%q<jeweler>, [">= 0"])
|
139
|
+
s.add_dependency(%q<shoulda>, [">= 0"])
|
140
|
+
s.add_dependency(%q<rdoc>, [">= 0"])
|
141
|
+
s.add_dependency(%q<bundler>, [">= 0"])
|
142
|
+
s.add_dependency(%q<jeweler>, [">= 0"])
|
143
|
+
s.add_dependency(%q<shoulda>, [">= 0"])
|
144
|
+
s.add_dependency(%q<rdoc>, [">= 0"])
|
145
|
+
s.add_dependency(%q<bundler>, [">= 0"])
|
146
|
+
s.add_dependency(%q<jeweler>, [">= 0"])
|
147
|
+
end
|
148
|
+
else
|
149
|
+
s.add_dependency(%q<faraday>, [">= 0"])
|
150
|
+
s.add_dependency(%q<oauth2>, [">= 0"])
|
151
|
+
s.add_dependency(%q<libxml-ruby>, [">= 0"])
|
152
|
+
s.add_dependency(%q<virtus>, [">= 0"])
|
153
|
+
s.add_dependency(%q<webmaster>, [">= 0"])
|
154
|
+
s.add_dependency(%q<shoulda>, [">= 0"])
|
155
|
+
s.add_dependency(%q<rdoc>, [">= 0"])
|
156
|
+
s.add_dependency(%q<bundler>, [">= 0"])
|
157
|
+
s.add_dependency(%q<jeweler>, [">= 0"])
|
158
|
+
s.add_dependency(%q<shoulda>, [">= 0"])
|
159
|
+
s.add_dependency(%q<rdoc>, [">= 0"])
|
160
|
+
s.add_dependency(%q<bundler>, [">= 0"])
|
161
|
+
s.add_dependency(%q<jeweler>, [">= 0"])
|
162
|
+
s.add_dependency(%q<shoulda>, [">= 0"])
|
163
|
+
s.add_dependency(%q<rdoc>, [">= 0"])
|
164
|
+
s.add_dependency(%q<bundler>, [">= 0"])
|
165
|
+
s.add_dependency(%q<jeweler>, [">= 0"])
|
166
|
+
s.add_dependency(%q<shoulda>, [">= 0"])
|
167
|
+
s.add_dependency(%q<rdoc>, [">= 0"])
|
168
|
+
s.add_dependency(%q<bundler>, [">= 0"])
|
169
|
+
s.add_dependency(%q<jeweler>, [">= 0"])
|
170
|
+
s.add_dependency(%q<shoulda>, [">= 0"])
|
171
|
+
s.add_dependency(%q<rdoc>, [">= 0"])
|
172
|
+
s.add_dependency(%q<bundler>, [">= 0"])
|
173
|
+
s.add_dependency(%q<jeweler>, [">= 0"])
|
174
|
+
s.add_dependency(%q<shoulda>, [">= 0"])
|
175
|
+
s.add_dependency(%q<rdoc>, [">= 0"])
|
176
|
+
s.add_dependency(%q<bundler>, [">= 0"])
|
177
|
+
s.add_dependency(%q<jeweler>, [">= 0"])
|
178
|
+
s.add_dependency(%q<shoulda>, [">= 0"])
|
179
|
+
s.add_dependency(%q<rdoc>, [">= 0"])
|
180
|
+
s.add_dependency(%q<bundler>, [">= 0"])
|
181
|
+
s.add_dependency(%q<jeweler>, [">= 0"])
|
182
|
+
s.add_dependency(%q<shoulda>, [">= 0"])
|
183
|
+
s.add_dependency(%q<rdoc>, [">= 0"])
|
184
|
+
s.add_dependency(%q<bundler>, [">= 0"])
|
185
|
+
s.add_dependency(%q<jeweler>, [">= 0"])
|
186
|
+
s.add_dependency(%q<shoulda>, [">= 0"])
|
187
|
+
s.add_dependency(%q<rdoc>, [">= 0"])
|
188
|
+
s.add_dependency(%q<bundler>, [">= 0"])
|
189
|
+
s.add_dependency(%q<jeweler>, [">= 0"])
|
190
|
+
s.add_dependency(%q<shoulda>, [">= 0"])
|
191
|
+
s.add_dependency(%q<rdoc>, [">= 0"])
|
192
|
+
s.add_dependency(%q<bundler>, [">= 0"])
|
193
|
+
s.add_dependency(%q<jeweler>, [">= 0"])
|
194
|
+
end
|
195
|
+
end
|
196
|
+
|