Sha256: 5873705ba0596785842b2a013a67797a363fed7a3c33f4893f96371c2d353aa6
Contents?: true
Size: 681 Bytes
Versions: 10
Compression:
Stored size: 681 Bytes
Contents
#!/usr/bin/env ruby require 'githubstats' require 'optparse' OptionParser.new do |opts| opts.banner = 'Usage: githubstats [-h] [USER]' opts.on_tail('-v', '--version', 'Show version') do puts GithubStats::VERSION exit end end.parse! user = GithubStats.new ARGV.first puts "Contribution data for #{user.name}: Today's score: #{user.today} Current streak: #{(user.streak || []).length} Longest streak: #{(user.longest_streak || []).length} High score: #{user.max.score} on #{user.max.date} Quartile boundaries: #{user.quartile_boundaries.inspect}" # Uses https://github.com/holman/spark system('spark', *user.raw.pop(60).map { |point| point.score.to_s })
Version data entries
10 entries across 10 versions & 1 rubygems