la_metric 0.0.1 → 0.0.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +61 -1
- data/la_metric.gemspec +1 -1
- data/lib/la_metric.rb +1 -1
- data/lib/la_metric/frames.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 5524db59b4f88010551d53a1c0afc79b335f790923d88fd5c180f00466383c96
|
4
|
+
data.tar.gz: ba1748ddc43fcb033d5d29f76a3e191112689bd3a5f32b8454dbabaa190056b9
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 1813289d92faf627adfeefb123d422d23d831dc0ed9c160fd38bc4ed8e2c99d074e590d817f5312370db6043875de6bc795adf03695e432b3dafee89b142152c
|
7
|
+
data.tar.gz: fec22ee069753706760c2cd2730c2b1b0086e94537559fc88eb5331aa8b3c14b1d1f2ae3bf3ef620d0779995d7863a4e90a52eea1afd1992749f7ec6ee46aae3
|
data/README.md
CHANGED
@@ -1,2 +1,62 @@
|
|
1
|
-
# lametric
|
2
1
|
LaMetric
|
2
|
+
==============
|
3
|
+
|
4
|
+
Ruby adapter for [LaMetric](https://lametric.com/) clocks
|
5
|
+
|
6
|
+
|
7
|
+
Installation
|
8
|
+
-----------------
|
9
|
+
|
10
|
+
Add to your Gemfile:
|
11
|
+
|
12
|
+
gem 'la_metric'
|
13
|
+
|
14
|
+
Or execute:
|
15
|
+
|
16
|
+
gem install la_metric
|
17
|
+
|
18
|
+
|
19
|
+
Configuration
|
20
|
+
-----------------
|
21
|
+
|
22
|
+
Configure url and access token if you want to push data to your widget:
|
23
|
+
|
24
|
+
LaMetric.configure do |config|
|
25
|
+
config.url = 'your_app_push_url'
|
26
|
+
config.access_token = 'your_access_token'
|
27
|
+
end
|
28
|
+
|
29
|
+
Or via environment variables:
|
30
|
+
|
31
|
+
LA_METRIC_URL=your_app_push_url
|
32
|
+
LA_METRIC_ACCESS_TOKEN=your_access_token
|
33
|
+
|
34
|
+
|
35
|
+
Usage
|
36
|
+
-----------------
|
37
|
+
|
38
|
+
Add your frames:
|
39
|
+
|
40
|
+
frames = LaMetric::Frames.new
|
41
|
+
frames.push('Some text')
|
42
|
+
frames.push(text: 9999, icon: 'i34', index: 0)
|
43
|
+
|
44
|
+
Push frames to widget:
|
45
|
+
|
46
|
+
LaMetric.push(frames)
|
47
|
+
|
48
|
+
Or render frames in your controller
|
49
|
+
|
50
|
+
render json: frames.to_json
|
51
|
+
|
52
|
+
|
53
|
+
Contribution
|
54
|
+
-----------------
|
55
|
+
|
56
|
+
Feel free :)
|
57
|
+
|
58
|
+
|
59
|
+
Author
|
60
|
+
-----------------
|
61
|
+
|
62
|
+
Ilia Kasianenko [@got2be](https://github.com/got2be)
|
data/la_metric.gemspec
CHANGED
data/lib/la_metric.rb
CHANGED
data/lib/la_metric/frames.rb
CHANGED