subunit 0.5.0 → 0.5.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 6f79f4af50bd21b1fbc2ab5d0f182604abdaccd2d71635a2de7608f0284b30b1
4
- data.tar.gz: b0250717312d90e88426144fb0f5d52777302c84a7557784741bf6b0340d26f2
3
+ metadata.gz: e37055bb45fcbc79062342381126b101118521d8a567b27d3a35771774a9acd6
4
+ data.tar.gz: a4b86b164ccbff2d7cde9918a86edf8caacde4d744764d0260cc403547aa21e8
5
5
  SHA512:
6
- metadata.gz: 4ae5c071276ca33df749097b7f0afbf603fd74073fc13063282d4b436be27464f683dc1c5f29081c9eb204274e68980aeb98a5b53534027e41acf59390966387
7
- data.tar.gz: 186200ad80cefe4fd019e1c975db08b0461bed1405e49d78a77056cb437cc62866f79e078e42fb7844c3a7de8e32730ea6ad624cf972dc3001608b949fee3fd7
6
+ metadata.gz: 9d4da753cf22b01795e0b8a6b97586d028287285ebb3aaf0c7d35c05c623b99dd4384402537c7a1cb890e786ea6b22ec31ccbcd1fc1a4c93d4763861978162a5
7
+ data.tar.gz: c059d56a367ca18712cdcae402509fd5770c44d464ada14f035aaabb9d0c272d5e33dd3d88776abee4a56cf92834f40a91e13242af4455bd87d22f155f4d66b7
Binary file
data.tar.gz.sig CHANGED
Binary file
@@ -26,7 +26,12 @@ class Subunit
26
26
  end
27
27
  end
28
28
 
29
- def to_s(omit: [])
29
+ def to_s(omit: [], verbose: true)
30
+
31
+ if not verbose then
32
+ return self.to_a.reverse.take_while {|x| x > 0}.reverse\
33
+ .map {|x| "%02d" % x}.join(':')
34
+ end
30
35
 
31
36
  h = @to_h
32
37
  omit.each {|x| h.delete x}
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: subunit
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.0
4
+ version: 0.5.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - James Robertson
@@ -35,7 +35,7 @@ cert_chain:
35
35
  HowcHg4GymtLLITCF/QtA5tta5SmHAca1POGncsO9QiramFQ9S3Q4O4wcjboVJOp
36
36
  SSxk4InmYoY9Cl2GVQ+d9owo
37
37
  -----END CERTIFICATE-----
38
- date: 2020-06-11 00:00:00.000000000 Z
38
+ date: 2020-07-27 00:00:00.000000000 Z
39
39
  dependencies: []
40
40
  description:
41
41
  email: james@jamesrobertson.eu
@@ -63,9 +63,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
63
63
  - !ruby/object:Gem::Version
64
64
  version: '0'
65
65
  requirements: []
66
- rubyforge_project:
67
- rubygems_version: 2.7.10
66
+ rubygems_version: 3.0.3
68
67
  signing_key:
69
68
  specification_version: 4
70
- summary: subunit
69
+ summary: Input a raw unit and it returns the denomination.
71
70
  test_files: []
metadata.gz.sig CHANGED
Binary file