gicodewarrior-gattica 0.5.1 → 0.5.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 5f5f37f5bfbdeb0cfb588cf18dc37b8e47a4495e
4
- data.tar.gz: fb30cc83bb8521cbe300503491ff7a0729bec7b4
3
+ metadata.gz: ae5cc9615e34f43de2d081b800305c8a6f6d9747
4
+ data.tar.gz: faa877e6ec18d7a67291f3592bec5fa506807f12
5
5
  SHA512:
6
- metadata.gz: 2c7f39fe99b62eaa98a9d56fd7a43226491f97d8b8aa02d83382d1734e602b26319df6764cb379b2c9432b5dcafacc90c3b359531a11a6714f4041770bc30925
7
- data.tar.gz: 1213b44814f7adb702fc6d749c943bf6247be63b268481bb03ff380b34bfba8cb5bdff7d651d7d432d2536fa152bdc9dc76051b7c755596533a923f4278ac37b
6
+ metadata.gz: 59a182cc7efe05067361d35f0390907d84bce6d1b13cca832064db1ad463d4c05c9e20b259392fd902c035eefef014feec832e9651eef448e10c50c5bd6c35ad
7
+ data.tar.gz: 012343087b1d9c2322960f40876ab32c8e076d402c006dda514b4e8b3cd3a41ee3a2083c4778de8200ce3caade7e0cd5a6cc99a907743bf73e29d6864373573b
@@ -0,0 +1,4 @@
1
+ *.gem
2
+ github-test.rb
3
+ examples/active_example.rb
4
+ examples/.DS_Store
@@ -1,5 +1,4 @@
1
- ---
2
- :major: 0
1
+ ---
3
2
  :minor: 4
4
- :patch: 2
5
- :build:
3
+ :patch: 1
4
+ :major: 0
@@ -1,59 +1,71 @@
1
1
  # Generated by jeweler
2
2
  # DO NOT EDIT THIS FILE DIRECTLY
3
- # Instead, edit Jeweler::Tasks in Rakefile, and run 'rake gemspec'
3
+ # Instead, edit Jeweler::Tasks in Rakefile, and run the gemspec command
4
4
  # -*- encoding: utf-8 -*-
5
5
 
6
6
  Gem::Specification.new do |s|
7
- s.name = "gicodewarrior-gattica"
8
- s.version = "0.5.1"
7
+ s.name = %q{gicodewarrior-gattica}
8
+ s.version = "0.5.2"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["The Active Network"]
12
- s.date = "2013-04-04"
13
- s.description = "Gattica is a Ruby library for extracting data from the Google Analytics API."
14
- s.email = "rob.cameron@active.com"
12
+ s.date = %q{2011-11-01}
13
+ s.description = %q{Gattica is a Ruby library for extracting data from the Google Analytics API.}
14
+ s.email = %q{rob.cameron@active.com}
15
15
  s.extra_rdoc_files = [
16
16
  "LICENSE",
17
- "README.rdoc"
17
+ "README.rdoc"
18
18
  ]
19
19
  s.files = [
20
- "History.txt",
21
- "LICENSE",
22
- "README.rdoc",
23
- "Rakefile",
24
- "VERSION.yml",
25
- "examples/example.rb",
26
- "gattica.gemspec",
27
- "lib/gattica.rb",
28
- "lib/gattica/account.rb",
29
- "lib/gattica/auth.rb",
30
- "lib/gattica/convertible.rb",
31
- "lib/gattica/data_point.rb",
32
- "lib/gattica/data_set.rb",
33
- "lib/gattica/exceptions.rb",
34
- "lib/gattica/user.rb",
35
- "test/helper.rb",
36
- "test/suite.rb",
37
- "test/test_auth.rb",
38
- "test/test_engine.rb",
39
- "test/test_gattica.rb",
40
- "test/test_user.rb"
20
+ ".gitignore",
21
+ "History.txt",
22
+ "LICENSE",
23
+ "README.rdoc",
24
+ "Rakefile",
25
+ "VERSION.yml",
26
+ "examples/example.rb",
27
+ "gattica.gemspec",
28
+ "lib/gattica.rb",
29
+ "lib/gattica/account.rb",
30
+ "lib/gattica/auth.rb",
31
+ "lib/gattica/convertible.rb",
32
+ "lib/gattica/data_point.rb",
33
+ "lib/gattica/data_set.rb",
34
+ "lib/gattica/exceptions.rb",
35
+ "lib/gattica/user.rb",
36
+ "test/helper.rb",
37
+ "test/suite.rb",
38
+ "test/test_auth.rb",
39
+ "test/test_engine.rb",
40
+ "test/test_gattica.rb",
41
+ "test/test_user.rb"
41
42
  ]
42
- s.homepage = "http://github.com/activenetwork/gattica"
43
+ s.homepage = %q{http://github.com/activenetwork/gattica}
44
+ s.rdoc_options = ["--charset=UTF-8"]
43
45
  s.require_paths = ["lib"]
44
- s.rubygems_version = "2.0.3"
45
- s.summary = "Gattica is a Ruby library for extracting data from the Google Analytics API."
46
+ s.rubygems_version = %q{1.3.7}
47
+ s.summary = %q{Gattica is a Ruby library for extracting data from the Google Analytics API.}
48
+ s.test_files = [
49
+ "test/test_auth.rb",
50
+ "test/helper.rb",
51
+ "test/test_user.rb",
52
+ "test/test_engine.rb",
53
+ "test/suite.rb",
54
+ "test/test_gattica.rb",
55
+ "examples/example.rb"
56
+ ]
46
57
 
47
58
  if s.respond_to? :specification_version then
48
- s.specification_version = 4
59
+ current_version = Gem::Specification::CURRENT_SPECIFICATION_VERSION
60
+ s.specification_version = 3
49
61
 
50
62
  if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then
51
- s.add_runtime_dependency(%q<nokogiri>, ["< 1.6", ">= 1.4.0"])
63
+ s.add_runtime_dependency(%q<nokogiri>, [">= 1.4.0", "< 1.6"])
52
64
  else
53
- s.add_dependency(%q<nokogiri>, ["< 1.6", ">= 1.4.0"])
65
+ s.add_dependency(%q<nokogiri>, [">= 1.4.0", "< 1.6"])
54
66
  end
55
67
  else
56
- s.add_dependency(%q<nokogiri>, ["< 1.6", ">= 1.4.0"])
68
+ s.add_dependency(%q<nokogiri>, [">= 1.4.0", "< 1.6"])
57
69
  end
58
70
  end
59
71
 
@@ -11,7 +11,7 @@ require 'nokogiri'
11
11
  require 'yaml'
12
12
 
13
13
  module Gattica
14
- VERSION = '0.4.2'
14
+ VERSION = '0.4.0'
15
15
  end
16
16
 
17
17
  # internal
@@ -239,7 +239,7 @@ module Gattica
239
239
  # sure it's valid and not an error
240
240
 
241
241
  def do_http_get(query_string)
242
- response, data = @http.get(query_string, @headers)
242
+ response = @http.get(query_string, @headers)
243
243
 
244
244
  # error checking
245
245
  if response.code != '200'
@@ -253,7 +253,7 @@ module Gattica
253
253
  end
254
254
  end
255
255
 
256
- return data
256
+ return response.body
257
257
  end
258
258
 
259
259
  private
@@ -317,7 +317,7 @@ module Gattica
317
317
 
318
318
  # Validates that the args passed to +get+ are valid
319
319
  def validate_and_clean(args)
320
- [:dimensions, :metrics].each do |key|
320
+ [:dimensions, :metrics, :sort, :filters].each do |key|
321
321
  value = args[key] || []
322
322
  args[key] = value.respond_to?(:to_ary) ? value.to_ary : [value]
323
323
  end
@@ -19,7 +19,7 @@ module Gattica
19
19
  def initialize(http, user)
20
20
  options = OPTIONS.merge(user.to_h)
21
21
 
22
- response, data = http.post(SCRIPT_NAME, options.to_query, HEADERS)
22
+ response = http.post(SCRIPT_NAME, options.to_query, HEADERS)
23
23
  if response.code != '200'
24
24
  case response.code
25
25
  when '403'
@@ -28,7 +28,7 @@ module Gattica
28
28
  raise GatticaError::UnknownAnalyticsError, response.body + " (status code: #{response.code})"
29
29
  end
30
30
  end
31
- @tokens = parse_tokens(data)
31
+ @tokens = parse_tokens(response.body)
32
32
  end
33
33
 
34
34
 
metadata CHANGED
@@ -1,35 +1,35 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gicodewarrior-gattica
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.1
4
+ version: 0.5.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - The Active Network
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2013-04-04 00:00:00.000000000 Z
11
+ date: 2011-11-01 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: nokogiri
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - <
18
- - !ruby/object:Gem::Version
19
- version: '1.6'
20
17
  - - '>='
21
18
  - !ruby/object:Gem::Version
22
19
  version: 1.4.0
20
+ - - <
21
+ - !ruby/object:Gem::Version
22
+ version: '1.6'
23
23
  type: :runtime
24
24
  prerelease: false
25
25
  version_requirements: !ruby/object:Gem::Requirement
26
26
  requirements:
27
- - - <
28
- - !ruby/object:Gem::Version
29
- version: '1.6'
30
27
  - - '>='
31
28
  - !ruby/object:Gem::Version
32
29
  version: 1.4.0
30
+ - - <
31
+ - !ruby/object:Gem::Version
32
+ version: '1.6'
33
33
  description: Gattica is a Ruby library for extracting data from the Google Analytics
34
34
  API.
35
35
  email: rob.cameron@active.com
@@ -39,6 +39,7 @@ extra_rdoc_files:
39
39
  - LICENSE
40
40
  - README.rdoc
41
41
  files:
42
+ - .gitignore
42
43
  - History.txt
43
44
  - LICENSE
44
45
  - README.rdoc
@@ -64,7 +65,8 @@ homepage: http://github.com/activenetwork/gattica
64
65
  licenses: []
65
66
  metadata: {}
66
67
  post_install_message:
67
- rdoc_options: []
68
+ rdoc_options:
69
+ - --charset=UTF-8
68
70
  require_paths:
69
71
  - lib
70
72
  required_ruby_version: !ruby/object:Gem::Requirement
@@ -81,6 +83,13 @@ requirements: []
81
83
  rubyforge_project:
82
84
  rubygems_version: 2.0.3
83
85
  signing_key:
84
- specification_version: 4
86
+ specification_version: 3
85
87
  summary: Gattica is a Ruby library for extracting data from the Google Analytics API.
86
- test_files: []
88
+ test_files:
89
+ - test/test_auth.rb
90
+ - test/helper.rb
91
+ - test/test_user.rb
92
+ - test/test_engine.rb
93
+ - test/suite.rb
94
+ - test/test_gattica.rb
95
+ - examples/example.rb