stock_index 0.8.2 → 0.8.3

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: 47caacde2517072a8821c60eade50e3ccd2ef24b
4
- data.tar.gz: 68cf3b9fc472f093417bec1f6a1d8d0886f11db6
3
+ metadata.gz: 756783af169d357099bb8d42a12a845e1ea06f63
4
+ data.tar.gz: 3212e237c134bbe4230e212e523b4dac963dac9d
5
5
  SHA512:
6
- metadata.gz: 2baeb6f8641d8554e7743d84bc1f554295d3032cfd5258fdd1b9bd59d631f25535f3e741f8e0b6078bb2c18900135316f33a69feb68c8b1945f06389dda1d15f
7
- data.tar.gz: 5786a1fa5c3738260571f0ff9cc98d514f4fad70a2517c089557ac505cb3937c692fe7c0a7bc068ed68eeb1583be89ef09c6d2261f1c70eeabe582048797ec3a
6
+ metadata.gz: a7390f2bca18b518c3f22fb3cbeac607742c8053cb54efdb187d271f0720e48e47aeff0f9159186423d5bba263b9ced7874cdf516b827ae01600ef8c8b5ac490
7
+ data.tar.gz: 9c574bd43a8254ab207a81ea63052996ffbfe8700571631dcfd4d943dc1a1f5cd9aed57760b9ceb97f39aea854728c1fcc588ab883505e56054e104895b1ae0a
data/.gitignore CHANGED
@@ -6,7 +6,7 @@
6
6
  Gemfile.lock
7
7
  InstalledFiles
8
8
  _yardoc
9
- coverage
9
+ /coverage
10
10
  doc/
11
11
  lib/bundler/man
12
12
  pkg
@@ -15,5 +15,4 @@ spec/reports
15
15
  test/tmp
16
16
  test/version_tmp
17
17
  tmp
18
- .idea
19
- .rvmrc
18
+ .idea
data/.ruby-gemset ADDED
@@ -0,0 +1 @@
1
+ stock_index
data/.ruby-version ADDED
@@ -0,0 +1 @@
1
+ ruby-2.2.2
data/CHANGELOG.md ADDED
@@ -0,0 +1,13 @@
1
+ # Change Log
2
+
3
+ ## [0.8.3] - 2015-07-27
4
+
5
+ ### Added
6
+ - This CHANGELOG.md file
7
+
8
+ ### Changed
9
+ - Improve README.md
10
+ - Change .rvmrc for .ruby-version and .ruby-gemset in .gitignore
11
+
12
+ ### Fixed
13
+ - [Scraping from wikipedia pages has stopped working](https://github.com/javiervidal/stock_index/issues/1)
data/README.md CHANGED
@@ -75,6 +75,18 @@ The bbgid is obtained from [Bloomberg Open Symbology predefined files](http://bs
75
75
 
76
76
  The name, cik, and bbgid are cached using [PStore](http://ruby-doc.org/stdlib-1.9.2/libdoc/pstore/rdoc/PStore.html).
77
77
 
78
+ ## How to Launch the Console
79
+
80
+ $ rake console
81
+
82
+ ## How to Run the Test Suite
83
+
84
+ $ rspec
85
+
86
+ ## Changelog
87
+
88
+ [Changelog](https://github.com/javiervidal/stock_index/blob/master/CHANGELOG.md)
89
+
78
90
  ## Contributing
79
91
 
80
92
  1. Fork it ( http://github.com/javiervidal/stock_index/fork )
@@ -85,7 +97,7 @@ The name, cik, and bbgid are cached using [PStore](http://ruby-doc.org/stdlib-1.
85
97
 
86
98
  ## Code Status
87
99
 
88
- [![Gem Version](http://img.shields.io/badge/gem-v0.8.0-blue.svg)](https://rubygems.org/gems/stock_index)
100
+ [![Gem Version](http://img.shields.io/badge/gem-v0.8.3-blue.svg)](https://rubygems.org/gems/stock_index)
89
101
  [![Build Status](https://travis-ci.org/javiervidal/stock_index.svg?branch=master)](https://travis-ci.org/javiervidal/stock_index)
90
102
  [![Coverage Status](https://coveralls.io/repos/javiervidal/stock_index/badge.png?branch=master)](https://coveralls.io/r/javiervidal/stock_index?branch=master)
91
103
  [![Code Climate](https://codeclimate.com/github/javiervidal/stock_index/badges/gpa.svg)](https://codeclimate.com/github/javiervidal/stock_index)
data/cache/XLON.pstore CHANGED
Binary file
data/cache/XNAS.pstore CHANGED
Binary file
data/cache/XNYS.pstore CHANGED
Binary file
@@ -2,20 +2,20 @@ class StockIndex
2
2
  INDICES = {
3
3
  '^DJI' => {
4
4
  name: 'DOW JONES INDUSTRIAL AVERAGE',
5
- url: 'http://en.wikipedia.org/wiki/Dow_Jones_Industrial_Average'
5
+ url: 'https://en.wikipedia.org/wiki/Dow_Jones_Industrial_Average'
6
6
  },
7
7
  '^GSPC' => {
8
8
  name: 'S&P 500',
9
- url: 'http://en.wikipedia.org/wiki/List_of_S%26P_500_companies'
9
+ url: 'https://en.wikipedia.org/wiki/List_of_S%26P_500_companies'
10
10
  },
11
11
  '^NDX' => {
12
12
  name: 'NASDAQ 100',
13
- url: 'http://en.wikipedia.org/wiki/NASDAQ-100'
13
+ url: 'https://en.wikipedia.org/wiki/NASDAQ-100'
14
14
  },
15
15
  '^N225' => {
16
16
  name: 'NIKKEI 225',
17
17
  url: 'http://indexes.nikkei.co.jp/en/nkave/index/component?idx=nk225',
18
- wikipedia_url: 'http://en.wikipedia.org/wiki/Nikkei_225'
18
+ wikipedia_url: 'https://en.wikipedia.org/wiki/Nikkei_225'
19
19
  },
20
20
  '^STOXX50E' => {
21
21
  name: 'EURO STOXX 50',
@@ -24,7 +24,7 @@ class StockIndex
24
24
  '^FTSE' => {
25
25
  name: 'FTSE 100',
26
26
  url: 'http://www.londonstockexchange.com/exchange/prices-and-markets/stocks/indices/summary/summary-indices-constituents.html?index=UKX',
27
- wikipedia_url: 'http://en.wikipedia.org/wiki/FTSE_100_Index#Current_constituents'
27
+ wikipedia_url: 'https://en.wikipedia.org/wiki/FTSE_100_Index#Current_constituents'
28
28
  }
29
29
  }
30
30
  end
@@ -1,3 +1,3 @@
1
1
  class StockIndex
2
- VERSION = "0.8.2"
2
+ VERSION = "0.8.3"
3
3
  end
data/spec/helper.rb CHANGED
@@ -13,15 +13,15 @@ WebMock.disable_net_connect!(allow: 'coveralls.io')
13
13
  RSpec.configure do |config|
14
14
  config.before(:each) do
15
15
 
16
- stub_request(:get, "http://en.wikipedia.org/wiki/Dow_Jones_Industrial_Average").
16
+ stub_request(:get, "https://en.wikipedia.org/wiki/Dow_Jones_Industrial_Average").
17
17
  with(:headers => {'Accept' => '*/*'}).
18
18
  to_return(:status => 200, :body => fixture_html('dji'), :headers => {})
19
19
 
20
- stub_request(:get, "http://en.wikipedia.org/wiki/List_of_S&P_500_companies").
20
+ stub_request(:get, "https://en.wikipedia.org/wiki/List_of_S&P_500_companies").
21
21
  with(:headers => {'Accept' => '*/*'}).
22
22
  to_return(:status => 200, :body => fixture_html('gspc'), :headers => {})
23
23
 
24
- stub_request(:get, "http://en.wikipedia.org/wiki/NASDAQ-100").
24
+ stub_request(:get, "https://en.wikipedia.org/wiki/NASDAQ-100").
25
25
  with(:headers => {'Accept' => '*/*'}).
26
26
  to_return(:status => 200, :body => fixture_html('ndx'), :headers => {})
27
27
 
@@ -29,7 +29,7 @@ RSpec.configure do |config|
29
29
  with(:headers => {'Accept' => '*/*'}).
30
30
  to_return(:status => 200, :body => fixture_html('n225'), :headers => {})
31
31
 
32
- stub_request(:get, "http://en.wikipedia.org/wiki/Nikkei_225").
32
+ stub_request(:get, "https://en.wikipedia.org/wiki/Nikkei_225").
33
33
  with(:headers => {'Accept' => '*/*'}).
34
34
  to_return(:status => 200, :body => fixture_html('n225_wikipedia'), :headers => {})
35
35
 
@@ -65,7 +65,7 @@ RSpec.configure do |config|
65
65
  with(:headers => {'Accept' => '*/*'}).
66
66
  to_return(:status => 200, :body => fixture_html_ftse(6), :headers => {})
67
67
 
68
- stub_request(:get, "http://en.wikipedia.org/wiki/FTSE_100_Index").
68
+ stub_request(:get, "https://en.wikipedia.org/wiki/FTSE_100_Index").
69
69
  with(:headers => {'Accept' => '*/*'}).
70
70
  to_return(:status => 200, :body => fixture_html('ftse_wikipedia'), :headers => {})
71
71
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: stock_index
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.8.2
4
+ version: 0.8.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Javier Vidal
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-12-22 00:00:00.000000000 Z
11
+ date: 2015-07-28 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -145,7 +145,10 @@ extra_rdoc_files: []
145
145
  files:
146
146
  - ".gitignore"
147
147
  - ".rspec"
148
+ - ".ruby-gemset"
149
+ - ".ruby-version"
148
150
  - ".travis.yml"
151
+ - CHANGELOG.md
149
152
  - Gemfile
150
153
  - LICENSE.txt
151
154
  - README.md
@@ -216,7 +219,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
216
219
  version: '0'
217
220
  requirements: []
218
221
  rubyforge_project:
219
- rubygems_version: 2.2.2
222
+ rubygems_version: 2.4.8
220
223
  signing_key:
221
224
  specification_version: 4
222
225
  summary: Stock Index