world_traveler 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 +6 -0
- data/Gemfile +8 -0
- data/Gemfile.lock +47 -0
- data/LICENSE.txt +21 -0
- data/README.md +38 -0
- data/Rakefile +6 -0
- data/bin/console +14 -0
- data/bin/setup +8 -0
- data/bin/world_traveler +6 -0
- data/lib/world_traveler.rb +15 -0
- data/lib/world_traveler/cli.rb +85 -0
- data/lib/world_traveler/continents.rb +23 -0
- data/lib/world_traveler/display.rb +70 -0
- data/lib/world_traveler/highlights.rb +30 -0
- data/lib/world_traveler/scraper.rb +41 -0
- data/lib/world_traveler/version.rb +3 -0
- data/world_traveler.gemspec +26 -0
- metadata +132 -0
checksums.yaml
ADDED
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
---
|
|
2
|
+
SHA256:
|
|
3
|
+
metadata.gz: 47a84c848b1537cccbd5f6a42e3364aaf8f7981ea6412ba84ca9ef84da3b5bfc
|
|
4
|
+
data.tar.gz: bcc71653dbc5bf5a0f14af9a34e6b4e9f4bb43e942a08f7b7c269280d6a7695e
|
|
5
|
+
SHA512:
|
|
6
|
+
metadata.gz: 15745294f234abbd59298de35a79dd4e35287dc9e1e1c3fec46664b9a2d54f7d55f0b9f5d444ce51b4ae36599a141d079500f63dd93c8dbd08767b070a9d48e0
|
|
7
|
+
data.tar.gz: 56549a090755a5d93f1cc7fa837b6803ff659c1f545a6111ce3a36ce068e7033d74f34acd133369edccd7c986fe17965444d1266ef3f984a2f80cdfbbf9c5b11
|
data/.gitignore
ADDED
data/.rspec
ADDED
data/.travis.yml
ADDED
data/Gemfile
ADDED
data/Gemfile.lock
ADDED
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
PATH
|
|
2
|
+
remote: .
|
|
3
|
+
specs:
|
|
4
|
+
world_traveler (0.1.0)
|
|
5
|
+
nokogiri
|
|
6
|
+
|
|
7
|
+
GEM
|
|
8
|
+
remote: https://rubygems.org/
|
|
9
|
+
specs:
|
|
10
|
+
coderay (1.1.3)
|
|
11
|
+
colorize (0.8.1)
|
|
12
|
+
diff-lcs (1.4.4)
|
|
13
|
+
method_source (1.0.0)
|
|
14
|
+
mini_portile2 (2.4.0)
|
|
15
|
+
nokogiri (1.10.10)
|
|
16
|
+
mini_portile2 (~> 2.4.0)
|
|
17
|
+
pry (0.13.1)
|
|
18
|
+
coderay (~> 1.1)
|
|
19
|
+
method_source (~> 1.0)
|
|
20
|
+
rake (12.3.3)
|
|
21
|
+
rspec (3.9.0)
|
|
22
|
+
rspec-core (~> 3.9.0)
|
|
23
|
+
rspec-expectations (~> 3.9.0)
|
|
24
|
+
rspec-mocks (~> 3.9.0)
|
|
25
|
+
rspec-core (3.9.2)
|
|
26
|
+
rspec-support (~> 3.9.3)
|
|
27
|
+
rspec-expectations (3.9.2)
|
|
28
|
+
diff-lcs (>= 1.2.0, < 2.0)
|
|
29
|
+
rspec-support (~> 3.9.0)
|
|
30
|
+
rspec-mocks (3.9.1)
|
|
31
|
+
diff-lcs (>= 1.2.0, < 2.0)
|
|
32
|
+
rspec-support (~> 3.9.0)
|
|
33
|
+
rspec-support (3.9.3)
|
|
34
|
+
|
|
35
|
+
PLATFORMS
|
|
36
|
+
ruby
|
|
37
|
+
|
|
38
|
+
DEPENDENCIES
|
|
39
|
+
bundler
|
|
40
|
+
colorize (~> 0.8.1)
|
|
41
|
+
pry
|
|
42
|
+
rake (~> 12.0)
|
|
43
|
+
rspec (~> 3.0)
|
|
44
|
+
world_traveler!
|
|
45
|
+
|
|
46
|
+
BUNDLED WITH
|
|
47
|
+
2.1.4
|
data/LICENSE.txt
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
The MIT License (MIT)
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2020 TODO: Write your name
|
|
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
ADDED
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
# WorldTraveler
|
|
2
|
+
|
|
3
|
+
Welcome to WorldTraveler gem! This Ruby gem provides a CLI to view top destinations around the world as per Lonely Planet's travel highlights per continent. It's designed to help user's explore the world through a command line interface. It askes users for a continent of choice, displays highlights in that continent and details for a chosen highlight.
|
|
4
|
+
|
|
5
|
+
## Installation
|
|
6
|
+
|
|
7
|
+
Add this line to your application's Gemfile:
|
|
8
|
+
|
|
9
|
+
```ruby
|
|
10
|
+
gem 'world_traveller'
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
And then execute:
|
|
14
|
+
|
|
15
|
+
$ bundle install
|
|
16
|
+
|
|
17
|
+
Or install it yourself as:
|
|
18
|
+
|
|
19
|
+
$ gem install world_traveler
|
|
20
|
+
|
|
21
|
+
## Usage
|
|
22
|
+
|
|
23
|
+
Execute the bin file './bin/world_traveler' and follow the on screen prompts.
|
|
24
|
+
|
|
25
|
+
## Development
|
|
26
|
+
|
|
27
|
+
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.
|
|
28
|
+
|
|
29
|
+
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).
|
|
30
|
+
|
|
31
|
+
## Contributing
|
|
32
|
+
|
|
33
|
+
Bug reports and pull requests are welcome on GitHub at https://github.com/habeshawit/world_traveler.
|
|
34
|
+
|
|
35
|
+
|
|
36
|
+
## License
|
|
37
|
+
|
|
38
|
+
The gem is available as open source under the terms of the [MIT License](https://opensource.org/licenses/MIT).
|
data/Rakefile
ADDED
data/bin/console
ADDED
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
#!/usr/bin/env ruby
|
|
2
|
+
|
|
3
|
+
require "bundler/setup"
|
|
4
|
+
require "world_traveler"
|
|
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
data/bin/world_traveler
ADDED
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
require 'open-uri'
|
|
2
|
+
require 'nokogiri'
|
|
3
|
+
require 'pry'
|
|
4
|
+
require "world_traveler/version"
|
|
5
|
+
require "colorize"
|
|
6
|
+
require_relative "world_traveler/scraper"
|
|
7
|
+
require_relative "world_traveler/cli"
|
|
8
|
+
require_relative "world_traveler/continents"
|
|
9
|
+
require_relative "world_traveler/highlights"
|
|
10
|
+
require_relative "world_traveler/display"
|
|
11
|
+
|
|
12
|
+
module WorldTraveler
|
|
13
|
+
class Error < StandardError; end
|
|
14
|
+
# Your code goes here...
|
|
15
|
+
end
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
class WorldTraveler::CLI
|
|
2
|
+
|
|
3
|
+
def call
|
|
4
|
+
system("clear")
|
|
5
|
+
WorldTraveler::Display.welcome_message
|
|
6
|
+
sleep(4)
|
|
7
|
+
|
|
8
|
+
@input = ""
|
|
9
|
+
|
|
10
|
+
while @input != "exit"
|
|
11
|
+
get_continents
|
|
12
|
+
list_continents
|
|
13
|
+
get_user_choice
|
|
14
|
+
next_action
|
|
15
|
+
end
|
|
16
|
+
goodbye
|
|
17
|
+
end
|
|
18
|
+
|
|
19
|
+
def get_continents
|
|
20
|
+
@continent = WorldTraveler::Continents.all
|
|
21
|
+
end
|
|
22
|
+
|
|
23
|
+
def list_continents
|
|
24
|
+
system("clear")
|
|
25
|
+
WorldTraveler::Display.continent_list
|
|
26
|
+
|
|
27
|
+
@continent.each.with_index(1) do |continent, index|
|
|
28
|
+
puts "#{index}. #{continent.name}".center(135).rjust(10)
|
|
29
|
+
puts "-----------------------------------------".green.center(150)
|
|
30
|
+
end
|
|
31
|
+
puts ""
|
|
32
|
+
puts "Where would you like to go? (Choose 1-#{@continent.size})".center(135).green.bold
|
|
33
|
+
end
|
|
34
|
+
|
|
35
|
+
def get_user_choice
|
|
36
|
+
chosen_continent = gets.strip.to_i
|
|
37
|
+
show_highlights_for(chosen_continent)
|
|
38
|
+
end
|
|
39
|
+
|
|
40
|
+
def show_highlights_for(chosen_continent)
|
|
41
|
+
system("clear")
|
|
42
|
+
if chosen_continent.between?(1,@continent.size)
|
|
43
|
+
cont = @continent[chosen_continent - 1]
|
|
44
|
+
cont.get_highlights
|
|
45
|
+
puts "Here are highlights for #{cont.name}".light_blue.bold
|
|
46
|
+
cont.highlights.each.with_index(1) do |high, idx|
|
|
47
|
+
puts "#{idx}. #{high.name}"
|
|
48
|
+
end
|
|
49
|
+
get_user_highlight(cont)
|
|
50
|
+
else
|
|
51
|
+
puts "Not sure what you mean. You must enter a number between 1 - #{@continent.size}."
|
|
52
|
+
end
|
|
53
|
+
end
|
|
54
|
+
|
|
55
|
+
def get_user_highlight(cont)
|
|
56
|
+
puts "\nChoose a highlight in #{cont.name} to see more details.".light_blue.bold
|
|
57
|
+
input = (gets.strip.to_i)-1
|
|
58
|
+
if input.between?(0,cont.highlights.size-1)
|
|
59
|
+
highlight = cont.highlights[input]
|
|
60
|
+
highlight.index = input.to_i - 1
|
|
61
|
+
highlight.get_highlight_details
|
|
62
|
+
show_highlight_details(highlight)
|
|
63
|
+
else
|
|
64
|
+
puts "Not sure what you mean. You must enter a number between 1 - #{cont.highlights.size}."
|
|
65
|
+
end
|
|
66
|
+
end
|
|
67
|
+
|
|
68
|
+
def show_highlight_details(highlight)
|
|
69
|
+
puts "---------------------------------#{highlight.name}---------------------------------".center(155).yellow.bold
|
|
70
|
+
highlight.info.each {|i| puts "#{i}\n"}
|
|
71
|
+
puts "-----------------------------------------------------------------------------------".center(155).yellow.bold
|
|
72
|
+
end
|
|
73
|
+
|
|
74
|
+
def next_action
|
|
75
|
+
puts "\nType 'exit' to exit or any key to return to main menu.".green.bold
|
|
76
|
+
@input = gets.strip
|
|
77
|
+
end
|
|
78
|
+
|
|
79
|
+
def goodbye
|
|
80
|
+
system("clear")
|
|
81
|
+
WorldTraveler::Display.goodbye
|
|
82
|
+
end
|
|
83
|
+
end
|
|
84
|
+
|
|
85
|
+
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
class WorldTraveler::Continents
|
|
2
|
+
attr_accessor :name, :url, :highlights
|
|
3
|
+
|
|
4
|
+
@@all = []
|
|
5
|
+
|
|
6
|
+
def initialize(name, url)
|
|
7
|
+
@name = name
|
|
8
|
+
@url = url
|
|
9
|
+
@highlights = []
|
|
10
|
+
@@all << self
|
|
11
|
+
end
|
|
12
|
+
|
|
13
|
+
def self.all
|
|
14
|
+
WorldTraveler::Scraper.scrape_continents if @@all.empty?
|
|
15
|
+
@@all
|
|
16
|
+
end
|
|
17
|
+
|
|
18
|
+
def get_highlights
|
|
19
|
+
WorldTraveler::Scraper.scrape_highlights(self) if @highlights.empty?
|
|
20
|
+
# binding.pry
|
|
21
|
+
end
|
|
22
|
+
|
|
23
|
+
end
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
class WorldTraveler::Display
|
|
2
|
+
|
|
3
|
+
# def self.loading
|
|
4
|
+
# puts " Loading "
|
|
5
|
+
# puts " This may gonna take a few seconds... "
|
|
6
|
+
# end
|
|
7
|
+
|
|
8
|
+
def self.welcome_message
|
|
9
|
+
puts "
|
|
10
|
+
db d8b db d88888b db .o88b. .d88b. .88b d88. d88888b d888888b .d88b. db d8b db .d88b. d8888b. db d8888b.
|
|
11
|
+
88 I8I 88 88' 88 d8P Y8 .8P Y8. 88'YbdP`88 88' `~~88~~' .8P Y8. 88 I8I 88 .8P Y8. 88 `8D 88 88 `8D
|
|
12
|
+
88 I8I 88 88ooooo 88 8P 88 88 88 88 88 88ooooo 88 88 88 88 I8I 88 88 88 88oobY' 88 88 88
|
|
13
|
+
Y8 I8I 88 88~~~~~ 88 8b 88 88 88 88 88 88~~~~~ 88 88 88 Y8 I8I 88 88 88 88`8b 88 88 88
|
|
14
|
+
`8b d8'8b d8' 88. 88booo. Y8b d8 `8b d8' 88 88 88 88. 88 `8b d8' `8b d8'8b d8' `8b d8' 88 `88. 88booo. 88 .8D
|
|
15
|
+
`8b8' `8d8' Y88888P Y88888P `Y88P' `Y88P' YP YP YP Y88888P YP `Y88P' `8b8' `8d8' `Y88P' 88 YD Y88888P Y8888D'
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
d888888b d8888b. .d8b. db db d88888b db d88888b d8888b. db
|
|
19
|
+
`~~88~~' 88 `8D d8' `8b 88 88 88' 88 88' 88 `8D 88
|
|
20
|
+
88 88oobY' 88ooo88 Y8 8P 88ooooo 88 88ooooo 88oobY' YP
|
|
21
|
+
88 88`8b 88~~~88 `8b d8' 88~~~~~ 88 88~~~~~ 88`8b
|
|
22
|
+
88 88 `88. 88 88 `8bd8' 88. 88booo. 88. 88 `88. db
|
|
23
|
+
YP 88 YD YP YP YP Y88888P Y88888P Y88888P 88 YD YP
|
|
24
|
+
|
|
25
|
+
".yellow.bold
|
|
26
|
+
|
|
27
|
+
puts " Let's Travel!
|
|
28
|
+
oO0OoO0OoO0OooO0OoO0OoO0OooO0OoO0OoO0OooO0OoO0OoO0OooO0OoO0OoO0OooO0OoO0OoO0Oo".green.bold
|
|
29
|
+
|
|
30
|
+
end
|
|
31
|
+
|
|
32
|
+
|
|
33
|
+
def self.continent_list
|
|
34
|
+
puts "
|
|
35
|
+
╦ ┬┌─┐┌┬┐ ┌─┐┌─┐ ╔═╗┌─┐┌┐┌┌┬┐┬┌┐┌┌─┐┌┐┌┌┬┐┌─┐
|
|
36
|
+
║ │└─┐ │ │ │├┤ ║ │ ││││ │ ││││├┤ │││ │ └─┐
|
|
37
|
+
╩═╝┴└─┘ ┴ └─┘└ ╚═╝└─┘┘└┘ ┴ ┴┘└┘└─┘┘└┘ ┴ └─┘ ".yellow
|
|
38
|
+
|
|
39
|
+
end
|
|
40
|
+
|
|
41
|
+
def self.goodbye
|
|
42
|
+
puts "
|
|
43
|
+
|
|
44
|
+
|
|
45
|
+
|
|
46
|
+
d8888b. .d88b. d8b db db db .d88b. db db .d8b. d888b d88888b db db
|
|
47
|
+
88 `8D .8P Y8. 888o 88 88 88 .8P Y8. `8b d8' d8' `8b 88' Y8b 88' 88 88
|
|
48
|
+
88oooY' 88 88 88V8o 88 Y8 8P 88 88 `8bd8' 88ooo88 88 88ooooo YP YP
|
|
49
|
+
88~~~b. 88 88 88 V8o88 `8b d8' 88 88 88 88~~~88 88 ooo 88~~~~~
|
|
50
|
+
88 8D `8b d8' 88 V888 `8bd8' `8b d8' 88 88 88 88. ~8~ 88. db db
|
|
51
|
+
Y8888P' `Y88P' VP V8P YP `Y88P' YP YP YP Y888P Y88888P YP YP
|
|
52
|
+
|
|
53
|
+
|
|
54
|
+
|
|
55
|
+
|
|
|
56
|
+
|
|
|
57
|
+
.-'-.
|
|
58
|
+
' ___ '
|
|
59
|
+
---------' .-. '---------
|
|
60
|
+
_________________________' '-' '_________________________
|
|
61
|
+
''''''-|---|--/ \==][^',_m_,'^][==/ \--|---|-''''''
|
|
62
|
+
\ / ||/ H \|| \ /
|
|
63
|
+
'--' OO O|O OO '--'
|
|
64
|
+
|
|
65
|
+
|
|
66
|
+
".yellow
|
|
67
|
+
end
|
|
68
|
+
|
|
69
|
+
|
|
70
|
+
end
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
class WorldTraveler::Highlights
|
|
2
|
+
attr_accessor :name, :continent, :link, :info, :index
|
|
3
|
+
@@all = []
|
|
4
|
+
|
|
5
|
+
def initialize(name, continent, link)
|
|
6
|
+
@name = name
|
|
7
|
+
@continent = continent
|
|
8
|
+
@link = link
|
|
9
|
+
@info = []
|
|
10
|
+
# # notify month about the event
|
|
11
|
+
add_to_continent
|
|
12
|
+
save
|
|
13
|
+
end
|
|
14
|
+
|
|
15
|
+
def self.all
|
|
16
|
+
@@all
|
|
17
|
+
end
|
|
18
|
+
|
|
19
|
+
def add_to_continent
|
|
20
|
+
@continent.highlights << self unless @continent.highlights.include?(self)
|
|
21
|
+
end
|
|
22
|
+
|
|
23
|
+
def get_highlight_details
|
|
24
|
+
WorldTraveler::Scraper.scrape_info(self) if @info.empty?
|
|
25
|
+
end
|
|
26
|
+
|
|
27
|
+
def save
|
|
28
|
+
@@all << self
|
|
29
|
+
end
|
|
30
|
+
end
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
class WorldTraveler::Scraper
|
|
2
|
+
|
|
3
|
+
def self.scrape_continents
|
|
4
|
+
doc = Nokogiri::HTML(open("https://www.lonelyplanet.com/places?page=1&type=Continent"))
|
|
5
|
+
|
|
6
|
+
continents = doc.css("ul.flex li.w-full")
|
|
7
|
+
|
|
8
|
+
continents.each do |c|
|
|
9
|
+
name = c.text
|
|
10
|
+
url = "https://www.lonelyplanet.com" + c.search("a").attribute("href").value
|
|
11
|
+
WorldTraveler::Continents.new(name, url)
|
|
12
|
+
end
|
|
13
|
+
end
|
|
14
|
+
|
|
15
|
+
def self.scrape_highlights(continent)
|
|
16
|
+
doc = Nokogiri::HTML(open(continent.url))
|
|
17
|
+
|
|
18
|
+
highlight = doc.css("ol.jsx-742652205 li.jsx-742652205")
|
|
19
|
+
highlight.each do |h|
|
|
20
|
+
title = h.css("/a/span/span[2]/text()").text.strip
|
|
21
|
+
link = "https://www.lonelyplanet.com/" + h.search("a").attribute("href").value
|
|
22
|
+
WorldTraveler::Highlights.new(title, continent, link)
|
|
23
|
+
end
|
|
24
|
+
end
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
def self.scrape_info(highlight)
|
|
28
|
+
doc = Nokogiri::HTML(open(highlight.link))
|
|
29
|
+
|
|
30
|
+
more_detail1 = doc.css("div.jsx-3600140326 p/text()[1]")["#{highlight.index}".to_i]
|
|
31
|
+
more_detail2 = doc.css("div.jsx-3600140326 p/text()[2]")["#{highlight.index}".to_i]
|
|
32
|
+
if more_detail1 != nil
|
|
33
|
+
highlight.info << "#{more_detail1.text.strip} #{highlight.name} #{more_detail2.text.strip}"
|
|
34
|
+
else
|
|
35
|
+
more = doc.css("div.jsx-2897242284 p")
|
|
36
|
+
more.each {|a| highlight.info << "#{a.text} \n\n"}
|
|
37
|
+
end
|
|
38
|
+
end
|
|
39
|
+
|
|
40
|
+
end
|
|
41
|
+
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
require_relative 'lib/world_traveler/version'
|
|
2
|
+
|
|
3
|
+
Gem::Specification.new do |spec|
|
|
4
|
+
spec.name = "world_traveler"
|
|
5
|
+
spec.version = WorldTraveler::VERSION
|
|
6
|
+
spec.authors = ["Shalom Kebede"]
|
|
7
|
+
spec.email = ["shalomseleshi@gmail.com"]
|
|
8
|
+
|
|
9
|
+
spec.summary = %q{This Ruby gem provides a CLI to view top destinations around the world}
|
|
10
|
+
spec.homepage = "https://github.com/habeshawit/world_traveler"
|
|
11
|
+
spec.license = "MIT"
|
|
12
|
+
|
|
13
|
+
spec.files = Dir.chdir(File.expand_path('..', __FILE__)) do
|
|
14
|
+
`git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
|
|
15
|
+
end
|
|
16
|
+
spec.bindir = "exe"
|
|
17
|
+
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
|
|
18
|
+
spec.require_paths = ["lib"]
|
|
19
|
+
|
|
20
|
+
spec.add_development_dependency "bundler"
|
|
21
|
+
spec.add_development_dependency "rake"
|
|
22
|
+
spec.add_development_dependency "rspec"
|
|
23
|
+
spec.add_development_dependency "pry"
|
|
24
|
+
|
|
25
|
+
spec.add_dependency "nokogiri"
|
|
26
|
+
end
|
metadata
ADDED
|
@@ -0,0 +1,132 @@
|
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
|
2
|
+
name: world_traveler
|
|
3
|
+
version: !ruby/object:Gem::Version
|
|
4
|
+
version: 0.1.0
|
|
5
|
+
platform: ruby
|
|
6
|
+
authors:
|
|
7
|
+
- Shalom Kebede
|
|
8
|
+
autorequire:
|
|
9
|
+
bindir: exe
|
|
10
|
+
cert_chain: []
|
|
11
|
+
date: 2020-09-19 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: '0'
|
|
20
|
+
type: :development
|
|
21
|
+
prerelease: false
|
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
23
|
+
requirements:
|
|
24
|
+
- - ">="
|
|
25
|
+
- !ruby/object:Gem::Version
|
|
26
|
+
version: '0'
|
|
27
|
+
- !ruby/object:Gem::Dependency
|
|
28
|
+
name: rake
|
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
|
30
|
+
requirements:
|
|
31
|
+
- - ">="
|
|
32
|
+
- !ruby/object:Gem::Version
|
|
33
|
+
version: '0'
|
|
34
|
+
type: :development
|
|
35
|
+
prerelease: false
|
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
37
|
+
requirements:
|
|
38
|
+
- - ">="
|
|
39
|
+
- !ruby/object:Gem::Version
|
|
40
|
+
version: '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: '0'
|
|
48
|
+
type: :development
|
|
49
|
+
prerelease: false
|
|
50
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
51
|
+
requirements:
|
|
52
|
+
- - ">="
|
|
53
|
+
- !ruby/object:Gem::Version
|
|
54
|
+
version: '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
|
+
- shalomseleshi@gmail.com
|
|
86
|
+
executables: []
|
|
87
|
+
extensions: []
|
|
88
|
+
extra_rdoc_files: []
|
|
89
|
+
files:
|
|
90
|
+
- ".gitignore"
|
|
91
|
+
- ".rspec"
|
|
92
|
+
- ".travis.yml"
|
|
93
|
+
- Gemfile
|
|
94
|
+
- Gemfile.lock
|
|
95
|
+
- LICENSE.txt
|
|
96
|
+
- README.md
|
|
97
|
+
- Rakefile
|
|
98
|
+
- bin/console
|
|
99
|
+
- bin/setup
|
|
100
|
+
- bin/world_traveler
|
|
101
|
+
- lib/world_traveler.rb
|
|
102
|
+
- lib/world_traveler/cli.rb
|
|
103
|
+
- lib/world_traveler/continents.rb
|
|
104
|
+
- lib/world_traveler/display.rb
|
|
105
|
+
- lib/world_traveler/highlights.rb
|
|
106
|
+
- lib/world_traveler/scraper.rb
|
|
107
|
+
- lib/world_traveler/version.rb
|
|
108
|
+
- world_traveler.gemspec
|
|
109
|
+
homepage: https://github.com/habeshawit/world_traveler
|
|
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
|
+
rubygems_version: 3.1.4
|
|
129
|
+
signing_key:
|
|
130
|
+
specification_version: 4
|
|
131
|
+
summary: This Ruby gem provides a CLI to view top destinations around the world
|
|
132
|
+
test_files: []
|