winr 1.0.4 → 1.0.6
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +4 -0
- data/bin/winr +2 -1
- data/winr.gemspec +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 9edbfd97d6566e4b2a73a54020d1a4ccccdcbb1dbc65f771d8c58b527868ec5e
|
4
|
+
data.tar.gz: 1e5b06ca102234793875f50e37f9424ac1a977b91922e4662fb1552d90f14bb2
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
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", "µ", "
|
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
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
|
+
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-
|
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
|