Skip to content

Commit

Permalink
✨ みんかぶFX/為替のクローラーを追加する
Browse files Browse the repository at this point in the history
  • Loading branch information
aikawame committed Feb 23, 2024
1 parent adb666c commit 2a395c6
Show file tree
Hide file tree
Showing 3 changed files with 1,096 additions and 0 deletions.
13 changes: 13 additions & 0 deletions crawler/app/models/crawler/minkabufx.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# frozen_string_literal: true

# みんかぶFX/為替のクローラー
class Crawler::Minkabufx < Crawler
def fetch_items
fetch_html.css('.list-link__item').map do |block|
anchor = block.css('a')
Item.new(title: anchor.attr('title'),
link_url: URI.join(root_url, anchor.attr('href')),
updated_at: Time.zone.parse(block.css('.fc-sub').text))
end
end
end
Loading

0 comments on commit 2a395c6

Please sign in to comment.