Sha256: 006da2411408d2d104544c58449af75f6d70e33ed292b168cd55835cb9dfa7cf
Contents?: true
Size: 273 Bytes
Versions: 3
Compression:
Stored size: 273 Bytes
Contents
module UtilsHelper def filesize(i) case when i > 1000000000 '%dG' % (i / 1000000000).to_i when i > 1000000 '%dM' % (i / 1000000).to_i when i > 1000 '%dk' % (i / 1000).to_i else i.to_s end end end self.extend UtilsHelper
Version data entries
3 entries across 3 versions & 2 rubygems
Version | Path |
---|---|
gitstats-rb-2.0.0 | template/gnuplot/helpers/utils.rb |
gitstats-ruby-1.0.1 | template/helpers/utils.rb |
gitstats-ruby-1.0.0 | template/helpers/utils.rb |