newegg_scraper_chsbr 0.1.0 → 0.2.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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: c0d338e6de4d37ec3b6e4d803a5ad5072690cd7602df34397ffc982027075c84
4
- data.tar.gz: c3fd4a5570d47b5076f445777e6044b5c5b3da94f5c4a18bc8104f68eaf37efb
3
+ metadata.gz: dbfd1d76149f6e24674933978bc42dfed9c4793b07ede185dd890a9624ac8259
4
+ data.tar.gz: dcf10106484e843c95d888d267725e8d3cee154a78ae8014c141baf9a160495b
5
5
  SHA512:
6
- metadata.gz: a86cd954f40f9833d453ae9cb22334bf7e0453706a0f9d62eb09725df9a6506de4d8bee6af669825bda14fb6fc3ca7b5197edda1738dc71557536374b6d7c404
7
- data.tar.gz: 3a2f2fc4723c764fd0df8a4b605c06415429f000b978522a8e6ea301c3c9a819302b8d72dfc43d56ad308b465670ba2bc9e7093a3e0472bcc733f73e5f3aa264
6
+ metadata.gz: 6eedd9aae8b3c008bb8485e882e24322d7b76ac61245f4690dd43772816f72e5a1b5be2ab7538be22c6fc643ab096a4f6530db673c0a04c2611e74fd5eaaec5b
7
+ data.tar.gz: d4d473f51c977978959b4dd7e32a91938cb626bd90b2cb8cd4d83e9e6ea08136747b658ce45f9beefab02aa73445683ef177274f1ab30c659136f42637791388
data/bin/newegg_scraper CHANGED
@@ -1,4 +1,4 @@
1
1
  #!/usr/bin/env ruby
2
2
 
3
3
  require_relative "../lib/environment.rb"
4
- NeweggScraperChsbr::CLI.new.start
4
+ NeweggScraperChsbr::CLI.new.call
data/lib/environment.rb CHANGED
@@ -1,6 +1,8 @@
1
1
  require 'open-uri'
2
2
  require 'nokogiri'
3
3
  require "bundler/setup"
4
+
5
+
4
6
  require_relative "./newegg_scraper_chsbr/version.rb"
5
7
  require_relative './newegg_scraper_chsbr/data_grabber.rb'
6
8
  require_relative './newegg_scraper_chsbr/scraper.rb'
@@ -8,4 +10,6 @@ require_relative './newegg_scraper_chsbr/user.rb'
8
10
  require_relative './newegg_scraper_chsbr/name.rb'
9
11
  require_relative './newegg_scraper_chsbr/price.rb'
10
12
  require_relative './newegg_scraper_chsbr/cli.rb'
11
- require_relative './newegg_scraper_chsbr/cpu.rb'
13
+ require_relative './newegg_scraper_chsbr/cpu.rb'
14
+ require_relative './newegg_scraper_chsbr/descriptors.rb'
15
+ require_relative './newegg_scraper_chsbr/shipping.rb'
@@ -4,28 +4,52 @@ class NeweggScraperChsbr::CLI
4
4
  def initialize
5
5
  NeweggScraperChsbr::DataGrabber.new
6
6
  end
7
- def start
8
- puts "Hello! I heard you were interested in purchasing some CPU's."
9
- puts "Please enter y to browse."
7
+ def call
8
+ puts "Were you interested in purchasing some CPU's?"
9
+ puts "Please enter y to do so."
10
10
  @counter = gets.strip
11
- while @counter == 'y' do
11
+ corr_input = control_bool
12
+ while corr_input
13
+ puts "Were you interested in purchasing some CPU's?"
14
+ puts "Please enter y to do so.\nPlease enter n or exit to quit."
15
+ @counter = gets.strip
16
+ corr_input = control_bool
17
+ end
18
+ while @counter == 'y'
19
+ get_price_range
12
20
  get_init_data_for_user
13
21
  NeweggScraperChsbr::Cpu.display_cpu(@user)
14
22
  @user.choose_cpu
15
23
  NeweggScraperChsbr::Cpu.display_cpu_with_extras(@user)
16
- puts "If you would like to continue please enter : #{@counter}"
24
+ puts "If you would like to restart the program please enter : #{@counter}.\nTo exit type n or exit."
17
25
  @counter = gets.strip
26
+ corr_input = control_bool
27
+ while corr_input
28
+ puts "Were you interested in purchasing some CPU's?"
29
+ puts "Please enter y to do so.\nPlease enter n or exit to quit."
30
+ @counter = gets.strip
31
+ corr_input = control_bool
32
+ end
33
+
18
34
  end
19
35
  puts "Thanks for using Chesbro's Scraper!"
20
36
  end
21
37
  def get_init_data_for_user
22
38
 
23
39
  if @counter == 'y'
24
- get_price_range
40
+
25
41
  puts "Are you searching for Intel or AMD?"
26
42
  puts "Please put i for Intel, or a for AMD."
27
43
  puts "Please put x for either."
28
44
  @cpu_make = gets.strip
45
+ not_found = cpu_make_bool
46
+ while not_found
47
+ puts "Are you searching for Intel or AMD?"
48
+ puts "Please put i for Intel, or a for AMD."
49
+ puts "Please put x for either."
50
+ @cpu_make = gets.strip
51
+ not_found = cpu_make_bool
52
+ end
29
53
  puts "\n\nYou want to search for (an) #{NeweggScraperChsbr::Cpu.cpu_maker(@cpu_make)} CPU."
30
54
  if @max_price.to_i != 0 && @min_price.to_i != 0
31
55
  puts "You entered a maximum price of $#{@max_price}, and a minimum price of $#{@min_price}."
@@ -40,28 +64,59 @@ class NeweggScraperChsbr::CLI
40
64
  end
41
65
  end
42
66
  def if_correct_info
43
- puts "\n IF this data is correct please enter y"
67
+ puts "\nIf you're satisfied with your selection, the computer will print\na list of CPUs that satisfy the criteria. Enter y to continue. Enter n to choose again."
44
68
  @counter = gets.strip
45
69
  if @counter == 'y'
46
70
  @user = NeweggScraperChsbr::User.new(@cpu_make, @min_price, @max_price)
47
71
  else
48
- get_init_data_for_user
72
+ @counter = 'y'
73
+ call
49
74
  end
50
75
  end
51
76
  def get_price_range
52
- puts "Hello! Would you like to set a budget? If no, set your maximum budget to 0"
77
+ puts "Welcome. Would you like to set a budget? If no, set your maximum budget to 0"
78
+ puts "Please enter the integer value of your maximum price."
79
+ puts "$500.50, please enter as 501, or 500 to stay below budget."
80
+ @max_price = gets.strip
81
+ while @max_price.to_i < 0 || @max_price.to_i > 10000 || @max_price.include?("$") || @max_price.include?(".") || @max_price == nil
82
+ puts "Welcome. Would you like to set a budget? If no, set your maximum budget to 0"
53
83
  puts "Please enter the integer value of your maximum price."
54
84
  puts "$500.50, please enter as 501, or 500 to stay below budget."
55
85
  @max_price = gets.strip
56
- if @max_price.to_i == 0
57
- @min_price = "0"
58
- else
86
+ end
87
+ if @max_price.to_i != 0
88
+ puts "Please enter the minimum you would spend on a CPU."
89
+ puts "Please use the same format as above."
90
+ @min_price = gets.strip
91
+
92
+ while @min_price.to_i <= 0 || @min_price.to_i >= @max_price.to_i || @min_price.include?("$") || @min_price.include?(".") || @min_price == nil
59
93
  puts "Please enter the minimum you would spend on a CPU."
60
94
  puts "Please use the same format as above."
61
95
  @min_price = gets.strip
62
96
  end
63
-
97
+ end
64
98
  end
99
+ def control_bool
100
+ if @counter.include?("y")
101
+ false
102
+ elsif @counter.include?("exit")
103
+ false
104
+ elsif @counter.include?("n")
105
+ false
106
+ else
107
+ true
108
+ end
109
+ end
110
+ def cpu_make_bool
111
+ if @cpu_make.include?("x")
112
+ false
113
+ elsif @cpu_make.include?("a")
114
+ false
115
+ elsif @cpu_make.include?("i")
116
+ false
117
+ else
118
+ true
119
+ end
65
120
 
66
-
121
+ end
67
122
  end
@@ -5,8 +5,8 @@ class NeweggScraperChsbr::Cpu
5
5
  def initialize(name, price, shipping, desc)
6
6
  @name = NeweggScraperChsbr::Name.new(name)
7
7
  @price = NeweggScraperChsbr::Price.new(price)
8
- @desc = desc
9
- @shipping = shipping
8
+ @desc = NeweggScraperChsbr::Descriptors.new(desc)
9
+ @shipping = NeweggScraperChsbr::Shipping.new(shipping)
10
10
  @@all << self
11
11
  end
12
12
  def self.all
@@ -25,7 +25,7 @@ class NeweggScraperChsbr::Cpu
25
25
  counter = 1
26
26
  @@all.each do | computer |
27
27
  if user.max_price.to_i != 0 && user.min_price.to_i == 0
28
- binding.pry
28
+
29
29
 
30
30
  user.min_price = "1"
31
31
  end
@@ -54,12 +54,12 @@ class NeweggScraperChsbr::Cpu
54
54
  def self.display_cpu_with_extras(user)
55
55
 
56
56
  user.chosen_cpu.each do | chosen_cpu |
57
- puts "\n\n\n#{@@all[chosen_cpu - 1].name.name}\nHas a price of: #{@@all[chosen_cpu - 1].price.price}\nShipping: #{@@all[chosen_cpu - 1].shipping}\n\n Descriptive Points:\n"
57
+ puts "\n\n\n#{@@all[chosen_cpu - 1].name.name}\nHas a price of: #{@@all[chosen_cpu - 1].price.price}\nShipping: #{@@all[chosen_cpu - 1].shipping.price}\n\n Descriptive Points:\n"
58
58
  @@all[chosen_cpu - 1].printDesc
59
59
  end
60
60
  end
61
61
  def printDesc
62
- @desc.each do | key, value |
62
+ @desc.bullets.each do | key, value |
63
63
  puts " #{key + 1}: #{value}"
64
64
  end
65
65
  end
@@ -1,3 +1,6 @@
1
1
  class NeweggScraperChsbr::Descriptors
2
-
2
+ attr_reader :bullets
3
+ def initialize(hash)
4
+ @bullets = hash
5
+ end
3
6
  end
@@ -1,11 +1,10 @@
1
1
 
2
-
3
2
  class NeweggScraperChsbr::Scraper
4
3
  attr_reader :xml_obj
5
4
 
6
5
  URL = "https://www.newegg.com/p/pl?d=cpu"
7
6
  def initialize(url = URL)
8
- @xml_obj = Nokogiri::HTML(open(url)) # This opens the URL with open-uri, then parses it as an XML Object
7
+ @xml_obj = Nokogiri::HTML(URI.open(url)) # This opens the URL with open-uri, then parses it as an XML Object
9
8
  end
10
9
 
11
10
 
@@ -0,0 +1,6 @@
1
+ class NeweggScraperChsbr::Shipping
2
+ attr_reader :price
3
+ def initialize(shipping_price)
4
+ @price = shipping_price
5
+ end
6
+ end
@@ -8,13 +8,22 @@ class NeweggScraperChsbr::User
8
8
  @chosen_cpu = []
9
9
  end
10
10
  def choose_cpu
11
- puts "Please enter the number of the CPU you'd like to choose."
12
- chosen = gets.strip.to_i
13
- @chosen_cpu << chosen
14
- puts "Would you like to add another CPU?\nEnter y to do so."
15
- if gets.strip == 'y'
11
+ puts "Please enter the number of the CPU you'd like to see more about."
12
+ chosen = gets.strip
13
+ while !is_numeric?(chosen)
14
+ puts "Please enter the number of the CPU you'd like to see more about."
15
+ chosen = gets.strip
16
+ end
17
+ @chosen_cpu << chosen.to_i
18
+ puts "Would you like to see more about another CPU?\nEnter y to do so.\nEnter n to see details about the chosen CPU(s)"
19
+ input = gets.strip
20
+
21
+ if input == 'y'
16
22
  choose_cpu
17
23
  end
18
24
 
19
25
  end
26
+ def is_numeric?(obj)
27
+ obj.match(/\A[^+-]?\d+?(\^.\d+)?\Z/) == nil ? false : true
28
+ end
20
29
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module NeweggScraperChsbr
4
- VERSION = "0.1.0"
4
+ VERSION = "0.2.0"
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: newegg_scraper_chsbr
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Lrd134
8
8
  autorequire:
9
- bindir: exe
9
+ bindir: bin
10
10
  cert_chain: []
11
- date: 2021-04-15 00:00:00.000000000 Z
11
+ date: 2021-04-17 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: nokogiri
@@ -41,18 +41,12 @@ dependencies:
41
41
  description: To scrape CPU's off of Newegg and display them nicely.
42
42
  email:
43
43
  - larryc3200@gmail.com
44
- executables: []
44
+ executables:
45
+ - newegg_scraper
45
46
  extensions: []
46
47
  extra_rdoc_files: []
47
48
  files:
48
- - ".gitignore"
49
- - Gemfile
50
- - Gemfile.lock
51
- - LICENSE.txt
52
- - README.md
53
- - Rakefile
54
49
  - bin/newegg_scraper
55
- - class_diagram.drawio
56
50
  - lib/environment.rb
57
51
  - lib/newegg_scraper_chsbr/cli.rb
58
52
  - lib/newegg_scraper_chsbr/cpu.rb
@@ -61,9 +55,9 @@ files:
61
55
  - lib/newegg_scraper_chsbr/name.rb
62
56
  - lib/newegg_scraper_chsbr/price.rb
63
57
  - lib/newegg_scraper_chsbr/scraper.rb
58
+ - lib/newegg_scraper_chsbr/shipping.rb
64
59
  - lib/newegg_scraper_chsbr/user.rb
65
60
  - lib/newegg_scraper_chsbr/version.rb
66
- - newegg_scraper_chsbr.gemspec
67
61
  homepage: https://github.com/Lrd134/aa_phase_1_proj
68
62
  licenses:
69
63
  - MIT
data/.gitignore DELETED
@@ -1,8 +0,0 @@
1
- /.bundle/
2
- /.yardoc
3
- /_yardoc/
4
- /coverage/
5
- /doc/
6
- /pkg/
7
- /spec/reports/
8
- /tmp/
data/Gemfile DELETED
@@ -1,9 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- source "https://rubygems.org"
4
-
5
- # Specify your gem's dependencies in newegg_scraper_chsbr.gemspec
6
- gemspec
7
- gem "rake", "~> 13.0"
8
- gem "nokogiri"
9
- gem "open-uri"
data/Gemfile.lock DELETED
@@ -1,27 +0,0 @@
1
- PATH
2
- remote: .
3
- specs:
4
- newegg_scraper_chsbr (0.1.0)
5
- nokogiri
6
- open-uri
7
-
8
- GEM
9
- remote: https://rubygems.org/
10
- specs:
11
- nokogiri (1.11.3-x86_64-linux)
12
- racc (~> 1.4)
13
- open-uri (0.1.0)
14
- racc (1.5.2)
15
- rake (13.0.3)
16
-
17
- PLATFORMS
18
- x86_64-linux
19
-
20
- DEPENDENCIES
21
- newegg_scraper_chsbr!
22
- nokogiri
23
- open-uri
24
- rake (~> 13.0)
25
-
26
- BUNDLED WITH
27
- 2.2.13
data/LICENSE.txt DELETED
@@ -1,21 +0,0 @@
1
- The MIT License (MIT)
2
-
3
- Copyright (c) 2021 Lrd134
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/README.md DELETED
@@ -1,43 +0,0 @@
1
- # NeweggScraperChsbr
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/newegg_scraper_chsbr`. 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 'newegg_scraper_chsbr'
13
- ```
14
-
15
- And then execute:
16
-
17
- $ bundle install
18
-
19
- Or install it yourself as:
20
-
21
- $ gem install newegg_scraper_chsbr
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. 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 the created tag, 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]/newegg_scraper_chsbr. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [code of conduct](https://github.com/[USERNAME]/newegg_scraper_chsbr/blob/master/CODE_OF_CONDUCT.md).
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 NeweggScraperChsbr project's codebases, issue trackers, chat rooms and mailing lists is expected to follow the [code of conduct](https://github.com/[USERNAME]/newegg_scraper_chsbr/blob/master/CODE_OF_CONDUCT.md).
data/Rakefile DELETED
@@ -1,3 +0,0 @@
1
- # frozen_string_literal: true
2
- require "bundler/gem_tasks"
3
- task default: %i[]
data/class_diagram.drawio DELETED
@@ -1 +0,0 @@
1
- <mxfile host="app.diagrams.net" modified="2021-04-11T18:44:34.960Z" agent="5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/89.0.4389.114 Safari/537.36" etag="iBiGEqASrCRcf-A13k5W" version="14.5.10" type="device"><diagram id="C5RBs43oDa-KdzZeNtuy" name="Page-1">7Vtbc9o4FP41zHQfsmPZ5pLHQC5NN82mJW32rSOwMCqyxcoihPz6HtkythEX0+CBEmaYwTqWZel8n6TvHNs1pxO83Ag8Hn7mHmE12/Jeas5lzbaRa1vwpyyzxHJedxODL6inK2WGLn0l2qiv8yfUI1GhouScSTouGvs8DElfFmxYCD4tVhtwVrzrGPvEMHT7mJnWJ+rJYWJt2c3M/pFQf5jeGTXOkzMBTivrkURD7PFpzuRc1ZyO4FwmR8FLhzDlvNQvT7ezJ3Y3atx8+hL9j7+1/3m8/36WNHa9zSXzIQgSyt9u+nU0uP743f353/jh+svUurnofTrTl1jPmE20vzrjSaTHK2epE6MpDRgOodQe8FB29RlwQRsz6odw3Ie+EQGGZyIkBf9f6BOSj8HaH1Lm3eEZn6gRRBL3R2mpPeSCvkKzmMEpBAY4LaSmkt0o1OiqK8FsgVWQCOo8pG5Bc9MdjqSu0+eM4XFEe3GHVZUAC5+GbS4lD9KG+CT0iKdLc5zjghR8NGeOur4kGBo05Q3ykqOiBueG8IBIMYMq+uycZ3qiobQ8zWiLGto2zFPWaenpoqeKP297fruvMLVw6IMTsvs5C/dzS94PECncDjMAPsSStJUbozwJ4SA31MwUU3MLmiKDpg+C9onBU3C1zHGSkYFcychojPs09O/iOpduZvmqh6pMHK4dsJgNQ+p5JIzZIrHECaEURcachjL2Rb0NP/BYx/q7XqtDhzpQRlkZfqq6kB0eArEwjRlEgK1Tohi7hFtrZ+1mbs2KkG0LbZ5JBUy3BdA2ALyVJPhxj4PjA3HNajKUAdOHVUFdt/cMtWPOVR7FC/CPzpAf46zdL+DN1p4Bdw3ADYQZjbWD9gZauq9ugD8AIFVzKd6Pig6XZ8jghGNywlmCP8M9woCZVFKu2hdJ3QVe7GvBRpZbDtU1W/+bQK0boP47GIC+U+pdqfUh55ESE52Hb92jm9CVoYr2vTg3DFi7cuKpYZaU/NZJ8u9O8qMFye80qpX8aEHyO63DlfzN1Uy17idBT61F73PZaZSm2aGo/5aB5QX0XiVubOszFqOjQ3KninBrvPceApyfFOHOQS0r86sShMhMFd7Cwm9dARrxVmtbj0oZXoWCq9aObEbnNZBbFcatfS/UyEy03RC143ZJQEMsFOCPeATOPjZ8q4J0/5I/7cC61ZiE3oV61gKlHuNKbbfBpOU4spLiNWXpzrVBLxe3P+L5JJ06hPX49CoztGMDnEiZsrXajvhE9MlmyCC+8EmJaE71di2wy4AUhGFJn4uPnNZo8wdF3EyX21ZRl9uWU2wiGaS+Kv+MZ9uGEi8YDe0sT78k+Sf4gEQRN+X6KcKsPsJ0FiO+shFm09pI4iUBpuOWCDCbhxFgIjNv2cUM6xX3He5t88n75wSWyExTGui990hje1jLxo+VhRpmlvJdKZYUsYOWLGhhpW/+pmRxFhqymwt9qVqyLEk09gUeL8kvngRL9YKlbrUKdCj9FoyN1mwyqxVLvf4HvQVj5lH1azDQFwdlKcV3qF2apYl2MNrFzJKe3ompCOy9Z8RtMzA+CdU3w7rvnLhthpA0BF8BSq/kgx9nTj1w6F9HN58rg3TvKXB7u+CDj2NXbxdezCMTdADBhoZoZ8GGhlkxKS+sXN2hN8Yd9YUMEzq3i02UjjtaGxpaEXcYDZ0t5rwW2uGDQUQqCV1sU0Ew8Kx6SIPNF3r0kpPbXuIwYeX6oJaAMpHNfM+JN4s2BCZ+TPcOZxzqX4Y83ta2ii7i8ErH8nb55cZe9Xhm/nmJHm0t/wVHKfae74S9Z04xunGtt3MFitk3KEn17Ese5+oX</diagram></mxfile>
@@ -1,39 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- require_relative "lib/newegg_scraper_chsbr/version"
4
-
5
- Gem::Specification.new do |spec|
6
- spec.name = "newegg_scraper_chsbr"
7
- spec.version = NeweggScraperChsbr::VERSION
8
- spec.authors = ["Lrd134"]
9
- spec.email = ["larryc3200@gmail.com"]
10
-
11
- spec.summary = "Cpu Shopping Data from Newegg"
12
- spec.description = "To scrape CPU's off of Newegg and display them nicely."
13
- spec.homepage = "https://github.com/Lrd134/aa_phase_1_proj"
14
- spec.license = "MIT"
15
- spec.required_ruby_version = Gem::Requirement.new(">= 2.4.0")
16
-
17
- #spec.metadata["allowed_push_host"] = "https://rubygems.org/"
18
-
19
- spec.metadata["homepage_uri"] = spec.homepage
20
- spec.metadata["source_code_uri"] = "https://github.com/Lrd134/aa_phase_1_proj"
21
- spec.metadata["changelog_uri"] = "https://github.com/Lrd134/aa_phase_1_proj/blob/master/CHANGELOG.md"
22
-
23
- # Specify which files should be added to the gem when it is released.
24
- # The `git ls-files -z` loads the files in the RubyGem that have been added into git.
25
- spec.files = Dir.chdir(File.expand_path(__dir__)) do
26
- `git ls-files -z`.split("\x0").reject { |f| f.match(%r{\A(?:test|spec|features)/}) }
27
- end
28
- spec.bindir = "exe"
29
- spec.executables = spec.files.grep(%r{\Aexe/}) { |f| File.basename(f) }
30
- spec.require_paths = ["lib"]
31
-
32
- # Uncomment to register a new dependency of your gem
33
-
34
- spec.add_dependency "nokogiri"
35
- spec.add_dependency "open-uri"
36
-
37
- # For more information and examples about making a new gem, checkout our
38
- # guide at: https://bundler.io/guides/creating_gem.html
39
- end