CLI_2 0.1.1 → 0.1.2

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: 13f02e0abff7b6caf511ae76fff2bb92e715273afc932d24f23d52e842bfef86
4
- data.tar.gz: 6e3d21f227a26bfe9f9a6595607f9882c97655d5482266154b83d5fdd8f318ad
3
+ metadata.gz: 5c11305b83475bdef31ecae376e03c608efd443c4ef77b87f385a4f6f3d8c074
4
+ data.tar.gz: 460d40df4873cd0b647a1c7e956c9710a9804f08cea2723ab89dd489bfab26b7
5
5
  SHA512:
6
- metadata.gz: 835edbb29636f290bace867d5b1e906735085ef6beb5d3cd2a8ee9f7e57ff762f8ad042ce2ea292a03f7c28d07476cb36b36156dd9021cbd83ef6b082222df87
7
- data.tar.gz: 02edb17d3218e0c38b3529ce7d6fd87277c41930ca1e81da6501a292838dbfb70da0f0fb2549f3d0ee9cf3bf284c65b285fe60cdfcebf0ad24bc6aba13747053
6
+ metadata.gz: d3e94f5a9a968533d0dad99b648876d372bf515be6c5c4e6c992c5fac4bcfd0f92426035934526a20647eda13784822e460863edd7cfdb574b7f7042ec5b341b
7
+ data.tar.gz: f7e5b17f69455bdaa842108cd81579aab3ebbe91fb80fdf021da1f1d7e82b9d8f3cae36e41d207d9b8055a14ae02a8fd5c5ad2ffabef3fcd742305368ce23699
data/CLI_2-0.1.1.gem ADDED
Binary file
data/CLI_2.gemspec CHANGED
@@ -10,7 +10,7 @@ Gem::Specification.new do |spec|
10
10
  spec.email = ["'alekvuka@gmail.com'"]
11
11
 
12
12
  spec.summary = %q{Write a short summary, because RubyGems requires one.}
13
- spec.description = %q{ Write a longer description or delete this line.}
13
+ spec.description = %q{ The framework of the gem is in CLI, Scraper and Provider classes with a Printer module. The CLI class initiates the user interaction and is responsible for interpreting user input and initiating the Scraper class. The Scraper class is responsible fir scraping the given website and instantiating Provider objects. The provider class is responsible for Provider objects each instance of has instance variables that account for the Provider attributes, such as name, qualifications, etc. The Printer module is responsible for outputting messages to the user, it contains methods such as “Main Menu” and “Warning Message.”}
14
14
  spec.homepage = "https://github.com/alekvuka/CLI_2"
15
15
  spec.license = "MIT"
16
16
 
data/Gemfile CHANGED
@@ -6,4 +6,4 @@ git_source(:github) {|repo_name| "https://github.com/#{repo_name}" }
6
6
  gemspec
7
7
 
8
8
  gem 'pry'
9
- gem 'nokogiri', '1.6.6.2'
9
+ gem "nokogiri", ">= 1.8.2"
data/README.md CHANGED
@@ -1,8 +1,8 @@
1
1
  # CLI2
2
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/CLI_2`. To experiment with that code, run `bin/console` for an interactive prompt.
3
+ CLI_2 scrapes provider's name, specialties, teams, languages and other attributes from a health clinic's website directory. CLI_2 organizes these attributes so that they can be easily interrogated by the user. The user can interact with the program though a CLI menu which displays the options on what information the user can gather from the collected data.
4
4
 
5
- TODO: Delete this and the text above, and describe your gem
5
+ CLI_2 is designed to be easily modified so that you can use it as a template when collecting and organizing information from your specific health clinic's website.
6
6
 
7
7
  ## Installation
8
8
 
@@ -20,13 +20,10 @@ Or install it yourself as:
20
20
 
21
21
  $ gem install CLI_2
22
22
 
23
- ## Usage
24
-
25
- TODO: Write usage instructions here
26
23
 
27
24
  ## Development
28
25
 
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.
26
+ After checking out the repo, run `bin/setup` to install dependencies. You can also run `bin/run` for an interactive prompt that will allow you to interact with the program.
30
27
 
31
28
  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
29
 
data/lib/CLI.rb CHANGED
@@ -15,7 +15,7 @@ class CLI
15
15
  Scraper.scrape_page(clinic_url)
16
16
  end
17
17
 
18
-
18
+
19
19
 
20
20
  def start(clinic_url = "http://callen-lorde.org/meet-our-providers/")
21
21
 
@@ -49,7 +49,7 @@ class CLI
49
49
  if user_input >= 1 && user_input <= 6
50
50
  true
51
51
  else
52
- list_right_options
52
+ Printer::list_right_options
53
53
  start
54
54
  end
55
55
  end
data/lib/CLI_2/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module CLI2
2
- VERSION = "0.1.1"
2
+ VERSION = "0.1.2"
3
3
  end
data/lib/Languages.rb CHANGED
@@ -47,6 +47,7 @@ class Languages
47
47
 
48
48
  end
49
49
  language_instances_to_return
50
+
50
51
  end
51
52
 
52
53
 
data/lib/Printer.rb CHANGED
@@ -76,7 +76,7 @@ module Printer
76
76
  if Teams.team_by_provider_name(provider_instance.name) != nil
77
77
  puts "#{provider_instance.name}'s team: #{Teams.team_by_provider_name(provider_instance.name)}"
78
78
  end
79
- puts "#{provider_instance.name}'s languages: #{Specialites.specialties_by_provider(provider_instance)}"
79
+ puts "#{provider_instance.name}'s specialties: #{Specialites.specialties_by_provider(provider_instance)}"
80
80
  #puts "#{provider_instance.name}'s specialties: #{provider_instance.specialties}"
81
81
  puts "#{provider_instance.name}'s languages: #{Languages.languages_by_provider(provider_instance)}"
82
82
  puts "#{provider_instance.name}'s qualifications: #{provider_instance.qualifications}"
data/lib/UserInputExe.rb CHANGED
@@ -1,5 +1,7 @@
1
1
  module UserInputExe
2
2
 
3
+
4
+
3
5
  def choice_1
4
6
  Printer::print_from_arr_of_o(Providers.all)
5
7
  end
@@ -7,9 +9,8 @@ module UserInputExe
7
9
 
8
10
 
9
11
  def choice_2
10
-
11
- user_input = Printer::get_provider_name
12
12
 
13
+ user_input = Printer::get_provider_name
13
14
  req_provider = Providers.all.detect do |provider|
14
15
  user_input == provider.name
15
16
  end
@@ -28,7 +29,6 @@ module UserInputExe
28
29
  def choice_3
29
30
 
30
31
  instances_of_teams = Teams.all
31
-
32
32
  Printer::print_from_arr_of_o(instances_of_teams)
33
33
 
34
34
  user_input = Printer::get_choice_from_above
@@ -41,11 +41,9 @@ module UserInputExe
41
41
  def choice_4
42
42
 
43
43
  instances_of_specialties = Specialites.all
44
-
45
44
  Printer::print_from_arr_of_o(instances_of_specialties)
46
45
 
47
46
  user_input = Printer::get_choice_from_above
48
-
49
47
  instances_of_specialties.each do |specialty|
50
48
  if specialty.name == user_input
51
49
  Printer::print_from_arr_of_o(specialty.providers)
@@ -59,11 +57,9 @@ module UserInputExe
59
57
  def choice_5
60
58
 
61
59
  instances_of_languages = Languages.all
62
-
63
60
  Printer::print_from_arr_of_o(instances_of_languages)
64
61
 
65
62
  user_input = Printer::get_choice_from_above
66
-
67
63
  instances_of_languages.each do |language|
68
64
  if language.name == user_input
69
65
  Printer::print_from_arr_of_o(language.providers)
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: CLI_2
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - "'ALEKSANDAR VUKASINOVIC'"
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-10-17 00:00:00.000000000 Z
11
+ date: 2018-10-22 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -38,7 +38,14 @@ dependencies:
38
38
  - - "~>"
39
39
  - !ruby/object:Gem::Version
40
40
  version: '10.0'
41
- description: " Write a longer description or delete this line."
41
+ description: " The framework of the gem is in CLI, Scraper and Provider classes with
42
+ a Printer module. The CLI class initiates the user interaction and is responsible
43
+ for interpreting user input and initiating the Scraper class. The Scraper class
44
+ is responsible fir scraping the given website and instantiating Provider objects.
45
+ The provider class is responsible for Provider objects each instance of has instance
46
+ variables that account for the Provider attributes, such as name, qualifications,
47
+ etc. The Printer module is responsible for outputting messages to the user, it contains
48
+ methods such as “Main Menu” and “Warning Message.”"
42
49
  email:
43
50
  - "'alekvuka@gmail.com'"
44
51
  executables:
@@ -48,6 +55,7 @@ extra_rdoc_files: []
48
55
  files:
49
56
  - ".gitignore"
50
57
  - CLI_2-0.1.0.gem
58
+ - CLI_2-0.1.1.gem
51
59
  - CLI_2.gemspec
52
60
  - CODE_OF_CONDUCT.md
53
61
  - Gemfile