basecustom 0.1.8 → 1.0.0
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 +5 -13
- data/README.md +67 -65
- data/lib/basecustom/version.rb +3 -1
- metadata +7 -7
checksums.yaml
CHANGED
@@ -1,15 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
|
5
|
-
data.tar.gz: !binary |-
|
6
|
-
ZWRiNDFiY2NkNDBjYTMyNDk0NDRiYzNhMmNkYTA3MjZkMzUwYmQzOA==
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: 1518a7c42b93431aca84dae5aed485f57a41d3d9
|
4
|
+
data.tar.gz: 43f26a363cf54eeb8e27c0147fbe07512fbb2a11
|
7
5
|
SHA512:
|
8
|
-
metadata.gz:
|
9
|
-
|
10
|
-
M2QzNjBiMmUwM2RlZjg0YjM5Njk5NTJmNzAzMTg2Nzg3YTljNWMwMzc5OTE1
|
11
|
-
YzQ5YTNmNzc4MmI3ZWMyOGUxNWY0NWQxMzc2OWJjNjI3NWMwNWI=
|
12
|
-
data.tar.gz: !binary |-
|
13
|
-
ZGZiMzE3MzllNDEzMmY0ZmY4YzcyMWVkYjcwMzMzYTFlNzU3OWQyYzFhYTgz
|
14
|
-
YzFiMzEwY2U2YmNmMjE5ZWVmMTE1ODBmZDI4NjU1NTE1OTU3M2QzZmJlZDU2
|
15
|
-
MzViZDk3OGEzZWVhMWU5NTU3Njg2N2YwYzZlZGRlNDA0ZTlhZjI=
|
6
|
+
metadata.gz: df61c42c3452574ebc8c8e20c4a061e349da59f29e6ef92e41f723fe5181b3e90957a4beaf83c224c218cdb47952311a95d06ef369b4fc0053412544b3c7f019
|
7
|
+
data.tar.gz: 18631b343764b359a653d8c324f17c249810585c24323974dc85be958911f9a757d1047c42a8ddc0273bd53c93c1d6e2cb756b6b586acecb5f22fdbc274cee48
|
data/README.md
CHANGED
@@ -1,65 +1,67 @@
|
|
1
|
-
# BaseCustom
|
2
|
-
by Daniel P. Clark
|
3
|
-
|
4
|
-
Inspired by:
|
5
|
-
* base62 by "JT Zemp" and contributors "Saadiq Rodgers-King", "Derrick Camerino"
|
6
|
-
|
7
|
-
**Description**
|
8
|
-
* Define any base conversion with any identifier for each value.
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
*
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
1
|
+
# BaseCustom
|
2
|
+
by Daniel P. Clark
|
3
|
+
|
4
|
+
Inspired by:
|
5
|
+
* base62 by "JT Zemp" and contributors "Saadiq Rodgers-King", "Derrick Camerino"
|
6
|
+
|
7
|
+
**Description**
|
8
|
+
* Define any base conversion with any identifier for each value.
|
9
|
+
|
10
|
+
<pre>require "basecustom"
|
11
|
+
|
12
|
+
base2 = BaseCustom.new('01')
|
13
|
+
base2.base('00001')
|
14
|
+
=> 1
|
15
|
+
base2.base('100110101')
|
16
|
+
=> 309
|
17
|
+
base2.base(340)
|
18
|
+
=> "101010100"
|
19
|
+
base2.base(0xF45)
|
20
|
+
=> "111101000101"
|
21
|
+
|
22
|
+
baseABC = BaseCustom.new('ABC')
|
23
|
+
baseABC.base('ABC')
|
24
|
+
=> 5
|
25
|
+
baseABC.base(123)
|
26
|
+
=> "BBBCA"
|
27
|
+
</pre>
|
28
|
+
|
29
|
+
# Usage Video
|
30
|
+
|
31
|
+
[](http://www.youtube.com/embed/b7TdvicxIrs)
|
32
|
+
|
33
|
+
# Version History
|
34
|
+
|
35
|
+
Version 1.0.0
|
36
|
+
* Bump version number. Gem has proven ready as a version 1 release.
|
37
|
+
|
38
|
+
Version 0.1.8
|
39
|
+
* Changed .all() to join by delimiter
|
40
|
+
|
41
|
+
Version 0.1.7
|
42
|
+
* Added features .length() and .all()
|
43
|
+
|
44
|
+
Version 0.1.6
|
45
|
+
* Fixed 0 as 0 bug.
|
46
|
+
|
47
|
+
Version 0.1.5
|
48
|
+
* Added jmchambers' debug from jtzemp/base62 to avoid infinite loop in Rails 3.0.7
|
49
|
+
|
50
|
+
Version 0.1.4
|
51
|
+
* My father suggested delimiter splitting on String initialization made more sense.
|
52
|
+
* Test-Unit assertions fixed/updated.
|
53
|
+
|
54
|
+
Version 0.1.3
|
55
|
+
* Fixed multicharacter numbering units
|
56
|
+
* Added delimiter for multicharacter numbering units
|
57
|
+
* Safe base type creation. Each situation checked for and proper error messages.
|
58
|
+
|
59
|
+
Version 0.1.2
|
60
|
+
* Added unique to string init declaration
|
61
|
+
* Added unique to array as well as checking that all array elements are strings
|
62
|
+
|
63
|
+
Version 0.1.1
|
64
|
+
* Flatten array's on input initialization
|
65
|
+
|
66
|
+
Version 0.1.0
|
67
|
+
* Complete Release
|
data/lib/basecustom/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: basecustom
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 1.0.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Daniel P. Clark / 6ftDan(TM)
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-
|
11
|
+
date: 2014-07-12 00:00:00.000000000 Z
|
12
12
|
dependencies: []
|
13
13
|
description: Define your own numberic base! Highly advanced and ultimately simple!
|
14
14
|
email: webmaster@6ftdan.com
|
@@ -25,23 +25,23 @@ homepage: https://rubygems.org/gems/basecustom
|
|
25
25
|
licenses:
|
26
26
|
- The MIT License (MIT)
|
27
27
|
metadata: {}
|
28
|
-
post_install_message:
|
28
|
+
post_install_message:
|
29
29
|
rdoc_options: []
|
30
30
|
require_paths:
|
31
31
|
- lib
|
32
32
|
required_ruby_version: !ruby/object:Gem::Requirement
|
33
33
|
requirements:
|
34
|
-
- -
|
34
|
+
- - ">="
|
35
35
|
- !ruby/object:Gem::Version
|
36
|
-
version: '
|
36
|
+
version: '1.8'
|
37
37
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
38
38
|
requirements:
|
39
|
-
- -
|
39
|
+
- - ">="
|
40
40
|
- !ruby/object:Gem::Version
|
41
41
|
version: '0'
|
42
42
|
requirements: []
|
43
43
|
rubyforge_project:
|
44
|
-
rubygems_version: 2.
|
44
|
+
rubygems_version: 2.3.0
|
45
45
|
signing_key:
|
46
46
|
specification_version: 4
|
47
47
|
summary: Define your own numberic base!
|