Skip to content

Created simple web scrapper for ruby jobs in Dublin via indeed.ie#64

Open
Visiona wants to merge 4 commits into
vikingeducation:masterfrom
Visiona:master
Open

Created simple web scrapper for ruby jobs in Dublin via indeed.ie#64
Visiona wants to merge 4 commits into
vikingeducation:masterfrom
Visiona:master

Conversation

@Visiona
Copy link
Copy Markdown

@Visiona Visiona commented Jan 21, 2017

No description provided.

Copy link
Copy Markdown

@remis1889 remis1889 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed.

Comment thread web_searcher.rb Outdated
@@ -0,0 +1,4 @@

class WebSearcher
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unused class.

Comment thread mechanized_agent.rb Outdated
require 'mechanize'


Agent = Mechanize.new { |agt| agt.user_agent_alias = 'Mac Firefox' } No newline at end of file
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This could also be done in the initialize method of WebScrapper class

Comment thread web_scrapper.rb Outdated

def page_with_search_results(city = "Dublin", role = "ruby", page_no = 1)
agent = Mechanize.new { |agt| agt.user_agent_alias = 'Mac Firefox' }
agent.history_added = Proc.new { sleep 0.5 }
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Lines 22-23 should ideally belong to the initialize method of the class.

Comment thread web_scrapper.rb Outdated
# puts "DBG: advert = #{advert.inspect}"
array = scrapping_data_from(advert)
# puts "DBG: array = #{array.inspect}"
@job_posts << array
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Lines 38 and 40 could be combined.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants