segment_rails 0.1.0 → 0.1.1

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: 45a50ecd2866fc9b994f61252c91150fed6ce6ee
4
- data.tar.gz: d4851fc9a646a1a9916310e13a9f6302de9d287a
3
+ metadata.gz: 07161f46bb75eee60819900280f1bd5041044f49
4
+ data.tar.gz: 27cd794e9a7b631615e44a5d534ec11a7b784cbc
5
5
  SHA512:
6
- metadata.gz: b650898e6877a6b3310d8c96fec8498981d323128d3d212d6669d27bc4b7ae2136c3fd7a0bcc4c3a52a0978c68c3e12506d352a7587f257fa1be9111be2f4d57
7
- data.tar.gz: c79720efcad610433a1fa7e178b0cd1bbbbfdaf75fe856b172ec3d5b6ad1e6a673c4c920eed0a6a15c13e5f79c69323937efcb2d1e4bf15643fbfacce7228d80
6
+ metadata.gz: f5b263b84825924fe12b597eb1389f5352b2af0091ea9b4154c12cd0693080fb688386f8fd4988604c7c738b9cc330044579c064337c48be6678dc079e643f23
7
+ data.tar.gz: 05e9b199bbbf0c7da71308d81686796611ba87f7f152fb31bde2bf979d4840a831d10c6f8d84fef402e4a5ff19dde7920cbfad57be8075e00be0130ca9751166
data/.gitignore ADDED
@@ -0,0 +1,10 @@
1
+ /segment_rails_test/
2
+ /.bundle/
3
+ /.yardoc
4
+ /Gemfile.lock
5
+ /_yardoc/
6
+ /coverage/
7
+ /doc/
8
+ /pkg/
9
+ /spec/reports/
10
+ /tmp/
data/.travis.yml ADDED
@@ -0,0 +1,3 @@
1
+ language: ruby
2
+ rvm:
3
+ - 2.2.2
@@ -0,0 +1,13 @@
1
+ # Contributor Code of Conduct
2
+
3
+ As contributors and maintainers of this project, we pledge to respect all people who contribute through reporting issues, posting feature requests, updating documentation, submitting pull requests or patches, and other activities.
4
+
5
+ We are committed to making participation in this project a harassment-free experience for everyone, regardless of level of experience, gender, gender identity and expression, sexual orientation, disability, personal appearance, body size, race, age, or religion.
6
+
7
+ Examples of unacceptable behavior by participants include the use of sexual language or imagery, derogatory comments or personal attacks, trolling, public or private harassment, insults, or other unprofessional conduct.
8
+
9
+ Project maintainers have the right and responsibility to remove, edit, or reject comments, commits, code, wiki edits, issues, and other contributions that are not aligned to this Code of Conduct. Project maintainers who do not follow the Code of Conduct may be removed from the project team.
10
+
11
+ Instances of abusive, harassing, or otherwise unacceptable behavior may be reported by opening an issue or contacting one or more of the project maintainers.
12
+
13
+ This Code of Conduct is adapted from the [Contributor Covenant](http:contributor-covenant.org), version 1.0.0, available at [http://contributor-covenant.org/version/1/0/0/](http://contributor-covenant.org/version/1/0/0/)
data/CONTRIBUTING.md ADDED
@@ -0,0 +1,28 @@
1
+ # Contributor Code of Conduct
2
+
3
+ As contributors and maintainers of this project, we pledge to respect all
4
+ people who contribute through reporting issues, posting feature requests,
5
+ updating documentation, submitting pull requests or patches, and other
6
+ activities.
7
+
8
+ We are committed to making participation in this project a harassment-free
9
+ experience for everyone, regardless of level of experience, gender, gender
10
+ identity and expression, sexual orientation, disability, personal appearance,
11
+ body size, race, ethnicity, age, or religion.
12
+
13
+ Examples of unacceptable behavior by participants include the use of sexual
14
+ language or imagery, derogatory comments or personal attacks, trolling, public
15
+ or private harassment, insults, or other unprofessional conduct.
16
+
17
+ Project maintainers have the right and responsibility to remove, edit, or
18
+ reject comments, commits, code, wiki edits, issues, and other contributions
19
+ that are not aligned to this Code of Conduct. Project maintainers who do not
20
+ follow the Code of Conduct may be removed from the project team.
21
+
22
+ Instances of abusive, harassing, or otherwise unacceptable behavior may be
23
+ reported by opening an issue or contacting one or more of the project
24
+ maintainers.
25
+
26
+ This Code of Conduct is adapted from the [Contributor
27
+ Covenant](http:contributor-covenant.org), version 1.0.0, available at
28
+ [http://contributor-covenant.org/version/1/0/0/](http://contributor-covenant.org/version/1/0/0/)
data/Gemfile ADDED
@@ -0,0 +1,4 @@
1
+ source 'https://rubygems.org'
2
+
3
+ # Specify your gem's dependencies in segment_rails.gemspec
4
+ gemspec
data/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ The MIT License (MIT)
2
+
3
+ Copyright (c) 2015 Zinc Technology Inc
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
data/LICENSE.txt ADDED
@@ -0,0 +1,21 @@
1
+ The MIT License (MIT)
2
+
3
+ Copyright (c) 2015 Zee Spencer
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in
13
+ all copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21
+ THE SOFTWARE.
data/README.md ADDED
@@ -0,0 +1,27 @@
1
+ # Segment-Rails
2
+
3
+ Segment is an incredible layer of abstraction between your application and
4
+ analytics systems. It's major benefit is when tracking events at the user
5
+ interface side. This includes all kinds of great meta data about the user that
6
+ isn't available on the server.
7
+
8
+
9
+ In client rendered apps this isn't a problem. Do event tracking at the
10
+ JavaScript layer once the event is verified as successful! In server-side apps,
11
+ the browser doesn't have a clear way of knowing whether an action was successful
12
+ or not.
13
+
14
+ To get that oh-so-sweet client side meta-data while still maintaining the rapid
15
+ development and accessibility of server-side rendering; we enqueue user action
16
+ events in a cookie. We use JavaScript to read the queue and track the events
17
+ with Segment. Mmmm, now we get the lovely referring domain and utm data!
18
+
19
+ ## Installation + Usage
20
+
21
+ 1. Add `segment_rails` to your Gemfile
22
+ 2. Add `include SegmentRails` to your `ApplicationController`
23
+ 3. Instrument your controllers with `track_event("Timmy fell down the
24
+ well", { reporter: :lassie })`
25
+ 4. Profit! (Or at least, observe behaviors which you hope will lead to profit)
26
+
27
+
data/Rakefile ADDED
@@ -0,0 +1 @@
1
+ require "bundler/gem_tasks"
data/bin/console ADDED
@@ -0,0 +1,14 @@
1
+ #!/usr/bin/env ruby
2
+
3
+ require "bundler/setup"
4
+ require "segment_rails"
5
+
6
+ # You can add fixtures and/or initialization code here to make experimenting
7
+ # with your gem easier. You can also use a different console, if you like.
8
+
9
+ # (If you use this, don't forget to add pry to your Gemfile!)
10
+ # require "pry"
11
+ # Pry.start
12
+
13
+ require "irb"
14
+ IRB.start
data/bin/setup ADDED
@@ -0,0 +1,7 @@
1
+ #!/bin/bash
2
+ set -euo pipefail
3
+ IFS=$'\n\t'
4
+
5
+ bundle install
6
+
7
+ # Do any other automated setup that you need to do here
@@ -0,0 +1,4 @@
1
+ module SegmentRails
2
+ VERSION = "0.1.1"
3
+ end
4
+
@@ -0,0 +1,33 @@
1
+ # coding: utf-8
2
+ lib = File.expand_path('../lib', __FILE__)
3
+ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
+ require 'segment_rails/version'
5
+
6
+ Gem::Specification.new do |spec|
7
+ spec.name = "segment_rails"
8
+ spec.version = SegmentRails::VERSION
9
+ spec.authors = ["Zee Spencer"]
10
+ spec.email = ["zee@zeespencer.com"]
11
+
12
+ spec.summary = %q{Preserve your meta-data! Track analytics on the front end!}
13
+ spec.description = %q{Preserve your meta-data! Track analytics on the front end!}
14
+ spec.homepage = "https://github.com/zincmade/segment_rails"
15
+ spec.license = "MIT"
16
+
17
+ # Prevent pushing this gem to RubyGems.org by setting 'allowed_push_host', or
18
+ # delete this section to allow pushing this gem to any host.
19
+ if spec.respond_to?(:metadata)
20
+ spec.metadata['allowed_push_host'] = "https://rubygems.org"
21
+ else
22
+ raise "RubyGems 2.0 or newer is required to protect against public gem pushes."
23
+ end
24
+
25
+ spec.files = `git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
26
+ spec.bindir = "exe"
27
+ spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
28
+ spec.require_paths = ["lib"]
29
+
30
+ spec.add_dependency "railties", ">= 3.1"
31
+ spec.add_development_dependency "bundler", "~> 1.9"
32
+ spec.add_development_dependency "rake", "~> 10.0"
33
+ end
metadata CHANGED
@@ -1,27 +1,84 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: segment_rails
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.1
5
5
  platform: ruby
6
6
  authors:
7
- - Zinc
7
+ - Zee Spencer
8
8
  autorequire:
9
- bindir: bin
9
+ bindir: exe
10
10
  cert_chain: []
11
11
  date: 2015-05-30 00:00:00.000000000 Z
12
- dependencies: []
13
- description: Track events on the front end with segment!
14
- email: hello@zincma.de
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: railties
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - ">="
18
+ - !ruby/object:Gem::Version
19
+ version: '3.1'
20
+ type: :runtime
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - ">="
25
+ - !ruby/object:Gem::Version
26
+ version: '3.1'
27
+ - !ruby/object:Gem::Dependency
28
+ name: bundler
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - "~>"
32
+ - !ruby/object:Gem::Version
33
+ version: '1.9'
34
+ type: :development
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - "~>"
39
+ - !ruby/object:Gem::Version
40
+ version: '1.9'
41
+ - !ruby/object:Gem::Dependency
42
+ name: rake
43
+ requirement: !ruby/object:Gem::Requirement
44
+ requirements:
45
+ - - "~>"
46
+ - !ruby/object:Gem::Version
47
+ version: '10.0'
48
+ type: :development
49
+ prerelease: false
50
+ version_requirements: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - "~>"
53
+ - !ruby/object:Gem::Version
54
+ version: '10.0'
55
+ description: Preserve your meta-data! Track analytics on the front end!
56
+ email:
57
+ - zee@zeespencer.com
15
58
  executables: []
16
59
  extensions: []
17
60
  extra_rdoc_files: []
18
61
  files:
62
+ - ".gitignore"
63
+ - ".travis.yml"
64
+ - CODE_OF_CONDUCT.md
65
+ - CONTRIBUTING.md
66
+ - Gemfile
67
+ - LICENSE
68
+ - LICENSE.txt
69
+ - README.md
70
+ - Rakefile
71
+ - bin/console
72
+ - bin/setup
19
73
  - lib/segment_rails.rb
74
+ - lib/segment_rails/version.rb
75
+ - segment_rails.gemspec
20
76
  - vendor/assets/javascripts/segment_rails.js
21
- homepage: http://rubygems.org/gems/segment_rails
77
+ homepage: https://github.com/zincmade/segment_rails
22
78
  licenses:
23
79
  - MIT
24
- metadata: {}
80
+ metadata:
81
+ allowed_push_host: https://rubygems.org
25
82
  post_install_message:
26
83
  rdoc_options: []
27
84
  require_paths:
@@ -41,5 +98,5 @@ rubyforge_project:
41
98
  rubygems_version: 2.4.5
42
99
  signing_key:
43
100
  specification_version: 4
44
- summary: Track events on the front end with segment!
101
+ summary: Preserve your meta-data! Track analytics on the front end!
45
102
  test_files: []