top_stock_movers 0.1.0
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 +7 -0
- data/.gitignore +11 -0
- data/.rspec +3 -0
- data/.travis.yml +5 -0
- data/CODE_OF_CONDUCT.md +74 -0
- data/Gemfile +6 -0
- data/Gemfile.lock +45 -0
- data/LICENSE.txt +21 -0
- data/Notes.md +46 -0
- data/README.md +43 -0
- data/Rakefile +6 -0
- data/bin/console +14 -0
- data/bin/setup +8 -0
- data/bin/top-stock-movers +5 -0
- data/lib/top_stock_movers/cli.rb +127 -0
- data/lib/top_stock_movers/stocks.rb +32 -0
- data/lib/top_stock_movers/version.rb +3 -0
- data/lib/top_stock_movers.rb +10 -0
- data/spec.md +6 -0
- data/top_stock_movers.gemspec +40 -0
- metadata +133 -0
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: 45453a754fe22db986bbe3dca025da2ce13d392927cdaa1dbb5dcad43c463b29
|
4
|
+
data.tar.gz: 92043c8418334ab5c37c27df6af67dc0a4612b1e4984ed18bccbcf483e0a7d64
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: 0a1279ad61e192e1826f1991f65fa07ae94cac31022988b7a50017b5b52387785dc9bccb2913d20906e54136719db121c781243e4771c94d9e987bf3a75d803b
|
7
|
+
data.tar.gz: 41ca13b5708bfc910d46a583e7518fd2b69d52358110e6ca5ad2ab7c4fbec9438b59f869f84fca522b2a395ffc185e199fd6e3ef980b30548a55f8f6c96df079
|
data/.gitignore
ADDED
data/.rspec
ADDED
data/.travis.yml
ADDED
data/CODE_OF_CONDUCT.md
ADDED
@@ -0,0 +1,74 @@
|
|
1
|
+
# Contributor Covenant Code of Conduct
|
2
|
+
|
3
|
+
## Our Pledge
|
4
|
+
|
5
|
+
In the interest of fostering an open and welcoming environment, we as
|
6
|
+
contributors and maintainers pledge to making participation in our project and
|
7
|
+
our community a harassment-free experience for everyone, regardless of age, body
|
8
|
+
size, disability, ethnicity, gender identity and expression, level of experience,
|
9
|
+
nationality, personal appearance, race, religion, or sexual identity and
|
10
|
+
orientation.
|
11
|
+
|
12
|
+
## Our Standards
|
13
|
+
|
14
|
+
Examples of behavior that contributes to creating a positive environment
|
15
|
+
include:
|
16
|
+
|
17
|
+
* Using welcoming and inclusive language
|
18
|
+
* Being respectful of differing viewpoints and experiences
|
19
|
+
* Gracefully accepting constructive criticism
|
20
|
+
* Focusing on what is best for the community
|
21
|
+
* Showing empathy towards other community members
|
22
|
+
|
23
|
+
Examples of unacceptable behavior by participants include:
|
24
|
+
|
25
|
+
* The use of sexualized language or imagery and unwelcome sexual attention or
|
26
|
+
advances
|
27
|
+
* Trolling, insulting/derogatory comments, and personal or political attacks
|
28
|
+
* Public or private harassment
|
29
|
+
* Publishing others' private information, such as a physical or electronic
|
30
|
+
address, without explicit permission
|
31
|
+
* Other conduct which could reasonably be considered inappropriate in a
|
32
|
+
professional setting
|
33
|
+
|
34
|
+
## Our Responsibilities
|
35
|
+
|
36
|
+
Project maintainers are responsible for clarifying the standards of acceptable
|
37
|
+
behavior and are expected to take appropriate and fair corrective action in
|
38
|
+
response to any instances of unacceptable behavior.
|
39
|
+
|
40
|
+
Project maintainers have the right and responsibility to remove, edit, or
|
41
|
+
reject comments, commits, code, wiki edits, issues, and other contributions
|
42
|
+
that are not aligned to this Code of Conduct, or to ban temporarily or
|
43
|
+
permanently any contributor for other behaviors that they deem inappropriate,
|
44
|
+
threatening, offensive, or harmful.
|
45
|
+
|
46
|
+
## Scope
|
47
|
+
|
48
|
+
This Code of Conduct applies both within project spaces and in public spaces
|
49
|
+
when an individual is representing the project or its community. Examples of
|
50
|
+
representing a project or community include using an official project e-mail
|
51
|
+
address, posting via an official social media account, or acting as an appointed
|
52
|
+
representative at an online or offline event. Representation of a project may be
|
53
|
+
further defined and clarified by project maintainers.
|
54
|
+
|
55
|
+
## Enforcement
|
56
|
+
|
57
|
+
Instances of abusive, harassing, or otherwise unacceptable behavior may be
|
58
|
+
reported by contacting the project team at christian.thomas.2894@gmail.com. All
|
59
|
+
complaints will be reviewed and investigated and will result in a response that
|
60
|
+
is deemed necessary and appropriate to the circumstances. The project team is
|
61
|
+
obligated to maintain confidentiality with regard to the reporter of an incident.
|
62
|
+
Further details of specific enforcement policies may be posted separately.
|
63
|
+
|
64
|
+
Project maintainers who do not follow or enforce the Code of Conduct in good
|
65
|
+
faith may face temporary or permanent repercussions as determined by other
|
66
|
+
members of the project's leadership.
|
67
|
+
|
68
|
+
## Attribution
|
69
|
+
|
70
|
+
This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4,
|
71
|
+
available at [http://contributor-covenant.org/version/1/4][version]
|
72
|
+
|
73
|
+
[homepage]: http://contributor-covenant.org
|
74
|
+
[version]: http://contributor-covenant.org/version/1/4/
|
data/Gemfile
ADDED
data/Gemfile.lock
ADDED
@@ -0,0 +1,45 @@
|
|
1
|
+
PATH
|
2
|
+
remote: .
|
3
|
+
specs:
|
4
|
+
top_stock_movers (0.1.0)
|
5
|
+
nokogiri
|
6
|
+
|
7
|
+
GEM
|
8
|
+
remote: https://rubygems.org/
|
9
|
+
specs:
|
10
|
+
coderay (1.1.2)
|
11
|
+
diff-lcs (1.2.5)
|
12
|
+
method_source (0.9.0)
|
13
|
+
mini_portile2 (2.3.0)
|
14
|
+
nokogiri (1.8.4)
|
15
|
+
mini_portile2 (~> 2.3.0)
|
16
|
+
pry (0.11.3)
|
17
|
+
coderay (~> 1.1.0)
|
18
|
+
method_source (~> 0.9.0)
|
19
|
+
rake (10.4.2)
|
20
|
+
rspec (3.4.0)
|
21
|
+
rspec-core (~> 3.4.0)
|
22
|
+
rspec-expectations (~> 3.4.0)
|
23
|
+
rspec-mocks (~> 3.4.0)
|
24
|
+
rspec-core (3.4.0)
|
25
|
+
rspec-support (~> 3.4.0)
|
26
|
+
rspec-expectations (3.4.0)
|
27
|
+
diff-lcs (>= 1.2.0, < 2.0)
|
28
|
+
rspec-support (~> 3.4.0)
|
29
|
+
rspec-mocks (3.4.0)
|
30
|
+
diff-lcs (>= 1.2.0, < 2.0)
|
31
|
+
rspec-support (~> 3.4.0)
|
32
|
+
rspec-support (3.4.0)
|
33
|
+
|
34
|
+
PLATFORMS
|
35
|
+
ruby
|
36
|
+
|
37
|
+
DEPENDENCIES
|
38
|
+
bundler (~> 1.16)
|
39
|
+
pry
|
40
|
+
rake (~> 10.0)
|
41
|
+
rspec (~> 3.0)
|
42
|
+
top_stock_movers!
|
43
|
+
|
44
|
+
BUNDLED WITH
|
45
|
+
1.16.2
|
data/LICENSE.txt
ADDED
@@ -0,0 +1,21 @@
|
|
1
|
+
The MIT License (MIT)
|
2
|
+
|
3
|
+
Copyright (c) 2018 Christian Thomas
|
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/Notes.md
ADDED
@@ -0,0 +1,46 @@
|
|
1
|
+
How to build a CLI gem
|
2
|
+
|
3
|
+
1. Plan your gem imagine your interface
|
4
|
+
2. Start with the project structure - google
|
5
|
+
3. Start with the entry point - the file run
|
6
|
+
4. Force that to build the CLI interface
|
7
|
+
5. stub out the interface
|
8
|
+
6. start making things real
|
9
|
+
7. discover objects
|
10
|
+
8. program
|
11
|
+
|
12
|
+
Ideas
|
13
|
+
stockmarket biggest movers
|
14
|
+
/sport rankings
|
15
|
+
dog parks near you
|
16
|
+
concerts
|
17
|
+
top travel destinations
|
18
|
+
cheapest travel destinations from your location
|
19
|
+
top rated video games
|
20
|
+
k
|
21
|
+
|
22
|
+
- A command line interface for biggest stock movers across all exchanges
|
23
|
+
|
24
|
+
1. mu
|
25
|
+
2. vrx
|
26
|
+
|
27
|
+
type in number of stock you want to see more about
|
28
|
+
|
29
|
+
|
30
|
+
# to make sure that objects beign added to another are for sure objects and no one can push strings to what you are trying to push objects to
|
31
|
+
# look into collaborating objects video
|
32
|
+
class Newsletter
|
33
|
+
attr_accessor :articles
|
34
|
+
|
35
|
+
def initialize
|
36
|
+
@articles = []
|
37
|
+
end
|
38
|
+
|
39
|
+
def articles
|
40
|
+
@articles.dup.freeze # this makes it so the only way to add an article is through the add_articles method which then passes it through the article class to make sure - you can't just Newsletter.articles = "string"
|
41
|
+
end
|
42
|
+
|
43
|
+
def add_articles(article)
|
44
|
+
raise "invalid article" if !article.is_a?(Article)
|
45
|
+
end
|
46
|
+
end
|
data/README.md
ADDED
@@ -0,0 +1,43 @@
|
|
1
|
+
# TopStockMovers
|
2
|
+
|
3
|
+
Welcome to your new gem! In this directory, you'll find the files you need to be able to package up your Ruby library into a gem. Put your Ruby code in the file `lib/top_stock_movers`. To experiment with that code, run `bin/console` for an interactive prompt.
|
4
|
+
|
5
|
+
TODO: Delete this and the text above, and describe your gem
|
6
|
+
|
7
|
+
## Installation
|
8
|
+
|
9
|
+
Add this line to your application's Gemfile:
|
10
|
+
|
11
|
+
```ruby
|
12
|
+
gem 'top_stock_movers'
|
13
|
+
```
|
14
|
+
|
15
|
+
And then execute:
|
16
|
+
|
17
|
+
$ bundle
|
18
|
+
|
19
|
+
Or install it yourself as:
|
20
|
+
|
21
|
+
$ gem install top_stock_movers
|
22
|
+
|
23
|
+
## Usage
|
24
|
+
|
25
|
+
TODO: Write usage instructions here
|
26
|
+
|
27
|
+
## Development
|
28
|
+
|
29
|
+
After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake spec` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
|
30
|
+
|
31
|
+
To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and tags, and push the `.gem` file to [rubygems.org](https://rubygems.org).
|
32
|
+
|
33
|
+
## Contributing
|
34
|
+
|
35
|
+
Bug reports and pull requests are welcome on GitHub at https://github.com/[USERNAME]/top_stock_movers. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [Contributor Covenant](http://contributor-covenant.org) code of conduct.
|
36
|
+
|
37
|
+
## License
|
38
|
+
|
39
|
+
The gem is available as open source under the terms of the [MIT License](https://opensource.org/licenses/MIT).
|
40
|
+
|
41
|
+
## Code of Conduct
|
42
|
+
|
43
|
+
Everyone interacting in the TopStockMovers project’s codebases, issue trackers, chat rooms and mailing lists is expected to follow the [code of conduct](https://github.com/[USERNAME]/top_stock_movers/blob/master/CODE_OF_CONDUCT.md).
|
data/Rakefile
ADDED
data/bin/console
ADDED
@@ -0,0 +1,14 @@
|
|
1
|
+
#!/usr/bin/env ruby
|
2
|
+
|
3
|
+
require "bundler/setup"
|
4
|
+
require "top_stock_movers"
|
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(__FILE__)
|
data/bin/setup
ADDED
@@ -0,0 +1,127 @@
|
|
1
|
+
class TopStockMovers::CLI
|
2
|
+
|
3
|
+
def call
|
4
|
+
list_viewing_options
|
5
|
+
list_stocks
|
6
|
+
menu
|
7
|
+
goodbye
|
8
|
+
end
|
9
|
+
|
10
|
+
class Viewing_options
|
11
|
+
attr_accessor :name, :desc, :sorter
|
12
|
+
|
13
|
+
@@all = []
|
14
|
+
|
15
|
+
def self.all
|
16
|
+
@@all
|
17
|
+
end
|
18
|
+
|
19
|
+
viewing_options = [["Gainers", "Stocks that have increased the most in price", "percent_change-pos"], ["Losers", "Stocks that have lost most of their value", "percent_change-neg"], ["Active" , "Stocks that have been traded the most", "volume"], ["Most-Volatile", "The volatility of a stock is the fluctuation of price in sany given timeframe", "percent_change-abs"], ["Overbought", "Stocks that have significantly increased in price due a large demand", "rating"], ["Oversold", "stock prices have decreased substantially", "rating"], ["Large-Cap", "Largest companies by market cap", "market_cap"]]
|
20
|
+
|
21
|
+
viewing_options.each do |array|
|
22
|
+
option = self.new
|
23
|
+
option.name = array[0]
|
24
|
+
option.desc = array[1]
|
25
|
+
option.sorter = array[2]
|
26
|
+
@@all << option
|
27
|
+
end
|
28
|
+
end
|
29
|
+
|
30
|
+
@selection = nil
|
31
|
+
|
32
|
+
def list_viewing_options
|
33
|
+
puts ""
|
34
|
+
puts "How would you like to view today's Stock Market?? please enter corresponding number"
|
35
|
+
puts ""
|
36
|
+
Viewing_options.all.each.with_index(1) do |option, i|
|
37
|
+
puts "#{i}. #{option.name} -- #{option.desc}"
|
38
|
+
end
|
39
|
+
input = gets.strip.to_i - 1
|
40
|
+
@selection = Viewing_options.all[input]
|
41
|
+
end
|
42
|
+
|
43
|
+
def list_stocks
|
44
|
+
puts ""
|
45
|
+
puts "Today's Top 25 #{@selection.name} stocks"
|
46
|
+
puts "------------------------------"
|
47
|
+
#The line below allows me to scrape 7 different url's
|
48
|
+
TopStockMovers::Stocks.scrape_tradingview(@selection.name.downcase) if TopStockMovers::Stocks.all == []
|
49
|
+
@stocks = TopStockMovers::Stocks.all
|
50
|
+
case @selection.sorter
|
51
|
+
when "percent_change-pos"
|
52
|
+
@stocks.sort{|a,b| b.percent_change <=> a.percent_change}.each.with_index(1) do |stock, i|
|
53
|
+
puts "#{i}. #{stock.percent_change}% - #{stock.ticker_symbol} - #{stock.name}"
|
54
|
+
break if i == 25
|
55
|
+
end
|
56
|
+
when "percent_change-neg"
|
57
|
+
@stocks.sort{|a,b| a.percent_change <=> b.percent_change}.each.with_index(1) do |stock, i|
|
58
|
+
puts "#{i}. #{stock.percent_change}% - #{stock.ticker_symbol} - #{stock.name}"
|
59
|
+
break if i == 25
|
60
|
+
end
|
61
|
+
when "percent_change-abs"
|
62
|
+
@stocks.sort{|a,b| b.percent_change.abs <=> a.percent_change.abs}.each.with_index(1) do |stock, i|
|
63
|
+
puts "#{i}. #{stock.percent_change}% - #{stock.ticker_symbol} - #{stock.name}"
|
64
|
+
break if i == 25
|
65
|
+
end
|
66
|
+
when "volume"
|
67
|
+
@stocks.sort{|a,b| b.volume <=> a.volume}.each.with_index(1) do |stock, i|
|
68
|
+
puts "#{i}. #{stock.volume}M -Vol #{stock.ticker_symbol} - #{stock.name}"
|
69
|
+
break if i == 25
|
70
|
+
end
|
71
|
+
when "rating"
|
72
|
+
@stocks.sort{|a,b| b.rating <=> a.rating}.each.with_index(1) do |stock, i|
|
73
|
+
puts "#{i}. #{stock.rating} -Rating - #{stock.percent_change}- #{stock.ticker_symbol} - #{stock.name}"
|
74
|
+
break if i == 25
|
75
|
+
end
|
76
|
+
when "market_cap"
|
77
|
+
@stocks.sort{|a,b| b.market_cap <=> a.market_cap}.each.with_index(1) do |stock, i|
|
78
|
+
puts "#{i}. #{stock.market_cap}M -MktCap- #{stock.ticker_symbol} - #{stock.name}"
|
79
|
+
break if i == 25
|
80
|
+
end
|
81
|
+
end
|
82
|
+
end
|
83
|
+
|
84
|
+
def menu
|
85
|
+
puts "Enter number of Stock you would like more info on, type 'list' to list stocks, type exit to quit"
|
86
|
+
input = gets.strip.downcase
|
87
|
+
if input.to_i > 0
|
88
|
+
num = input.to_i - 1
|
89
|
+
puts""
|
90
|
+
puts "#{@stocks[num].name} --- #{@stocks[num].ticker_symbol}"
|
91
|
+
puts "-----------------------------------------------------------------"
|
92
|
+
puts "Sector = #{@stocks[num].sector}"
|
93
|
+
puts "Rating = #{@stocks[num].rating}"
|
94
|
+
puts "Price = $#{@stocks[num].price}"
|
95
|
+
puts "Prc chg = #{@stocks[num].change}"
|
96
|
+
puts "% chg = #{@stocks[num].percent_change}"
|
97
|
+
puts "Volume = #{@stocks[num].volume}M"
|
98
|
+
puts "Mkt Cap = #{@stocks[num].market_cap}M"
|
99
|
+
puts "*** Would you like to open this stock's page for more info?(y/n) ***"
|
100
|
+
input_2 = gets.strip.downcase
|
101
|
+
if input_2 == "y"
|
102
|
+
link = "#{@stocks[num].url}"
|
103
|
+
if RbConfig::CONFIG['host_os'] =~ /mswin|mingw|cygwin/
|
104
|
+
system "start #{link}"
|
105
|
+
elsif RbConfig::CONFIG['host_os'] =~ /darwin/
|
106
|
+
system "open #{link}"
|
107
|
+
elsif RbConfig::CONFIG['host_os'] =~ /linux|bsd/
|
108
|
+
system "xdg-open #{link}"
|
109
|
+
end
|
110
|
+
menu
|
111
|
+
else
|
112
|
+
menu
|
113
|
+
end
|
114
|
+
elsif input == 'list'
|
115
|
+
list_stocks
|
116
|
+
menu
|
117
|
+
elsif input == 'exit'
|
118
|
+
else
|
119
|
+
menu
|
120
|
+
end
|
121
|
+
end
|
122
|
+
|
123
|
+
def goodbye
|
124
|
+
puts ""
|
125
|
+
puts "Thanks for using top-stock-movers!! Have a good day!"
|
126
|
+
end
|
127
|
+
end
|
@@ -0,0 +1,32 @@
|
|
1
|
+
class TopStockMovers::Stocks
|
2
|
+
attr_accessor :ticker_symbol, :name, :price, :percent_change, :change, :rating, :sector, :url, :volume, :market_cap
|
3
|
+
|
4
|
+
@@all = []
|
5
|
+
|
6
|
+
def self.all
|
7
|
+
@@all
|
8
|
+
end
|
9
|
+
|
10
|
+
def self.scrape_tradingview(category)
|
11
|
+
doc = Nokogiri::HTML(open("https://www.tradingview.com/markets/stocks-usa/market-movers-#{category}/"))
|
12
|
+
|
13
|
+
doc.css('body div div#js-category-content div div div div#js-screener-container div table tbody tr').each do |row|
|
14
|
+
|
15
|
+
stock = self.new
|
16
|
+
stock.url = "https://www.tradingview.com#{row.css('a').attr('href').value}"
|
17
|
+
|
18
|
+
stock_info = row.css('td').collect{|td| td.text}
|
19
|
+
|
20
|
+
stock.ticker_symbol = stock_info[0].split("\n\t\t\t\t\t\t").reject{|c| c.empty?}[0]
|
21
|
+
stock.name = stock_info[0].split("\n\t\t\t\t\t\t").reject{|c| c.empty?}[1].gsub(/INC|LTD|PLC|3X|LLC|BOND|SPONSORED|\s{2,}|[,(-]/, "++").split("++")[0]
|
22
|
+
stock.price = stock_info[1].to_f
|
23
|
+
stock.percent_change = stock_info[2].to_f
|
24
|
+
stock.change = stock_info[3].to_f
|
25
|
+
stock.rating = stock_info[4]
|
26
|
+
stock.volume = stock_info[5].to_f
|
27
|
+
stock.market_cap = stock_info[6].to_f.round(1)
|
28
|
+
stock.sector = stock_info[10]
|
29
|
+
@@all << stock
|
30
|
+
end
|
31
|
+
end
|
32
|
+
end
|
data/spec.md
ADDED
@@ -0,0 +1,40 @@
|
|
1
|
+
|
2
|
+
lib = File.expand_path("../lib", __FILE__)
|
3
|
+
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
4
|
+
require "top_stock_movers/version"
|
5
|
+
|
6
|
+
Gem::Specification.new do |spec|
|
7
|
+
spec.name = "top_stock_movers"
|
8
|
+
spec.version = TopStockMovers::VERSION
|
9
|
+
spec.authors = ["Christian Thomas"]
|
10
|
+
spec.email = ["christian.thomas.2894@gmail.com"]
|
11
|
+
|
12
|
+
spec.summary = %q{Quick information on the day's top moving stocks}
|
13
|
+
spec.homepage = "https://github.com/CT43/Stock-Market-Insights-cli-gem"
|
14
|
+
spec.license = "MIT"
|
15
|
+
|
16
|
+
# Prevent pushing this gem to RubyGems.org. To allow pushes either set the 'allowed_push_host'
|
17
|
+
# to allow pushing to a single host or delete this section to allow pushing to any host.
|
18
|
+
# if spec.respond_to?(:metadata)
|
19
|
+
# spec.metadata['http://mygemserver.com']
|
20
|
+
# else
|
21
|
+
# raise "RubyGems 2.0 or newer is required to protect against " \
|
22
|
+
# "public gem pushes."
|
23
|
+
# end
|
24
|
+
|
25
|
+
# Specify which files should be added to the gem when it is released.
|
26
|
+
# The `git ls-files -z` loads the files in the RubyGem that have been added into git.
|
27
|
+
spec.files = Dir.chdir(File.expand_path('..', __FILE__)) do
|
28
|
+
`git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
|
29
|
+
end
|
30
|
+
spec.bindir = "exe"
|
31
|
+
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
|
32
|
+
spec.require_paths = ["lib"]
|
33
|
+
|
34
|
+
spec.add_development_dependency "bundler", "~> 1.16"
|
35
|
+
spec.add_development_dependency "rake", "~> 10.0"
|
36
|
+
spec.add_development_dependency "rspec", "~> 3.0"
|
37
|
+
spec.add_development_dependency "pry"
|
38
|
+
|
39
|
+
spec.add_dependency "nokogiri"
|
40
|
+
end
|
metadata
ADDED
@@ -0,0 +1,133 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: top_stock_movers
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.1.0
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- Christian Thomas
|
8
|
+
autorequire:
|
9
|
+
bindir: exe
|
10
|
+
cert_chain: []
|
11
|
+
date: 2018-07-17 00:00:00.000000000 Z
|
12
|
+
dependencies:
|
13
|
+
- !ruby/object:Gem::Dependency
|
14
|
+
name: bundler
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - "~>"
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: '1.16'
|
20
|
+
type: :development
|
21
|
+
prerelease: false
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - "~>"
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: '1.16'
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: rake
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - "~>"
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: '10.0'
|
34
|
+
type: :development
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - "~>"
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: '10.0'
|
41
|
+
- !ruby/object:Gem::Dependency
|
42
|
+
name: rspec
|
43
|
+
requirement: !ruby/object:Gem::Requirement
|
44
|
+
requirements:
|
45
|
+
- - "~>"
|
46
|
+
- !ruby/object:Gem::Version
|
47
|
+
version: '3.0'
|
48
|
+
type: :development
|
49
|
+
prerelease: false
|
50
|
+
version_requirements: !ruby/object:Gem::Requirement
|
51
|
+
requirements:
|
52
|
+
- - "~>"
|
53
|
+
- !ruby/object:Gem::Version
|
54
|
+
version: '3.0'
|
55
|
+
- !ruby/object:Gem::Dependency
|
56
|
+
name: pry
|
57
|
+
requirement: !ruby/object:Gem::Requirement
|
58
|
+
requirements:
|
59
|
+
- - ">="
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: '0'
|
62
|
+
type: :development
|
63
|
+
prerelease: false
|
64
|
+
version_requirements: !ruby/object:Gem::Requirement
|
65
|
+
requirements:
|
66
|
+
- - ">="
|
67
|
+
- !ruby/object:Gem::Version
|
68
|
+
version: '0'
|
69
|
+
- !ruby/object:Gem::Dependency
|
70
|
+
name: nokogiri
|
71
|
+
requirement: !ruby/object:Gem::Requirement
|
72
|
+
requirements:
|
73
|
+
- - ">="
|
74
|
+
- !ruby/object:Gem::Version
|
75
|
+
version: '0'
|
76
|
+
type: :runtime
|
77
|
+
prerelease: false
|
78
|
+
version_requirements: !ruby/object:Gem::Requirement
|
79
|
+
requirements:
|
80
|
+
- - ">="
|
81
|
+
- !ruby/object:Gem::Version
|
82
|
+
version: '0'
|
83
|
+
description:
|
84
|
+
email:
|
85
|
+
- christian.thomas.2894@gmail.com
|
86
|
+
executables: []
|
87
|
+
extensions: []
|
88
|
+
extra_rdoc_files: []
|
89
|
+
files:
|
90
|
+
- ".gitignore"
|
91
|
+
- ".rspec"
|
92
|
+
- ".travis.yml"
|
93
|
+
- CODE_OF_CONDUCT.md
|
94
|
+
- Gemfile
|
95
|
+
- Gemfile.lock
|
96
|
+
- LICENSE.txt
|
97
|
+
- Notes.md
|
98
|
+
- README.md
|
99
|
+
- Rakefile
|
100
|
+
- bin/console
|
101
|
+
- bin/setup
|
102
|
+
- bin/top-stock-movers
|
103
|
+
- lib/top_stock_movers.rb
|
104
|
+
- lib/top_stock_movers/cli.rb
|
105
|
+
- lib/top_stock_movers/stocks.rb
|
106
|
+
- lib/top_stock_movers/version.rb
|
107
|
+
- spec.md
|
108
|
+
- top_stock_movers.gemspec
|
109
|
+
homepage: https://github.com/CT43/Stock-Market-Insights-cli-gem
|
110
|
+
licenses:
|
111
|
+
- MIT
|
112
|
+
metadata: {}
|
113
|
+
post_install_message:
|
114
|
+
rdoc_options: []
|
115
|
+
require_paths:
|
116
|
+
- lib
|
117
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
118
|
+
requirements:
|
119
|
+
- - ">="
|
120
|
+
- !ruby/object:Gem::Version
|
121
|
+
version: '0'
|
122
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
123
|
+
requirements:
|
124
|
+
- - ">="
|
125
|
+
- !ruby/object:Gem::Version
|
126
|
+
version: '0'
|
127
|
+
requirements: []
|
128
|
+
rubyforge_project:
|
129
|
+
rubygems_version: 2.7.7
|
130
|
+
signing_key:
|
131
|
+
specification_version: 4
|
132
|
+
summary: Quick information on the day's top moving stocks
|
133
|
+
test_files: []
|