bin/cobench in cobench-0.0.4 vs bin/cobench in cobench-0.0.5
- old
+ new
@@ -25,10 +25,11 @@
require 'loog'
require 'octokit'
require 'nokogiri'
require 'backtrace'
require 'fileutils'
+require 'obk'
require_relative '../lib/cobench/version'
loog = Loog::REGULAR
def config(path)
@@ -87,9 +88,10 @@
else
api = Octokit::Client.new
loog.warn("Connecting to GitHub without a token, this may lead to errors, use --token")
end
api.auto_paginate = true
+ api = Obk.new(api, pause: 2000)
opts[:coder].each do |u|
loog.info("Scanning #{u}...")
data[u] = {}
Dir[File.join(__dir__, '../lib/cobench/metrics/*.rb')].each do |f|
name = File::basename(f).split('.')[0]