winr 1.0.4 → 1.0.6

Sign up to get free protection for your applications and to get access to all the features.
Files changed (5) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +4 -0
  3. data/bin/winr +2 -1
  4. data/winr.gemspec +1 -1
  5. metadata +2 -2
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 38f86d556218355c4e595fb33774565d9ccda930368801e5a22f132836e0fb18
4
- data.tar.gz: 502c9dbceec99afd1194380bb27421fcfa240fe74d09f1c6e159ef53720c28b9
3
+ metadata.gz: 9edbfd97d6566e4b2a73a54020d1a4ccccdcbb1dbc65f771d8c58b527868ec5e
4
+ data.tar.gz: 1e5b06ca102234793875f50e37f9424ac1a977b91922e4662fb1552d90f14bb2
5
5
  SHA512:
6
- metadata.gz: 7f452bc2804419bb14b818613351cd963663bf8f191138e481662f5ca8850d8045d46985a8b412753aae7179bc9fc1c91f57ed414af59e97561db6eec00e1deb
7
- data.tar.gz: 1cf7d74de6ecebef12d73c6e257db1e4fc76d3a4d5c1b115b22f5bda22d549dd9144f2a81816fcc6e045fb0843d6234496118ca3885a9a84f94a24efac1b0057
6
+ metadata.gz: 890807ab0362d1e7db37baa79dea67a0a502c1cdb5debf66bef70d7d8688818068603500dc23e9308f0cc931a1ccf77b7db17fce10a6893d1cd5a518596acde9
7
+ data.tar.gz: d15d49fb4f467fd70345411d6a146acf55248a5698f396d05eba780f3ddf620d77a002e9690db9e4447e87c642570628ba79d4a93cc495f3283b3011ecf0e3d3
data/README.md CHANGED
@@ -117,6 +117,10 @@ $ winr test/sum.rb
117
117
  └──────────────────┴─────────────┴──────────────┴────────┘
118
118
  ```
119
119
 
120
+ The following screenshot shows the output (notice the units and color), when the value of `max` is changed to `1e3`.
121
+
122
+ <img src="https://user-images.githubusercontent.com/142875/219610505-64569102-f294-4b2b-b08b-c103d18da247.png" width="640">
123
+
120
124
  ## Install
121
125
 
122
126
  Install via `rubygems` with:
data/bin/winr CHANGED
@@ -60,6 +60,7 @@ show.empty? and abort "invalid list of statistics #{opts[:stats].inspect}"
60
60
 
61
61
  # ==[ Define some constants, ansi codes, and make hashes more flexible ]==
62
62
 
63
+ # used by the scale() method below
63
64
  Infinity = 1.0 / 0
64
65
  Overflow = "\n\nERROR: numeric overflow"
65
66
 
@@ -195,7 +196,7 @@ end
195
196
 
196
197
  def scale(show, unit)
197
198
  slot = 3
198
- span = ["G", "M", "K", " ", "m", "µ", "p"]
199
+ span = ["G", "M", "K", " ", "m", "µ", "n"]
199
200
  [0, Infinity].include?(show) and abort Overflow
200
201
  show *= 1000.0 and slot += 1 while show > 0 && show < 1.0
201
202
  show /= 1000.0 and slot -= 1 while show >= 1000.0
data/winr.gemspec CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
  Gem::Specification.new do |s|
4
4
  s.name = "winr"
5
- s.version = "1.0.4"
5
+ s.version = "1.0.6"
6
6
  s.author = "Steve Shreeve"
7
7
  s.email = "steve.shreeve@gmail.com"
8
8
  s.summary =
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: winr
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.4
4
+ version: 1.0.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Steve Shreeve
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-02-14 00:00:00.000000000 Z
11
+ date: 2023-02-18 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: A quick and lightweight benchmarking tool for Ruby
14
14
  email: steve.shreeve@gmail.com