Sha256: a4c444dff4f9121bc07bbebff5013a21c2dc16eb10f3c47614436ec406ea07fa
Contents?: true
Size: 893 Bytes
Versions: 2
Compression:
Stored size: 893 Bytes
Contents
require "mb_string" require "git_trend/cli" require "git_trend/formatter" require "git_trend/formatters/text_formatter" require "git_trend/formatters/json_formatter" require "git_trend/project" require "git_trend/scraper" require "git_trend/version" module GitTrend # GitTrend.get # GitTrend.get('ruby') # GitTrend.get(:ruby) # # GitTrend.get(since: :weekly) # GitTrend.get(since: :week) # GitTrend.get(since: :w) # # GitTrend.get('ruby', 'weekly') # GitTrend.get(:ruby, :weekly) # GitTrend.get(language: :ruby, since: :weekly) def self.get(*opts) if opts[0].instance_of?(Hash) hash = opts[0] language = hash.key?(:language) ? hash[:language] : nil since = hash.key?(:since) ? hash[:since] : nil Scraper.new.get(language, since) else Scraper.new.get(*opts) end end def self.languages Scraper.new.languages end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
git-trend-1.2.1 | lib/git_trend.rb |
git-trend-1.2.0 | lib/git_trend.rb |