hemju-google-analytics 0.0.2 → 0.0.3

Sign up to get free protection for your applications and to get access to all the features.
data/Rakefile CHANGED
@@ -7,10 +7,10 @@ require 'rake/testtask'
7
7
 
8
8
  spec = Gem::Specification.new do |s|
9
9
  s.name = 'hemju-google-analytics'
10
- s.version = '0.0.2'
10
+ s.version = '0.0.3'
11
11
  s.has_rdoc = true
12
12
  s.extra_rdoc_files = ['README', 'LICENSE']
13
- s.summary = 'Your summary here'
13
+ s.summary = "A gem that generates Google Analytics Javascript code."
14
14
  s.description = s.summary
15
15
  s.author = 'Helmut Michael Juskewycz'
16
16
  s.email = 'hjuskewycz@hemju.com'
@@ -30,7 +30,7 @@ Rake::RDocTask.new do |rdoc|
30
30
  files =['README', 'LICENSE', 'lib/**/*.rb']
31
31
  rdoc.rdoc_files.add(files)
32
32
  rdoc.main = "README" # page to start on
33
- rdoc.title = "google-analytics Docs"
33
+ rdoc.title = "hemju-google-analytics Docs"
34
34
  rdoc.rdoc_dir = 'doc/rdoc' # rdoc output folder
35
35
  rdoc.options << '--line-numbers'
36
36
  end
@@ -1,4 +1,4 @@
1
- <% if !Hemju::GoogleAnalytics.production_only || Rails.env="production" %>
1
+ <% if Hemju::GoogleAnalytics.environments.nil? || Hemju::GoogleAnalytics.environments.include?(Rails.env) %>
2
2
  <script type="text/javascript">
3
3
  var _gaq = _gaq || [];_gaq.push(['_setAccount', Hemju::GoogleAnalytics.account]);_gaq.push(['_setDomainName', Hemju::GoogleAnalytics.domain]);_gaq.push(['_trackPageview']);(function() {var ga = document.createElement('script');ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';ga.setAttribute('async', 'true');document.documentElement.firstChild.appendChild(ga);})();
4
4
  </script>
@@ -2,7 +2,9 @@ Hemju::GoogleAnalytics.setup do |config|
2
2
 
3
3
  config.account = "'UA-xxxxxxx-x'"
4
4
  config.domain = ".your-domain"
5
-
6
- config.production_only = true
5
+
6
+ # Define the environments when the Analyitcs code should be included.
7
+ # When set to nil, the code is always included.
8
+ config.environments = ["production"]
7
9
 
8
10
  end
@@ -1,3 +1,5 @@
1
- module Hemju::GoogleAnalytics
2
- VERSION = "0.0.2"
1
+ module Hemju
2
+ module GoogleAnalytics
3
+ VERSION = "0.0.2"
4
+ end
3
5
  end
@@ -1,11 +1,5 @@
1
1
  module Hemju
2
2
  module GoogleAnalytics
3
- class Railtie < ::Rails::Railtie
4
- rake_tasks do
5
- #load "google_analytics/railties/databases.rake"
6
- end
7
- end
8
-
9
3
  attr_accessor :account
10
4
  attr_accessor :domain
11
5
 
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: hemju-google-analytics
3
3
  version: !ruby/object:Gem::Version
4
- hash: 27
4
+ hash: 25
5
5
  prerelease: false
6
6
  segments:
7
7
  - 0
8
8
  - 0
9
- - 2
10
- version: 0.0.2
9
+ - 3
10
+ version: 0.0.3
11
11
  platform: ruby
12
12
  authors:
13
13
  - Helmut Michael Juskewycz
@@ -15,11 +15,11 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2010-06-21 00:00:00 +02:00
18
+ date: 2010-06-22 00:00:00 +02:00
19
19
  default_executable:
20
20
  dependencies: []
21
21
 
22
- description: Your summary here
22
+ description: A gem that generates Google Analytics Javascript code.
23
23
  email: hjuskewycz@hemju.com
24
24
  executables: []
25
25
 
@@ -70,6 +70,6 @@ rubyforge_project:
70
70
  rubygems_version: 1.3.7
71
71
  signing_key:
72
72
  specification_version: 3
73
- summary: Your summary here
73
+ summary: A gem that generates Google Analytics Javascript code.
74
74
  test_files: []
75
75