chartd 1.0.0 → 1.0.1

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: eab546b1677131a3af4f675d30377798e59a526a
4
- data.tar.gz: 4652a53ccaf3d551fd99c1176c4d0c075a9f8463
3
+ metadata.gz: 0ee60edcb90d712a493f2a79731d697810193e09
4
+ data.tar.gz: a8cbe8eeb202727f796775e2c741bd730e0346a4
5
5
  SHA512:
6
- metadata.gz: aa4086f5cbdbac14f11107992bb9d82c4cbe8d56dd28dfe16f31e46c66c2ddba82b57c5a00477d659432ba470248eea69079fb7a160a6a77f970f3fe07754a5b
7
- data.tar.gz: 47fb6bdd43be5690ace269f3b677c3535bb37acfe88fd2c66d92c0735a53895e8f97101c056420c4f75d007de2056061ddff572449caefb17176700e3cf981af
6
+ metadata.gz: 78079f475d599ad60c00cccaa7ad950ccd20115fb329b5b7a267e2639c13eef31c2bfc4afc32037edb77a90dbe4cdffeb04c5bb11f37bffa2e02bc3a1e554ef6
7
+ data.tar.gz: e523a5da38a3228d5d175448fd882a2e32ee7eb877b24a79a0f90bf3237dd9b081861ae6c7df9603ea783cb82dd85e8abd876098ba944a21134cb1688dd1d12b
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- chartd (0.0.1)
4
+ chartd (1.0.1)
5
5
 
6
6
  GEM
7
7
  remote: https://rubygems.org/
@@ -28,4 +28,4 @@ DEPENDENCIES
28
28
  test-unit (~> 3.2)
29
29
 
30
30
  BUNDLED WITH
31
- 1.11.2
31
+ 1.13.7
File without changes
data/README.md CHANGED
@@ -1,6 +1,7 @@
1
1
  # `chartd-rb` – Encode data for chartd.co
2
2
 
3
3
  [![Build Status](https://travis-ci.org/commissure/chartd-rb.svg?branch=master)](https://travis-ci.org/commissure/chartd-rb)
4
+ [![Gem Version](https://badge.fury.io/rb/chartd.svg)](https://rubygems.org/gems/chartd)
4
5
 
5
6
  :chart_with_upwards_trend: `chartd-rb` is a Ruby gem for [chartd.co],
6
7
  a service from [@stathat], that allows you to creat a chart by encoding
@@ -18,6 +19,27 @@ chart looks like this:
18
19
 
19
20
  <img src="https://chartd.co/a.png?w=580&h=180&d0=SRWfaZHLHEDABKKTUYgpqqvws0138eZfaYtwxxsxyst&ymin=94.48&ymax=103.3">
20
21
 
22
+ ## Installation
23
+
24
+
25
+ Add this line to your application’s Gemfile:
26
+
27
+ ```ruby
28
+ gem 'chartd'
29
+ ```
30
+
31
+ And then execute:
32
+
33
+ ```shell
34
+ $ bundle
35
+ ```
36
+
37
+ Or install it yourself as:
38
+
39
+ ```shell
40
+ $ gem install chartd
41
+ ```
42
+
21
43
 
22
44
  ## Usage
23
45
 
@@ -1,6 +1,6 @@
1
1
  Gem::Specification.new do |s|
2
2
  s.name = 'chartd'
3
- s.version = '1.0.0'
3
+ s.version = '1.0.1'
4
4
  s.summary = 'Encode values for chartd.co'
5
5
  s.description = 'Chartd helps you encode values for use with chartd.co.'
6
6
  s.authors = ['Max Lielje', 'David Pfahler']
@@ -15,11 +15,11 @@ class Chartd
15
15
 
16
16
  def initialize(dataset = [], min: nil, max: nil, ylabels: true, options: {})
17
17
  raise ERR_BAD_DATASET unless dataset.is_a?(Array)
18
- raise ERR_TOO_MANY_DATASETS if dataset.count > 5
19
18
 
20
19
  # Check if dataset is multidimensional and if so, use it as is.
21
20
  # Otherwise make it multidimensional.
22
21
  if dataset[0].is_a?(Array)
22
+ raise ERR_TOO_MANY_DATASETS if dataset.count > 5
23
23
  @dataset = dataset
24
24
  else
25
25
  @dataset = [dataset]
@@ -6,7 +6,7 @@ require 'chartd'
6
6
  class ChartdTest < Test::Unit::TestCase
7
7
  def test_chart
8
8
  expected = 'https://chartd.co/a.png?w=580&h=180&ymin=1.2&ymax=3.1&d0=Am9'
9
- chart = Chartd::Chart.new([1.2, 2.4, 3.1])
9
+ chart = Chartd::Chart.new([1.2, 2.4, 3.1, 4.8, 9.1, 2.2, 2.0])
10
10
 
11
11
  assert_equal expected, chart.url
12
12
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: chartd
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
4
+ version: 1.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Max Lielje
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2016-07-28 00:00:00.000000000 Z
12
+ date: 2017-07-03 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: rake
@@ -64,7 +64,7 @@ files:
64
64
  - ".travis.yml"
65
65
  - Gemfile
66
66
  - Gemfile.lock
67
- - LICENSE
67
+ - LICENSE.md
68
68
  - README.md
69
69
  - Rakefile
70
70
  - chartd.gemspec