fastlane-plugin-google_analytics 0.1.0 → 0.2.0.pre.alpha.pre.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 9708197bd8e89454b80fb83e4fa9eaa29982be10
|
4
|
+
data.tar.gz: 2577b524b46b55913958259a980d6b118ce62134
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 01fa107995857c47b012c713fe94e3aba77c1df9fe9b2aa242b22759f11a27092d2167729445215cc7ce019fe57c58b6bc9523458835f98ef964d47c59e8a38b
|
7
|
+
data.tar.gz: e60081c1e884cd321d407a22294b2f551fce3f43f2d4a473d302b03470c54e49e21a514699c426a8abfa92c9d284e50ad4931bd774872173b94b7cb78ae29640
|
data/README.md
CHANGED
@@ -10,43 +10,39 @@ This project is a [fastlane](https://github.com/fastlane/fastlane) plugin. To ge
|
|
10
10
|
fastlane add_plugin google_analytics
|
11
11
|
```
|
12
12
|
|
13
|
-
## About
|
13
|
+
## About
|
14
14
|
|
15
|
-
|
15
|
+
Use Google Analytics
|
16
16
|
|
17
|
-
|
17
|
+
<img src='assets/screen.png'>
|
18
18
|
|
19
19
|
## Example
|
20
20
|
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
## Run tests for this plugin
|
26
|
-
|
27
|
-
To run both the tests, and code style validation, run
|
28
|
-
|
21
|
+
### Pageview
|
22
|
+
```ruby
|
23
|
+
google_analytics(payload: { path: '/page-path', hostname: 'mysite.com', title: 'A Page!' } )
|
29
24
|
```
|
30
|
-
|
25
|
+
|
26
|
+
### Exception
|
27
|
+
```ruby
|
28
|
+
google_exception(payload: { description: 'RuntimeException', fatal: true })
|
31
29
|
```
|
32
30
|
|
33
|
-
|
31
|
+
### Timing
|
32
|
+
```ruby
|
33
|
+
google_timing(payload: { category: 'runtime', variable: 'db', label: 'query', time: 50 })
|
34
34
|
```
|
35
|
-
|
35
|
+
|
36
|
+
### Event
|
37
|
+
```ruby
|
38
|
+
google_event(payload: { category: 'video', action: 'play', label: 'cars', value: 1 })
|
36
39
|
```
|
37
40
|
|
41
|
+
|
38
42
|
## Issues and Feedback
|
39
43
|
|
40
44
|
For any other issues and feedback about this plugin, please submit it to this repository.
|
41
45
|
|
42
|
-
## Troubleshooting
|
43
|
-
|
44
|
-
If you have trouble using plugins, check out the [Plugins Troubleshooting](https://docs.fastlane.tools/plugins/plugins-troubleshooting/) guide.
|
45
|
-
|
46
|
-
## Using `fastlane` Plugins
|
47
|
-
|
48
|
-
For more information about how the `fastlane` plugin system works, check out the [Plugins documentation](https://docs.fastlane.tools/plugins/create-plugin/).
|
49
|
-
|
50
46
|
## About `fastlane`
|
51
47
|
|
52
48
|
`fastlane` is the easiest way to automate beta deployments and releases for your iOS and Android apps. To learn more, check out [fastlane.tools](https://fastlane.tools).
|
@@ -4,24 +4,29 @@ module Fastlane
|
|
4
4
|
module Actions
|
5
5
|
class GoogleAnalyticsAction < Action
|
6
6
|
def self.run(params)
|
7
|
-
UI.important "Firing #{params[:type]
|
7
|
+
UI.important "Firing #{params[:type]} ⚡️"
|
8
8
|
tracker(params).send(params[:type].to_s, params[:payload])
|
9
9
|
end
|
10
|
+
|
10
11
|
def self.tracker(params)
|
11
|
-
Staccato.tracker(params[:ua], nil, ssl:true) do |c|
|
12
|
-
|
12
|
+
Staccato.tracker(params[:ua], nil, ssl: true) do |c|
|
13
|
+
# c.adapter = Staccato::Adapter::Logger.new(Staccato.ga_collection_uri, Logger.new(STDOUT), lambda {|params| JSON.dump(params)})
|
13
14
|
end
|
14
15
|
end
|
16
|
+
|
15
17
|
def self.description
|
16
18
|
"Fire universal Analytics"
|
17
19
|
end
|
20
|
+
|
18
21
|
def self.alias_used(action_alias, params)
|
19
22
|
cat = action_alias.split("_").last
|
20
|
-
params[:type]=cat
|
23
|
+
params[:type] = cat
|
21
24
|
end
|
25
|
+
|
22
26
|
def self.aliases
|
23
|
-
|
27
|
+
["google_event", "google_pageview", "google_timing", "google_exception"]
|
24
28
|
end
|
29
|
+
|
25
30
|
def self.authors
|
26
31
|
["Helmut Januschka"]
|
27
32
|
end
|
@@ -47,12 +52,12 @@ module Fastlane
|
|
47
52
|
description: "Google Analytics Payload",
|
48
53
|
optional: false,
|
49
54
|
type: Hash),
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
55
|
+
FastlaneCore::ConfigItem.new(key: :type,
|
56
|
+
env_name: "GOOGLE_ANALYTICS_TYPE",
|
57
|
+
default_value: "pageview",
|
58
|
+
description: "pageview, event, timinig, exception",
|
59
|
+
optional: false,
|
60
|
+
type: String)
|
56
61
|
]
|
57
62
|
end
|
58
63
|
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: fastlane-plugin-google_analytics
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.2.0.pre.alpha.pre.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Helmut Januschka
|
@@ -135,12 +135,12 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
135
135
|
version: '0'
|
136
136
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
137
137
|
requirements:
|
138
|
-
- - "
|
138
|
+
- - ">"
|
139
139
|
- !ruby/object:Gem::Version
|
140
|
-
version:
|
140
|
+
version: 1.3.1
|
141
141
|
requirements: []
|
142
142
|
rubyforge_project:
|
143
|
-
rubygems_version: 2.
|
143
|
+
rubygems_version: 2.4.8
|
144
144
|
signing_key:
|
145
145
|
specification_version: 4
|
146
146
|
summary: Fire universal Analytics
|