moca_rlibs 0.0.8 → 0.0.9

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: feea6203c6583ea008e12222e3392f0d9c2dcf1632c29c9984320464e2c26d6d
4
- data.tar.gz: df4085914926e57d3126d00cd0b85759aebe3b6cab4794a9da973dc70f2b723d
3
+ metadata.gz: 3c202c01ae7a990ee27e861b804435a952a46beb50bc981b427394079b0c8703
4
+ data.tar.gz: 0befa50c7ce356cc7b0fc9d43e57c65363914f6055581a22dfada5aa42aafa2a
5
5
  SHA512:
6
- metadata.gz: 69a25352440a1b39b5c46599fbe650eb189d590a5ed9c28a9cb7d604b0bc871400e56d39673beb08a6dd8e0fb9b848e56a63748d301b56107f2f198c099546ef
7
- data.tar.gz: f098c4923f4723d24805a8a950f97ab82b2a4608bc239385e2e1bd0229eca11f1384c0a3d3270af1405d66f6dc5e02733ba361894c26fa58571cbbeadf7650c1
6
+ metadata.gz: 5232468e7c008b386bdb162fbe4396c351d86e71a89d9c98893500fc6bc5d788a7e9da3d8b9583738256b0777a0d2cdabb68c9b34480f2a586ac488b5485d358
7
+ data.tar.gz: 51871849c50b6097825e3a3365eba897407ca395e8130e15f9cc1d2d889a30f60f60552241a1336ee21001852151ea420eb0c0523004c25e9c1f0a052636581b
data/.idea/rlibs.iml CHANGED
@@ -17,6 +17,7 @@
17
17
  <orderEntry type="library" scope="PROVIDED" name="ast (v2.4.2, rbenv: 3.0.2) [gem]" level="application" />
18
18
  <orderEntry type="library" scope="PROVIDED" name="builder (v3.2.4, rbenv: 3.0.2) [gem]" level="application" />
19
19
  <orderEntry type="library" scope="PROVIDED" name="bundler (v2.2.22, rbenv: 3.0.2) [gem]" level="application" />
20
+ <orderEntry type="library" scope="PROVIDED" name="codecov (v0.6.0, rbenv: 3.0.2) [gem]" level="application" />
20
21
  <orderEntry type="library" scope="PROVIDED" name="concurrent-ruby (v1.1.9, rbenv: 3.0.2) [gem]" level="application" />
21
22
  <orderEntry type="library" scope="PROVIDED" name="diff-lcs (v1.4.4, rbenv: 3.0.2) [gem]" level="application" />
22
23
  <orderEntry type="library" scope="PROVIDED" name="docile (v1.4.0, rbenv: 3.0.2) [gem]" level="application" />
@@ -39,14 +40,15 @@
39
40
  <orderEntry type="library" scope="PROVIDED" name="rack-test (v1.1.0, rbenv: 3.0.2) [gem]" level="application" />
40
41
  <orderEntry type="library" scope="PROVIDED" name="rainbow (v3.0.0, rbenv: 3.0.2) [gem]" level="application" />
41
42
  <orderEntry type="library" scope="PROVIDED" name="rake (v13.0.6, rbenv: 3.0.2) [gem]" level="application" />
42
- <orderEntry type="library" scope="PROVIDED" name="regexp_parser (v2.1.1, rbenv: 3.0.2) [gem]" level="application" />
43
+ <orderEntry type="library" scope="PROVIDED" name="regexp_parser (v2.2.0, rbenv: 3.0.2) [gem]" level="application" />
43
44
  <orderEntry type="library" scope="PROVIDED" name="rexml (v3.2.5, rbenv: 3.0.2) [gem]" level="application" />
45
+ <orderEntry type="library" scope="PROVIDED" name="rspec (v3.10.0, rbenv: 3.0.2) [gem]" level="application" />
44
46
  <orderEntry type="library" scope="PROVIDED" name="rspec-core (v3.10.1, rbenv: 3.0.2) [gem]" level="application" />
45
47
  <orderEntry type="library" scope="PROVIDED" name="rspec-expectations (v3.10.1, rbenv: 3.0.2) [gem]" level="application" />
46
48
  <orderEntry type="library" scope="PROVIDED" name="rspec-mocks (v3.10.2, rbenv: 3.0.2) [gem]" level="application" />
47
49
  <orderEntry type="library" scope="PROVIDED" name="rspec-support (v3.10.3, rbenv: 3.0.2) [gem]" level="application" />
48
50
  <orderEntry type="library" scope="PROVIDED" name="rubocop (v1.23.0, rbenv: 3.0.2) [gem]" level="application" />
49
- <orderEntry type="library" scope="PROVIDED" name="rubocop-ast (v1.13.0, rbenv: 3.0.2) [gem]" level="application" />
51
+ <orderEntry type="library" scope="PROVIDED" name="rubocop-ast (v1.14.0, rbenv: 3.0.2) [gem]" level="application" />
50
52
  <orderEntry type="library" scope="PROVIDED" name="rubocop-performance (v1.12.0, rbenv: 3.0.2) [gem]" level="application" />
51
53
  <orderEntry type="library" scope="PROVIDED" name="rubocop-rails (v2.12.4, rbenv: 3.0.2) [gem]" level="application" />
52
54
  <orderEntry type="library" scope="PROVIDED" name="rubocop-rspec (v2.6.0, rbenv: 3.0.2) [gem]" level="application" />
@@ -56,6 +58,7 @@
56
58
  <orderEntry type="library" scope="PROVIDED" name="simplecov-html (v0.12.3, rbenv: 3.0.2) [gem]" level="application" />
57
59
  <orderEntry type="library" scope="PROVIDED" name="simplecov_json_formatter (v0.1.3, rbenv: 3.0.2) [gem]" level="application" />
58
60
  <orderEntry type="library" scope="PROVIDED" name="slack-notifier (v2.4.0, rbenv: 3.0.2) [gem]" level="application" />
61
+ <orderEntry type="library" scope="PROVIDED" name="sqlite3 (v1.4.2, rbenv: 3.0.2) [gem]" level="application" />
59
62
  <orderEntry type="library" scope="PROVIDED" name="tzinfo (v2.0.4, rbenv: 3.0.2) [gem]" level="application" />
60
63
  <orderEntry type="library" scope="PROVIDED" name="unicode-display_width (v2.1.0, rbenv: 3.0.2) [gem]" level="application" />
61
64
  <orderEntry type="library" scope="PROVIDED" name="zeitwerk (v2.5.1, rbenv: 3.0.2) [gem]" level="application" />
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- moca_rlibs (0.0.8)
4
+ moca_rlibs (0.0.9)
5
5
  activemodel
6
6
  activerecord
7
7
  activesupport
@@ -12,23 +12,22 @@ PATH
12
12
  GEM
13
13
  remote: https://rubygems.org/
14
14
  specs:
15
- activemodel (6.1.4.1)
16
- activesupport (= 6.1.4.1)
17
- activerecord (6.1.4.1)
18
- activemodel (= 6.1.4.1)
19
- activesupport (= 6.1.4.1)
20
- activesupport (6.1.4.1)
15
+ activemodel (7.0.0)
16
+ activesupport (= 7.0.0)
17
+ activerecord (7.0.0)
18
+ activemodel (= 7.0.0)
19
+ activesupport (= 7.0.0)
20
+ activesupport (7.0.0)
21
21
  concurrent-ruby (~> 1.0, >= 1.0.2)
22
22
  i18n (>= 1.6, < 2)
23
23
  minitest (>= 5.1)
24
24
  tzinfo (~> 2.0)
25
- zeitwerk (~> 2.3)
26
25
  ast (2.4.2)
27
26
  builder (3.2.4)
28
27
  codecov (0.6.0)
29
28
  simplecov (>= 0.15, < 0.22)
30
29
  concurrent-ruby (1.1.9)
31
- diff-lcs (1.4.4)
30
+ diff-lcs (1.5.0)
32
31
  docile (1.4.0)
33
32
  dry-configurable (0.13.0)
34
33
  concurrent-ruby (~> 1.0)
@@ -50,7 +49,7 @@ GEM
50
49
  dry-logic (~> 1.0, >= 1.0.2)
51
50
  email_validator (2.2.3)
52
51
  activemodel
53
- grape (1.6.0)
52
+ grape (1.6.2)
54
53
  activesupport
55
54
  builder
56
55
  dry-types (>= 1.1)
@@ -59,13 +58,13 @@ GEM
59
58
  rack-accept
60
59
  i18n (1.8.11)
61
60
  concurrent-ruby (~> 1.0)
62
- minitest (5.14.4)
61
+ minitest (5.15.0)
63
62
  mustermann (1.1.1)
64
63
  ruby2_keywords (~> 0.0.1)
65
64
  mustermann-grape (1.0.1)
66
65
  mustermann (>= 1.0.0)
67
66
  parallel (1.21.0)
68
- parser (3.0.3.1)
67
+ parser (3.0.3.2)
69
68
  ast (~> 2.4.1)
70
69
  rack (2.2.3)
71
70
  rack-accept (0.4.5)
@@ -89,25 +88,25 @@ GEM
89
88
  diff-lcs (>= 1.2.0, < 2.0)
90
89
  rspec-support (~> 3.10.0)
91
90
  rspec-support (3.10.3)
92
- rubocop (1.23.0)
91
+ rubocop (1.24.0)
93
92
  parallel (~> 1.10)
94
93
  parser (>= 3.0.0.0)
95
94
  rainbow (>= 2.2.2, < 4.0)
96
95
  regexp_parser (>= 1.8, < 3.0)
97
96
  rexml
98
- rubocop-ast (>= 1.12.0, < 2.0)
97
+ rubocop-ast (>= 1.15.0, < 2.0)
99
98
  ruby-progressbar (~> 1.7)
100
99
  unicode-display_width (>= 1.4.0, < 3.0)
101
- rubocop-ast (1.14.0)
100
+ rubocop-ast (1.15.1)
102
101
  parser (>= 3.0.1.1)
103
- rubocop-performance (1.12.0)
102
+ rubocop-performance (1.13.0)
104
103
  rubocop (>= 1.7.0, < 2.0)
105
104
  rubocop-ast (>= 0.4.0)
106
- rubocop-rails (2.12.4)
105
+ rubocop-rails (2.13.0)
107
106
  activesupport (>= 4.2.0)
108
107
  rack (>= 1.1)
109
108
  rubocop (>= 1.7.0, < 2.0)
110
- rubocop-rspec (2.6.0)
109
+ rubocop-rspec (2.7.0)
111
110
  rubocop (~> 1.19)
112
111
  ruby-progressbar (1.11.0)
113
112
  ruby2_keywords (0.0.5)
@@ -122,7 +121,6 @@ GEM
122
121
  tzinfo (2.0.4)
123
122
  concurrent-ruby (~> 1.0)
124
123
  unicode-display_width (2.1.0)
125
- zeitwerk (2.5.1)
126
124
 
127
125
  PLATFORMS
128
126
  arm64-darwin-21
data/README.md CHANGED
@@ -3,6 +3,9 @@
3
3
  [![Build Status](https://codebuild.ap-northeast-1.amazonaws.com/badges?uuid=eyJlbmNyeXB0ZWREYXRhIjoiekhCRy9vSkZhL3BSR1hCV0NvSkc3b3NMcm5MQnlnakkwVFZhWFI1bzZpTzZONmxMeFVLcjNKODhlQWo5ZGtFYmpLcjNQZVFqdzNVZTRBbFFJZ3h1NTNvPSIsIml2UGFyYW1ldGVyU3BlYyI6ImU4dXdib0NpOE1IbHJiYVQiLCJtYXRlcmlhbFNldFNlcmlhbCI6MX0%3D&branch=master)](https://ap-northeast-1.console.aws.amazon.com/codesuite/codebuild/085041388644/projects/rlibs)
4
4
  [![codecov](https://codecov.io/gh/mocaberos/rlibs/branch/master/graph/badge.svg?token=L6SB5CH8KN)](https://codecov.io/gh/mocaberos/rlibs)
5
5
 
6
+ # 注意
7
+ grape 1.6.1以降のバージョンのみ使用可能
8
+
6
9
  ## インストール
7
10
  ```ruby
8
11
  gem 'moca_rlibs'
@@ -15,7 +15,7 @@ module ActiveModel::Validations
15
15
  super
16
16
  end
17
17
 
18
- def validate_each(record, attribute, value)
18
+ def validate_each(record, _attribute, value)
19
19
  return if value.blank?
20
20
 
21
21
  value = value.presence.to_s
@@ -6,7 +6,7 @@ require 'active_support/all'
6
6
  module ActiveModel::Validations
7
7
  # 文字列が半角アルファベットのみであることをチェックする
8
8
  class OnlyAlphaValidator < ActiveModel::EachValidator
9
- def validate_each(record, attribute, value)
9
+ def validate_each(record, _attribute, value)
10
10
  return if value.blank?
11
11
 
12
12
  value = value.presence.to_s
@@ -6,7 +6,7 @@ require 'active_support/all'
6
6
  module ActiveModel::Validations
7
7
  # 文字列が半角英数字のみであることをチェックする
8
8
  class OnlyAlphaNumericValidator < ActiveModel::EachValidator
9
- def validate_each(record, attribute, value)
9
+ def validate_each(record, _attribute, value)
10
10
  return if value.blank?
11
11
 
12
12
  value = value.presence.to_s
@@ -6,7 +6,7 @@ require 'active_support/all'
6
6
  module ActiveModel::Validations
7
7
  # アスキー文字のみを許可する
8
8
  class OnlyAsciiValidator < ActiveModel::EachValidator
9
- def validate_each(record, attribute, value)
9
+ def validate_each(record, _attribute, value)
10
10
  return if value.blank?
11
11
 
12
12
  value = value.presence.to_s
@@ -6,7 +6,7 @@ require 'active_support/all'
6
6
  module ActiveModel::Validations
7
7
  # 文字列が数字のみであることをチェックする
8
8
  class OnlyNumbersValidator < ActiveModel::EachValidator
9
- def validate_each(record, attribute, value)
9
+ def validate_each(record, _attribute, value)
10
10
  return if value.blank?
11
11
 
12
12
  value = value.presence.to_s
@@ -6,7 +6,7 @@ require 'active_support/all'
6
6
  module ActiveModel::Validations
7
7
  # 出力可能なアスキー文字のみかどうかをチェックする(半角英数字+一部の記号)
8
8
  class OnlyPrintableValidator < ActiveModel::EachValidator
9
- def validate_each(record, attribute, value)
9
+ def validate_each(record, _attribute, value)
10
10
  return if value.blank?
11
11
 
12
12
  value = value.presence.to_s
@@ -5,7 +5,7 @@ require 'grape'
5
5
 
6
6
  module MocaRlibs::GrapeValidators
7
7
  # メールアドレスのフォーマットチェック(簡易的なチェック)
8
- class Email < Grape::Validations::Base
8
+ class Email < Grape::Validations::Validators::Base
9
9
  def validate_param!(attr_name, params)
10
10
  return if !@required && params[attr_name].blank?
11
11
 
@@ -7,7 +7,7 @@ require 'email_validator'
7
7
 
8
8
  module MocaRlibs::GrapeValidators
9
9
  # メールアドレスのフォーマットチェック(RFC-2822, RFC-5321)
10
- class EmailRFC < Grape::Validations::Base
10
+ class EmailRFC < Grape::Validations::Validators::Base
11
11
  def validate_param!(attr_name, params)
12
12
  return if !@required && params[attr_name].blank?
13
13
 
@@ -7,7 +7,7 @@ require 'email_validator'
7
7
 
8
8
  module MocaRlibs::GrapeValidators
9
9
  # メールアドレスのフォーマットチェック(厳密チェック)
10
- class EmailStrict < Grape::Validations::Base
10
+ class EmailStrict < Grape::Validations::Validators::Base
11
11
  def validate_param!(attr_name, params)
12
12
  return if !@required && params[attr_name].blank?
13
13
 
@@ -7,7 +7,7 @@ require 'grape'
7
7
 
8
8
  module MocaRlibs::GrapeValidators
9
9
  # 文字列の末尾をチェック
10
- class EndsWith < Grape::Validations::Base
10
+ class EndsWith < Grape::Validations::Validators::Base
11
11
  def validate_param!(attr_name, params)
12
12
  return if !@required && params[attr_name].blank?
13
13
 
@@ -6,7 +6,7 @@ require 'resolv'
6
6
 
7
7
  module MocaRlibs::GrapeValidators
8
8
  # 数値の最小値をチェック
9
- class IpAddress < Grape::Validations::Base
9
+ class IpAddress < Grape::Validations::Validators::Base
10
10
  def validate_param!(attr_name, params)
11
11
  return if !@required && params[attr_name].blank?
12
12
 
@@ -7,7 +7,7 @@ require 'grape'
7
7
 
8
8
  module MocaRlibs::GrapeValidators
9
9
  # 文字列の長さチェック
10
- class Length < Grape::Validations::Base
10
+ class Length < Grape::Validations::Validators::Base
11
11
  def validate_param!(attr_name, params)
12
12
  return if !@required && params[attr_name].blank?
13
13
 
@@ -7,7 +7,7 @@ require 'grape'
7
7
 
8
8
  module MocaRlibs::GrapeValidators
9
9
  # 数値の最大値をチェック
10
- class Max < Grape::Validations::Base
10
+ class Max < Grape::Validations::Validators::Base
11
11
  def validate_param!(attr_name, params)
12
12
  return if !@required && params[attr_name].blank?
13
13
 
@@ -7,7 +7,7 @@ require 'grape'
7
7
 
8
8
  module MocaRlibs::GrapeValidators
9
9
  # 数値の最小値をチェック
10
- class Min < Grape::Validations::Base
10
+ class Min < Grape::Validations::Validators::Base
11
11
  def validate_param!(attr_name, params)
12
12
  return if !@required && params[attr_name].blank?
13
13
 
@@ -5,7 +5,7 @@ require 'grape'
5
5
 
6
6
  module MocaRlibs::GrapeValidators
7
7
  # 文字列が半角アルファベットのみであることをチェックする
8
- class OnlyAlpha < Grape::Validations::Base
8
+ class OnlyAlpha < Grape::Validations::Validators::Base
9
9
  def validate_param!(attr_name, params)
10
10
  return if !@required && params[attr_name].blank?
11
11
 
@@ -5,7 +5,7 @@ require 'grape'
5
5
 
6
6
  module MocaRlibs::GrapeValidators
7
7
  # 文字列が半角英数字のみであることをチェックする
8
- class OnlyAlphaNumeric < Grape::Validations::Base
8
+ class OnlyAlphaNumeric < Grape::Validations::Validators::Base
9
9
  def validate_param!(attr_name, params)
10
10
  return if !@required && params[attr_name].blank?
11
11
 
@@ -5,7 +5,7 @@ require 'grape'
5
5
 
6
6
  module MocaRlibs::GrapeValidators
7
7
  # アスキー文字のみを許可する
8
- class OnlyASCII < Grape::Validations::Base
8
+ class OnlyASCII < Grape::Validations::Validators::Base
9
9
  def validate_param!(attr_name, params)
10
10
  return if !@required && params[attr_name].blank?
11
11
 
@@ -5,7 +5,7 @@ require 'grape'
5
5
 
6
6
  module MocaRlibs::GrapeValidators
7
7
  # 文字列が数字のみであることをチェックする
8
- class OnlyNumbers < Grape::Validations::Base
8
+ class OnlyNumbers < Grape::Validations::Validators::Base
9
9
  def validate_param!(attr_name, params)
10
10
  return if !@required && params[attr_name].blank?
11
11
 
@@ -5,7 +5,7 @@ require 'grape'
5
5
 
6
6
  module MocaRlibs::GrapeValidators
7
7
  # 出力可能なアスキー文字のみかどうかをチェックする(半角英数字+一部の記号)
8
- class OnlyPrintable < Grape::Validations::Base
8
+ class OnlyPrintable < Grape::Validations::Validators::Base
9
9
  def validate_param!(attr_name, params)
10
10
  return if !@required && params[attr_name].blank?
11
11
 
@@ -7,7 +7,7 @@ require 'grape'
7
7
 
8
8
  module MocaRlibs::GrapeValidators
9
9
  # 文字列の先頭をチェック
10
- class StartsWith < Grape::Validations::Base
10
+ class StartsWith < Grape::Validations::Validators::Base
11
11
  def validate_param!(attr_name, params)
12
12
  return if !@required && params[attr_name].blank?
13
13
 
@@ -5,7 +5,7 @@ require 'grape'
5
5
 
6
6
  module MocaRlibs::GrapeValidators
7
7
  # URLとして正しいフォーマットかどうかをチェックする
8
- class URL < Grape::Validations::Base
8
+ class URL < Grape::Validations::Validators::Base
9
9
  def validate_param!(attr_name, params)
10
10
  return if !@required && params[attr_name].blank?
11
11
 
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module MocaRlibs
4
- VERSION = '0.0.8'
4
+ VERSION = '0.0.9'
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: moca_rlibs
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.8
4
+ version: 0.0.9
5
5
  platform: ruby
6
6
  authors:
7
7
  - mocaberos
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2021-12-07 00:00:00.000000000 Z
11
+ date: 2021-12-31 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activemodel
@@ -264,7 +264,6 @@ files:
264
264
  - ".idea/vcs.xml"
265
265
  - ".rspec"
266
266
  - ".rubocop.yml"
267
- - CHANGELOG.md
268
267
  - CODE_OF_CONDUCT.md
269
268
  - Dockerfile
270
269
  - Gemfile
data/CHANGELOG.md DELETED
@@ -1,5 +0,0 @@
1
- ## [Unreleased]
2
-
3
- ## [0.0.2] - 2021-10-3
4
-
5
- - Initial release