taiwanese_id_validator 0.0.1 → 0.0.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/CHANGELOG.md +14 -0
- data/DEVELOPMENT.md +37 -0
- data/README.md +26 -16
- data/lib/international_id_validator/itid_mapping.rb +13 -0
- data/lib/international_id_validator/itid_validator.rb +32 -0
- data/lib/international_id_validator.rb +25 -0
- data/lib/taiwanese_id_validator/twid_validator.rb +3 -0
- data/lib/taiwanese_id_validator.rb +1 -1
- data/spec/international_id_validator/itid_validator_spec.rb +40 -0
- data/spec/international_id_validator_spec.rb +71 -0
- data/spec/spec_helper.rb +2 -1
- data/spec/taiwanese_id_validator/twid_validator_spec.rb +9 -4
- data/spec/taiwanese_id_validator_spec.rb +9 -9
- data/taiwanese_id_validator.gemspec +4 -4
- metadata +18 -12
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: 4369f6bf917fbd32056fcb9084fd6640a083f6cea7449d0212e3d87c5830f35e
|
4
|
+
data.tar.gz: 9bd602649636f06c50ca11a22930f7621a414285ab1a447f5927a6113946b9dd
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 8350403c7f2e5d6e80d62a193aa2d5fb46d896c07b0914309c6c718e8919123496a72550b8c321cd8596bf56cb93f09dfb197cb0738ed160c4f16cf9bcee5598
|
7
|
+
data.tar.gz: 11e07f4a93b054b8c47487a8d7e1891f880f1c35be44640e707f17f9abfb2af5c0d03b2477376b43a0556ad7d4329b49fbf8bc0cfc4ee840eddd927d56484c50
|
data/CHANGELOG.md
ADDED
@@ -0,0 +1,14 @@
|
|
1
|
+
# Changelog
|
2
|
+
|
3
|
+
## V0.0.3
|
4
|
+
|
5
|
+
- Fix `TwidValidator.valid?(nil)` raise Error problem [PR#3](https://github.com/wayne5540/taiwanese_id_validator/pull/3)
|
6
|
+
|
7
|
+
## V0.0.2
|
8
|
+
|
9
|
+
- Support new International ID format [PR#1](https://github.com/wayne5540/taiwanese_id_validator/pull/1)
|
10
|
+
- Upgrade bundler dependency, now requires version >= 2.2.33
|
11
|
+
|
12
|
+
## V0.0.1
|
13
|
+
|
14
|
+
First version
|
data/DEVELOPMENT.md
ADDED
@@ -0,0 +1,37 @@
|
|
1
|
+
## Get Started
|
2
|
+
|
3
|
+
1. Fork it ( https://github.com/[my-github-username]/taiwanese_id_validator/fork )
|
4
|
+
2. Create your feature branch (`git checkout -b my-new-feature`)
|
5
|
+
3. Commit your changes (`git commit -am 'Add some feature'`)
|
6
|
+
4. Push to the branch (`git push origin my-new-feature`)
|
7
|
+
5. Create a new Pull Request
|
8
|
+
|
9
|
+
## Run Tests
|
10
|
+
|
11
|
+
`rspec`
|
12
|
+
|
13
|
+
## Build the gem
|
14
|
+
|
15
|
+
Build the gem:
|
16
|
+
|
17
|
+
```
|
18
|
+
gem build taiwanese_id_validator.gemspec
|
19
|
+
```
|
20
|
+
|
21
|
+
Install the gem, change the version name if needed
|
22
|
+
|
23
|
+
```
|
24
|
+
gem install ./taiwanese_id_validator-0.0.3.gem
|
25
|
+
```
|
26
|
+
|
27
|
+
Push to RubyGem
|
28
|
+
|
29
|
+
```
|
30
|
+
gem push ./taiwanese_id_validator-0.0.3.gem
|
31
|
+
```
|
32
|
+
|
33
|
+
More details about how to make the gem including build, install, push can be found [here](https://guides.rubygems.org/make-your-own-gem/)
|
34
|
+
|
35
|
+
## TODOs
|
36
|
+
|
37
|
+
- Support Chinese ID Validation
|
data/README.md
CHANGED
@@ -6,10 +6,10 @@
|
|
6
6
|
|
7
7
|
## Features
|
8
8
|
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
9
|
+
- Rails model 內驗證 (Rails 3+/4/5/6/7)
|
10
|
+
- Rails model 外驗證
|
11
|
+
- 新式統一證號驗證
|
12
|
+
- 產生符合格式的身分證字號,可選擇男女
|
13
13
|
|
14
14
|
## Installation
|
15
15
|
|
@@ -39,7 +39,7 @@ end
|
|
39
39
|
|
40
40
|
#### Options
|
41
41
|
|
42
|
-
|
42
|
+
- `allow_nil` or `allow_blank`
|
43
43
|
|
44
44
|
```ruby
|
45
45
|
class User < ActiveRecord::Base
|
@@ -47,7 +47,7 @@ class User < ActiveRecord::Base
|
|
47
47
|
end
|
48
48
|
```
|
49
49
|
|
50
|
-
|
50
|
+
- Case sensitive, default is true
|
51
51
|
|
52
52
|
```ruby
|
53
53
|
class User < ActiveRecord::Base
|
@@ -55,7 +55,6 @@ class User < ActiveRecord::Base
|
|
55
55
|
end
|
56
56
|
```
|
57
57
|
|
58
|
-
|
59
58
|
### Validation outside the model
|
60
59
|
|
61
60
|
#### 驗證身分證字號
|
@@ -70,10 +69,16 @@ TwidValidator.valid?('A123456777') #=> false
|
|
70
69
|
|
71
70
|
#### 產生假身分證字號
|
72
71
|
|
72
|
+
Generator 是沒有被自動 require 的,所以要使用前要先 require:
|
73
|
+
|
73
74
|
```ruby
|
75
|
+
require 'taiwanese_id_validator/twid_generator'
|
76
|
+
|
74
77
|
TwidGenerator.generate #=> 隨機產生身分證字號
|
75
78
|
```
|
76
79
|
|
80
|
+
可以指定要產生男性或是女性的身分證字號
|
81
|
+
|
77
82
|
```ruby
|
78
83
|
TwidGenerator.generate("male") #=> 男性的身分證字號
|
79
84
|
```
|
@@ -82,20 +87,25 @@ TwidGenerator.generate("male") #=> 男性的身分證字號
|
|
82
87
|
TwidGenerator.generate("female") #=> 女性的身分證字號
|
83
88
|
```
|
84
89
|
|
85
|
-
|
90
|
+
#### 驗證統一證號
|
91
|
+
|
92
|
+
```ruby
|
93
|
+
ItidValidator.valid?('A800000014') #=> true
|
94
|
+
```
|
86
95
|
|
87
|
-
|
96
|
+
```ruby
|
97
|
+
ItidValidator.valid?('A800000015') #=> false
|
98
|
+
```
|
88
99
|
|
100
|
+
## Others
|
89
101
|
|
90
|
-
|
102
|
+
- [身分證公式](https://zh.wikipedia.org/wiki/%E4%B8%AD%E8%8F%AF%E6%B0%91%E5%9C%8B%E5%9C%8B%E6%B0%91%E8%BA%AB%E5%88%86%E8%AD%89)
|
103
|
+
- [新式統一證號](https://zh.wikipedia.org/wiki/%E4%B8%AD%E8%8F%AF%E6%B0%91%E5%9C%8B%E5%B1%85%E7%95%99%E8%AD%89)
|
91
104
|
|
92
|
-
|
93
|
-
2. Create your feature branch (`git checkout -b my-new-feature`)
|
94
|
-
3. Commit your changes (`git commit -am 'Add some feature'`)
|
95
|
-
4. Push to the branch (`git push origin my-new-feature`)
|
96
|
-
5. Create a new Pull Request
|
105
|
+
## Contributing
|
97
106
|
|
107
|
+
Check [DEVELOPMENT.md](DEVELOPMENT.md)
|
98
108
|
|
99
109
|
## LICENSE
|
100
110
|
|
101
|
-
This project rocks and uses MIT-LICENSE.
|
111
|
+
This project rocks and uses MIT-LICENSE.
|
@@ -0,0 +1,13 @@
|
|
1
|
+
module ItidMapping
|
2
|
+
ITID_LETTER = {
|
3
|
+
"A" => [1, 0], "B" => [1, 1], "C" => [1, 2], "D" => [1, 3],
|
4
|
+
"E" => [1, 4], "F" => [1, 5], "G" => [1, 6], "H" => [1, 7],
|
5
|
+
"I" => [3, 4], "J" => [1, 8], "K" => [1, 9], "L" => [2, 0],
|
6
|
+
"M" => [2, 1], "N" => [2, 2], "O" => [3, 5], "P" => [2, 3],
|
7
|
+
"Q" => [2, 4], "R" => [2, 5], "S" => [2, 6], "T" => [2, 7],
|
8
|
+
"U" => [2, 8], "V" => [2, 9], "W" => [3, 2], "X" => [3, 0],
|
9
|
+
"Y" => [3, 1], "Z" => [3, 3]
|
10
|
+
}
|
11
|
+
|
12
|
+
MULTIPLIER = [1,9,8,7,6,5,4,3,2,1].freeze
|
13
|
+
end
|
@@ -0,0 +1,32 @@
|
|
1
|
+
require 'international_id_validator/itid_mapping'
|
2
|
+
|
3
|
+
module ItidValidator
|
4
|
+
def self.valid?(itid, case_sensitive = true, allow_old = false)
|
5
|
+
return false if !itid
|
6
|
+
return false if !itid.is_a?(String)
|
7
|
+
|
8
|
+
itid = itid.upcase unless case_sensitive
|
9
|
+
|
10
|
+
return false if itid.length != 10
|
11
|
+
return true if allow_old && itid.match?(/\A[A-Z][ABCD]\d{8}\z/)
|
12
|
+
return false unless itid.match?(/[A-Z](8|9)\d{8}\z/)
|
13
|
+
|
14
|
+
characters = itid.chars
|
15
|
+
digits = ItidMapping::ITID_LETTER[characters.shift] + characters.map(&:to_i)
|
16
|
+
|
17
|
+
checked_num = calculate_checked_num(digits)
|
18
|
+
|
19
|
+
return checked_num == digits.last
|
20
|
+
end
|
21
|
+
|
22
|
+
private
|
23
|
+
|
24
|
+
def self.calculate_checked_num(digits)
|
25
|
+
sum = 0
|
26
|
+
10.times do |i|
|
27
|
+
m = digits[i] * ItidMapping::MULTIPLIER[i]
|
28
|
+
sum += (m % 10)
|
29
|
+
end
|
30
|
+
10 - (sum % 10)
|
31
|
+
end
|
32
|
+
end
|
@@ -0,0 +1,25 @@
|
|
1
|
+
require "international_id_validator/itid_validator"
|
2
|
+
|
3
|
+
class InternationalIdValidator < ActiveModel::EachValidator
|
4
|
+
def validate_each(record, attribute, value)
|
5
|
+
return if skip_check?
|
6
|
+
|
7
|
+
unless ItidValidator.valid?(value, case_sensitive?, allow_old?)
|
8
|
+
record.errors.add(attribute, (options[:message] || "is not a valid ID"))
|
9
|
+
end
|
10
|
+
end
|
11
|
+
|
12
|
+
private
|
13
|
+
|
14
|
+
def skip_check?
|
15
|
+
options[:allow_nil].present? || options[:allow_blank].present?
|
16
|
+
end
|
17
|
+
|
18
|
+
def case_sensitive?
|
19
|
+
options[:case_sensitive].nil? ? true : options[:case_sensitive]
|
20
|
+
end
|
21
|
+
|
22
|
+
def allow_old?
|
23
|
+
options[:allow_old].nil? ? false : options[:allow_old]
|
24
|
+
end
|
25
|
+
end
|
@@ -5,7 +5,7 @@ class TaiwaneseIdValidator < ActiveModel::EachValidator
|
|
5
5
|
return if skip_check?
|
6
6
|
|
7
7
|
unless TwidValidator.valid?(value, case_sensitive?)
|
8
|
-
record.errors
|
8
|
+
record.errors.add(attribute, (options[:message] || "is not a valid ID"))
|
9
9
|
end
|
10
10
|
end
|
11
11
|
|
@@ -0,0 +1,40 @@
|
|
1
|
+
require 'spec_helper'
|
2
|
+
|
3
|
+
describe ItidValidator do
|
4
|
+
|
5
|
+
describe "#valid?" do
|
6
|
+
context "when id not valid" do
|
7
|
+
it "returns false if id too short" do
|
8
|
+
expect( ItidValidator.valid?("A8000") ).to be false
|
9
|
+
end
|
10
|
+
|
11
|
+
it "returns false if id too long" do
|
12
|
+
expect( ItidValidator.valid?("A800000014111") ).to be false
|
13
|
+
end
|
14
|
+
|
15
|
+
it "returns false if id calculation is wrong" do
|
16
|
+
expect( ItidValidator.valid?("A800000013") ).to be false
|
17
|
+
end
|
18
|
+
|
19
|
+
it "returns false if format is wrong" do
|
20
|
+
expect( ItidValidator.valid?("YAC4713412") ).to be false
|
21
|
+
end
|
22
|
+
|
23
|
+
it "returns false if id is nil" do
|
24
|
+
expect( ItidValidator.valid?(nil) ).to be false
|
25
|
+
end
|
26
|
+
|
27
|
+
it "returns false if id is nil" do
|
28
|
+
expect( ItidValidator.valid?(1) ).to be false
|
29
|
+
end
|
30
|
+
end
|
31
|
+
|
32
|
+
context "when id is valid" do
|
33
|
+
let(:id) { "A800000014" }
|
34
|
+
|
35
|
+
it "returns true" do
|
36
|
+
expect( ItidValidator.valid?(id) ).to be true
|
37
|
+
end
|
38
|
+
end
|
39
|
+
end
|
40
|
+
end
|
@@ -0,0 +1,71 @@
|
|
1
|
+
require 'spec_helper'
|
2
|
+
|
3
|
+
class ItTestUser < TestModel
|
4
|
+
validates :itid, international_id: true
|
5
|
+
end
|
6
|
+
|
7
|
+
class ItTestUserAllowsNil < TestModel
|
8
|
+
validates :itid, international_id: { allow_nil: true }
|
9
|
+
end
|
10
|
+
|
11
|
+
class ItTestUserNoCaseSensitive < TestModel
|
12
|
+
validates :itid, international_id: { case_sensitive: false }
|
13
|
+
end
|
14
|
+
|
15
|
+
class ItTestUserAllowOld < TestModel
|
16
|
+
validates :itid, international_id: { allow_old: true }
|
17
|
+
end
|
18
|
+
|
19
|
+
describe InternationalIdValidator do
|
20
|
+
describe "validation" do
|
21
|
+
context "given the valid new IDs" do
|
22
|
+
[
|
23
|
+
"A800000014"
|
24
|
+
].each do |itid|
|
25
|
+
it "#{itid} should be valid" do
|
26
|
+
expect(ItTestUser.new(itid: itid)).to be_valid
|
27
|
+
end
|
28
|
+
|
29
|
+
it "#{itid} should be valid" do
|
30
|
+
expect(ItTestUserAllowsNil.new(itid: nil)).to be_valid
|
31
|
+
end
|
32
|
+
|
33
|
+
it "#{itid} should be valid" do
|
34
|
+
expect(ItTestUserNoCaseSensitive.new(itid: itid.downcase)).to be_valid
|
35
|
+
end
|
36
|
+
|
37
|
+
it "#{itid} should be valid" do
|
38
|
+
expect(ItTestUserNoCaseSensitive.new(itid: itid.downcase)).to be_valid
|
39
|
+
end
|
40
|
+
end
|
41
|
+
end
|
42
|
+
|
43
|
+
context "given the valid old IDs" do
|
44
|
+
[
|
45
|
+
"AD00000016"
|
46
|
+
].each do |itid|
|
47
|
+
it "#{itid} should not be valid" do
|
48
|
+
expect(ItTestUser.new(itid: itid)).not_to be_valid
|
49
|
+
end
|
50
|
+
|
51
|
+
it "#{itid} should be valid" do
|
52
|
+
expect(ItTestUserAllowOld.new(itid: itid)).to be_valid
|
53
|
+
end
|
54
|
+
end
|
55
|
+
end
|
56
|
+
|
57
|
+
context "given the invalid IDs" do
|
58
|
+
[
|
59
|
+
"A8000014",
|
60
|
+
"A80000001411",
|
61
|
+
"Aa00000014",
|
62
|
+
"A800000015",
|
63
|
+
"a800000014"
|
64
|
+
].each do |itid|
|
65
|
+
it "#{itid} should not be valid" do
|
66
|
+
expect(ItTestUser.new(itid: itid)).not_to be_valid
|
67
|
+
end
|
68
|
+
end
|
69
|
+
end
|
70
|
+
end
|
71
|
+
end
|
data/spec/spec_helper.rb
CHANGED
@@ -6,6 +6,7 @@ $LOAD_PATH.unshift(File.join(File.dirname(__FILE__), '..', 'lib'))
|
|
6
6
|
$LOAD_PATH.unshift(File.dirname(__FILE__))
|
7
7
|
|
8
8
|
require 'taiwanese_id_validator'
|
9
|
+
require 'international_id_validator'
|
9
10
|
|
10
11
|
class TestModel
|
11
12
|
include ActiveModel::Validations
|
@@ -17,4 +18,4 @@ class TestModel
|
|
17
18
|
def read_attribute_for_validation(key)
|
18
19
|
@attributes[key]
|
19
20
|
end
|
20
|
-
end
|
21
|
+
end
|
@@ -19,6 +19,14 @@ describe TwidValidator do
|
|
19
19
|
it "returns false if format is wrong" do
|
20
20
|
expect( TwidValidator.valid?("YAC4713412") ).to be false
|
21
21
|
end
|
22
|
+
|
23
|
+
it "returns false if id is nil" do
|
24
|
+
expect( TwidValidator.valid?(nil) ).to be false
|
25
|
+
end
|
26
|
+
|
27
|
+
it "returns false if id is nil" do
|
28
|
+
expect( TwidValidator.valid?(1) ).to be false
|
29
|
+
end
|
22
30
|
end
|
23
31
|
|
24
32
|
context "when id is valid" do
|
@@ -28,8 +36,5 @@ describe TwidValidator do
|
|
28
36
|
expect( TwidValidator.valid?(id) ).to be true
|
29
37
|
end
|
30
38
|
end
|
31
|
-
|
32
|
-
pending "case sensative"
|
33
39
|
end
|
34
|
-
|
35
|
-
end
|
40
|
+
end
|
@@ -1,14 +1,14 @@
|
|
1
1
|
require 'spec_helper'
|
2
2
|
|
3
|
-
class
|
3
|
+
class TwTestUser < TestModel
|
4
4
|
validates :twid, taiwanese_id: true
|
5
5
|
end
|
6
6
|
|
7
|
-
class
|
7
|
+
class TwTestUserAllowsNil < TestModel
|
8
8
|
validates :twid, taiwanese_id: { allow_nil: true }
|
9
9
|
end
|
10
10
|
|
11
|
-
class
|
11
|
+
class TwTestUserNoCaseSensitive < TestModel
|
12
12
|
validates :twid, taiwanese_id: { case_sensitive: false }
|
13
13
|
end
|
14
14
|
|
@@ -19,15 +19,15 @@ describe TaiwaneseIdValidator do
|
|
19
19
|
"Y144713411"
|
20
20
|
].each do |twid|
|
21
21
|
it "#{twid} should be valid" do
|
22
|
-
expect(
|
22
|
+
expect(TwTestUser.new(twid: twid)).to be_valid
|
23
23
|
end
|
24
24
|
|
25
25
|
it "#{twid} should be valid" do
|
26
|
-
expect(
|
26
|
+
expect(TwTestUserAllowsNil.new(twid: nil)).to be_valid
|
27
27
|
end
|
28
28
|
|
29
29
|
it "#{twid} should be valid" do
|
30
|
-
expect(
|
30
|
+
expect(TwTestUserNoCaseSensitive.new(twid: twid.downcase)).to be_valid
|
31
31
|
end
|
32
32
|
end
|
33
33
|
end
|
@@ -40,10 +40,10 @@ describe TaiwaneseIdValidator do
|
|
40
40
|
"Y144713410",
|
41
41
|
"y144713411"
|
42
42
|
].each do |twid|
|
43
|
-
it "#{twid} should be valid" do
|
44
|
-
expect(
|
43
|
+
it "#{twid} should not be valid" do
|
44
|
+
expect(TwTestUser.new(twid: twid)).not_to be_valid
|
45
45
|
end
|
46
46
|
end
|
47
47
|
end
|
48
48
|
end
|
49
|
-
end
|
49
|
+
end
|
@@ -1,11 +1,11 @@
|
|
1
1
|
Gem::Specification.new do |spec|
|
2
2
|
spec.name = "taiwanese_id_validator"
|
3
|
-
spec.version = "0.0.
|
3
|
+
spec.version = "0.0.3"
|
4
4
|
spec.authors = ["Wayne Chu"]
|
5
5
|
spec.email = ["wayne.5540@gmail.com"]
|
6
6
|
spec.summary = "Taiwanese Id Validator."
|
7
7
|
spec.description = "Taiwanese Id Validator"
|
8
|
-
spec.homepage = ""
|
8
|
+
spec.homepage = "https://github.com/wayne5540/taiwanese_id_validator"
|
9
9
|
spec.license = "MIT"
|
10
10
|
spec.files = `git ls-files`.split("\n")
|
11
11
|
spec.test_files = `git ls-files -- {spec}/*`.split("\n")
|
@@ -14,7 +14,7 @@ Gem::Specification.new do |spec|
|
|
14
14
|
|
15
15
|
spec.add_dependency "activemodel"
|
16
16
|
|
17
|
-
spec.add_development_dependency "bundler", "
|
17
|
+
spec.add_development_dependency "bundler", ">= 2.2.33"
|
18
18
|
spec.add_development_dependency "rake"
|
19
19
|
spec.add_development_dependency "rspec"
|
20
|
-
end
|
20
|
+
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: taiwanese_id_validator
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Wayne Chu
|
8
|
-
autorequire:
|
8
|
+
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2024-01-28 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activemodel
|
@@ -28,16 +28,16 @@ dependencies:
|
|
28
28
|
name: bundler
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
30
30
|
requirements:
|
31
|
-
- - "
|
31
|
+
- - ">="
|
32
32
|
- !ruby/object:Gem::Version
|
33
|
-
version:
|
33
|
+
version: 2.2.33
|
34
34
|
type: :development
|
35
35
|
prerelease: false
|
36
36
|
version_requirements: !ruby/object:Gem::Requirement
|
37
37
|
requirements:
|
38
|
-
- - "
|
38
|
+
- - ">="
|
39
39
|
- !ruby/object:Gem::Version
|
40
|
-
version:
|
40
|
+
version: 2.2.33
|
41
41
|
- !ruby/object:Gem::Dependency
|
42
42
|
name: rake
|
43
43
|
requirement: !ruby/object:Gem::Requirement
|
@@ -75,24 +75,31 @@ extra_rdoc_files: []
|
|
75
75
|
files:
|
76
76
|
- ".gitignore"
|
77
77
|
- ".travis.yml"
|
78
|
+
- CHANGELOG.md
|
79
|
+
- DEVELOPMENT.md
|
78
80
|
- Gemfile
|
79
81
|
- LICENSE.txt
|
80
82
|
- README.md
|
81
83
|
- Rakefile
|
84
|
+
- lib/international_id_validator.rb
|
85
|
+
- lib/international_id_validator/itid_mapping.rb
|
86
|
+
- lib/international_id_validator/itid_validator.rb
|
82
87
|
- lib/taiwanese_id_validator.rb
|
83
88
|
- lib/taiwanese_id_validator/twid_generator.rb
|
84
89
|
- lib/taiwanese_id_validator/twid_mapping.rb
|
85
90
|
- lib/taiwanese_id_validator/twid_validator.rb
|
91
|
+
- spec/international_id_validator/itid_validator_spec.rb
|
92
|
+
- spec/international_id_validator_spec.rb
|
86
93
|
- spec/spec_helper.rb
|
87
94
|
- spec/taiwanese_id_validator/twid_generator_spec.rb
|
88
95
|
- spec/taiwanese_id_validator/twid_validator_spec.rb
|
89
96
|
- spec/taiwanese_id_validator_spec.rb
|
90
97
|
- taiwanese_id_validator.gemspec
|
91
|
-
homepage:
|
98
|
+
homepage: https://github.com/wayne5540/taiwanese_id_validator
|
92
99
|
licenses:
|
93
100
|
- MIT
|
94
101
|
metadata: {}
|
95
|
-
post_install_message:
|
102
|
+
post_install_message:
|
96
103
|
rdoc_options: []
|
97
104
|
require_paths:
|
98
105
|
- lib
|
@@ -107,9 +114,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
107
114
|
- !ruby/object:Gem::Version
|
108
115
|
version: '0'
|
109
116
|
requirements: []
|
110
|
-
|
111
|
-
|
112
|
-
signing_key:
|
117
|
+
rubygems_version: 3.4.10
|
118
|
+
signing_key:
|
113
119
|
specification_version: 4
|
114
120
|
summary: Taiwanese Id Validator.
|
115
121
|
test_files: []
|