git-lint 7.4.0 → 8.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (34) hide show
  1. checksums.yaml +4 -4
  2. checksums.yaml.gz.sig +0 -0
  3. data/git-lint.gemspec +8 -8
  4. data/lib/git/lint/analyzer.rb +5 -5
  5. data/lib/git/lint/analyzers/abstract.rb +3 -3
  6. data/lib/git/lint/analyzers/commit_author_name.rb +1 -1
  7. data/lib/git/lint/analyzers/commit_body_bullet_capitalization.rb +1 -1
  8. data/lib/git/lint/analyzers/commit_body_bullet_delimiter.rb +1 -1
  9. data/lib/git/lint/analyzers/commit_body_bullet_only.rb +1 -1
  10. data/lib/git/lint/analyzers/commit_body_line_length.rb +1 -1
  11. data/lib/git/lint/analyzers/commit_body_phrase.rb +1 -1
  12. data/lib/git/lint/analyzers/commit_body_presence.rb +1 -1
  13. data/lib/git/lint/analyzers/commit_body_tracker_shorthand.rb +1 -1
  14. data/lib/git/lint/analyzers/commit_signature.rb +1 -1
  15. data/lib/git/lint/analyzers/commit_subject_length.rb +1 -1
  16. data/lib/git/lint/analyzers/commit_subject_prefix.rb +4 -4
  17. data/lib/git/lint/analyzers/commit_subject_suffix.rb +1 -1
  18. data/lib/git/lint/analyzers/commit_trailer_collaborator_name.rb +1 -1
  19. data/lib/git/lint/analyzers/commit_trailer_format_value.rb +1 -1
  20. data/lib/git/lint/analyzers/commit_trailer_issue_value.rb +1 -1
  21. data/lib/git/lint/analyzers/commit_trailer_milestone_value.rb +1 -1
  22. data/lib/git/lint/analyzers/commit_trailer_reviewer_value.rb +1 -1
  23. data/lib/git/lint/analyzers/commit_trailer_signer_name.rb +1 -1
  24. data/lib/git/lint/analyzers/commit_trailer_tracker_value.rb +1 -1
  25. data/lib/git/lint/cli/actions/analyze/branch.rb +2 -2
  26. data/lib/git/lint/cli/actions/analyze/commit.rb +2 -2
  27. data/lib/git/lint/cli/actions/hook.rb +2 -2
  28. data/lib/git/lint/configuration/model.rb +96 -96
  29. data/lib/git/lint/configuration/trailer.rb +1 -1
  30. data/lib/git/lint/container.rb +6 -8
  31. data/lib/git/lint/errors/base.rb +1 -1
  32. data.tar.gz.sig +0 -0
  33. metadata +17 -17
  34. metadata.gz.sig +0 -0
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: f98e51b1cd6205f40ac71ab134e84dd1c89fda97e4cdf8e8167cd786502d617b
4
- data.tar.gz: 255c7ca4d871b5b4d3a119fb168212e5f90acf50d576ed007356c82c975e3cd1
3
+ metadata.gz: e6336f6d97ff30bfbd055d4caaa4e96e660c4581594b7798228d06c3f7b65728
4
+ data.tar.gz: ba008a232c6eb9f27d7b51942b4720b900b1962611a3148c0ef0e31432ba9cc7
5
5
  SHA512:
6
- metadata.gz: ff1bd1993e0884ec5f8553daaca2e2359c864f75aa320cd688dd2019727f104b7c2077763c42099652be588b04b84702ab59bdbfe3162ff82197e3fdbe3b77fd
7
- data.tar.gz: 60f4b3b2316d0de7063b396c3539b45efdfd5692764a1349edd1f06c25d10b66ca2ec3a7f7931783c3c065fd400abd1aa05ca347cae95d8e3ed8109634d48064
6
+ metadata.gz: 1ff6007eaa1acb235a9b684319f9f458b83c74f27dec50d6e13f402945d85fa371272ddb10b1c5233db3383c3b59888d8810a34c3bd720bf0d1bdf922b0335a3
7
+ data.tar.gz: '0208b11645b14516a5bd795ad92db98b2adc1d9ca0f8a8b784d0dfbf7deaa4fe46baef9c74c4b4cb80140f1cb64188c92068fbbad821322ff2ed88cba3d3dc69'
checksums.yaml.gz.sig CHANGED
Binary file
data/git-lint.gemspec CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
  Gem::Specification.new do |spec|
4
4
  spec.name = "git-lint"
5
- spec.version = "7.4.0"
5
+ spec.version = "8.0.0"
6
6
  spec.authors = ["Brooke Kuhlmann"]
7
7
  spec.email = ["brooke@alchemists.io"]
8
8
  spec.homepage = "https://alchemists.io/projects/git-lint"
@@ -23,17 +23,17 @@ Gem::Specification.new do |spec|
23
23
  spec.cert_chain = [Gem.default_cert_path]
24
24
 
25
25
  spec.required_ruby_version = "~> 3.3"
26
- spec.add_dependency "cogger", "~> 0.15"
27
- spec.add_dependency "containable", "~> 0.0"
26
+ spec.add_dependency "cogger", "~> 0.21"
27
+ spec.add_dependency "containable", "~> 0.2"
28
28
  spec.add_dependency "core", "~> 1.0"
29
29
  spec.add_dependency "dry-monads", "~> 1.6"
30
30
  spec.add_dependency "dry-schema", "~> 1.13"
31
- spec.add_dependency "etcher", "~> 1.3"
32
- spec.add_dependency "gitt", "~> 3.2"
33
- spec.add_dependency "infusible", "~> 3.5"
34
- spec.add_dependency "refinements", "~> 12.1"
31
+ spec.add_dependency "etcher", "~> 2.0"
32
+ spec.add_dependency "gitt", "~> 3.6"
33
+ spec.add_dependency "infusible", "~> 3.8"
34
+ spec.add_dependency "refinements", "~> 12.5"
35
35
  spec.add_dependency "runcom", "~> 11.0"
36
- spec.add_dependency "sod", "~> 0.8"
36
+ spec.add_dependency "sod", "~> 0.12"
37
37
  spec.add_dependency "spek", "~> 3.0"
38
38
  spec.add_dependency "tone", "~> 1.0"
39
39
  spec.add_dependency "zeitwerk", "~> 2.6"
@@ -4,7 +4,7 @@ module Git
4
4
  module Lint
5
5
  # Runs all analyzers.
6
6
  class Analyzer
7
- include Import[:configuration]
7
+ include Import[:settings]
8
8
 
9
9
  ANALYZERS = [
10
10
  Analyzers::CommitAuthorCapitalization,
@@ -80,10 +80,10 @@ module Git
80
80
 
81
81
  # :reek:FeatureEnvy
82
82
  def enabled
83
- configuration.to_h
84
- .select { |key, value| key.end_with?("enabled") && value == true }
85
- .keys
86
- .map { |key| key.to_s.sub!("commits_", "commit_").delete_suffix! "_enabled" }
83
+ settings.to_h
84
+ .select { |key, value| key.end_with?("enabled") && value == true }
85
+ .keys
86
+ .map { |key| key.to_s.sub!("commits_", "commit_").delete_suffix! "_enabled" }
87
87
  end
88
88
 
89
89
  def load_analyzer commit, id
@@ -8,7 +8,7 @@ module Git
8
8
  module Analyzers
9
9
  # An abstract class which provides basic functionality for all analyzers to inherit from.
10
10
  class Abstract
11
- include Import[:configuration, :environment]
11
+ include Import[:settings, :environment]
12
12
 
13
13
  using Refinements::String
14
14
 
@@ -30,8 +30,8 @@ module Git
30
30
  end
31
31
 
32
32
  def severity
33
- configuration.public_send("#{self.class.id}_severity".sub("commit_", "commits_"))
34
- .tap { |level| fail Errors::Severity, level unless LEVELS.include? level }
33
+ settings.public_send("#{self.class.id}_severity".sub("commit_", "commits_"))
34
+ .tap { |level| fail Errors::Severity, level unless LEVELS.include? level }
35
35
  end
36
36
 
37
37
  def valid? = fail NoMethodError, "The `##{__method__}` method must be implemented."
@@ -17,7 +17,7 @@ module Git
17
17
 
18
18
  private
19
19
 
20
- def minimum = configuration.commits_author_name_minimum
20
+ def minimum = settings.commits_author_name_minimum
21
21
  end
22
22
  end
23
23
  end
@@ -19,7 +19,7 @@ module Git
19
19
  protected
20
20
 
21
21
  def load_filter_list
22
- Kit::FilterList.new configuration.commits_body_bullet_capitalization_includes
22
+ Kit::FilterList.new settings.commits_body_bullet_capitalization_includes
23
23
  end
24
24
 
25
25
  def invalid_line? line
@@ -19,7 +19,7 @@ module Git
19
19
  protected
20
20
 
21
21
  def load_filter_list
22
- Kit::FilterList.new configuration.commits_body_bullet_delimiter_includes
22
+ Kit::FilterList.new settings.commits_body_bullet_delimiter_includes
23
23
  end
24
24
 
25
25
  def invalid_line?(line) = line.match?(/\A\s*#{pattern}(?!(#{pattern}|\s)).+\Z/)
@@ -19,7 +19,7 @@ module Git
19
19
  protected
20
20
 
21
21
  def load_filter_list
22
- Kit::FilterList.new configuration.commits_body_bullet_only_includes
22
+ Kit::FilterList.new settings.commits_body_bullet_only_includes
23
23
  end
24
24
 
25
25
  def invalid_line?(line) = line.match?(/\A#{Regexp.union filter_list}\s+/)
@@ -22,7 +22,7 @@ module Git
22
22
 
23
23
  private
24
24
 
25
- def maximum = configuration.commits_body_line_length_maximum
25
+ def maximum = settings.commits_body_line_length_maximum
26
26
  end
27
27
  end
28
28
  end
@@ -19,7 +19,7 @@ module Git
19
19
  protected
20
20
 
21
21
  def load_filter_list
22
- Kit::FilterList.new configuration.commits_body_phrase_excludes
22
+ Kit::FilterList.new settings.commits_body_phrase_excludes
23
23
  end
24
24
 
25
25
  def invalid_line? line
@@ -14,7 +14,7 @@ module Git
14
14
  valid_lines.size >= minimum
15
15
  end
16
16
 
17
- def minimum = configuration.commits_body_presence_minimum
17
+ def minimum = settings.commits_body_presence_minimum
18
18
 
19
19
  def issue
20
20
  return {} if valid?
@@ -19,7 +19,7 @@ module Git
19
19
  protected
20
20
 
21
21
  def load_filter_list
22
- Kit::FilterList.new configuration.commits_body_tracker_shorthand_excludes
22
+ Kit::FilterList.new settings.commits_body_tracker_shorthand_excludes
23
23
  end
24
24
 
25
25
  def invalid_line?(line) = line.match?(/.*#{Regexp.union filter_list}.*/)
@@ -16,7 +16,7 @@ module Git
16
16
  protected
17
17
 
18
18
  def load_filter_list
19
- Kit::FilterList.new configuration.commits_signature_includes
19
+ Kit::FilterList.new settings.commits_signature_includes
20
20
  end
21
21
  end
22
22
  end
@@ -15,7 +15,7 @@ module Git
15
15
 
16
16
  private
17
17
 
18
- def maximum = configuration.commits_subject_length_maximum
18
+ def maximum = settings.commits_subject_length_maximum
19
19
  end
20
20
  end
21
21
  end
@@ -21,16 +21,16 @@ module Git
21
21
  protected
22
22
 
23
23
  def load_filter_list
24
- configuration.commits_subject_prefix_includes
25
- .map { |prefix| "#{prefix}#{delimiter}" }
26
- .then { |list| Kit::FilterList.new list }
24
+ settings.commits_subject_prefix_includes
25
+ .map { |prefix| "#{prefix}#{delimiter}" }
26
+ .then { |list| Kit::FilterList.new list }
27
27
  end
28
28
 
29
29
  def locally_prefixed? = !ci? && commit.directive?
30
30
 
31
31
  def ci? = environment["CI"] == "true"
32
32
 
33
- def delimiter = configuration.commits_subject_prefix_delimiter
33
+ def delimiter = settings.commits_subject_prefix_delimiter
34
34
  end
35
35
  end
36
36
  end
@@ -20,7 +20,7 @@ module Git
20
20
  protected
21
21
 
22
22
  def load_filter_list
23
- Kit::FilterList.new configuration.commits_subject_suffix_excludes
23
+ Kit::FilterList.new settings.commits_subject_suffix_excludes
24
24
  end
25
25
  end
26
26
  end
@@ -32,7 +32,7 @@ module Git
32
32
 
33
33
  private
34
34
 
35
- def minimum = configuration.commits_trailer_collaborator_name_minimum
35
+ def minimum = settings.commits_trailer_collaborator_name_minimum
36
36
  end
37
37
  end
38
38
  end
@@ -21,7 +21,7 @@ module Git
21
21
  protected
22
22
 
23
23
  def load_filter_list
24
- Kit::FilterList.new configuration.commits_trailer_format_value_includes
24
+ Kit::FilterList.new settings.commits_trailer_format_value_includes
25
25
  end
26
26
 
27
27
  def invalid_line? trailer
@@ -21,7 +21,7 @@ module Git
21
21
  protected
22
22
 
23
23
  def load_filter_list
24
- Kit::FilterList.new configuration.commits_trailer_issue_value_includes
24
+ Kit::FilterList.new settings.commits_trailer_issue_value_includes
25
25
  end
26
26
 
27
27
  def invalid_line? trailer
@@ -21,7 +21,7 @@ module Git
21
21
  protected
22
22
 
23
23
  def load_filter_list
24
- Kit::FilterList.new configuration.commits_trailer_milestone_value_includes
24
+ Kit::FilterList.new settings.commits_trailer_milestone_value_includes
25
25
  end
26
26
 
27
27
  def invalid_line? trailer
@@ -21,7 +21,7 @@ module Git
21
21
  protected
22
22
 
23
23
  def load_filter_list
24
- Kit::FilterList.new configuration.commits_trailer_reviewer_value_includes
24
+ Kit::FilterList.new settings.commits_trailer_reviewer_value_includes
25
25
  end
26
26
 
27
27
  def invalid_line? trailer
@@ -32,7 +32,7 @@ module Git
32
32
 
33
33
  private
34
34
 
35
- def minimum = configuration.commits_trailer_signer_name_minimum
35
+ def minimum = settings.commits_trailer_signer_name_minimum
36
36
  end
37
37
  end
38
38
  end
@@ -21,7 +21,7 @@ module Git
21
21
  protected
22
22
 
23
23
  def load_filter_list
24
- Kit::FilterList.new configuration.commits_trailer_tracker_value_includes
24
+ Kit::FilterList.new settings.commits_trailer_tracker_value_includes
25
25
  end
26
26
 
27
27
  def invalid_line? trailer
@@ -9,7 +9,7 @@ module Git
9
9
  module Analyze
10
10
  # Handles analyze action for branch.
11
11
  class Branch < Sod::Action
12
- include Git::Lint::Import[:kernel, :logger]
12
+ include Git::Lint::Import[:logger, :kernel, :io]
13
13
 
14
14
  description "Analyze current branch."
15
15
 
@@ -33,7 +33,7 @@ module Git
33
33
 
34
34
  def parse
35
35
  analyzer.call do |collector, reporter|
36
- kernel.puts reporter
36
+ io.puts reporter
37
37
  kernel.abort if collector.errors?
38
38
  end
39
39
  end
@@ -9,7 +9,7 @@ module Git
9
9
  module Analyze
10
10
  # Handles analyze action for single commit SHA
11
11
  class Commit < Sod::Action
12
- include Git::Lint::Import[:git, :kernel, :logger]
12
+ include Git::Lint::Import[:git, :logger, :kernel, :io]
13
13
 
14
14
  description "Analyze specific commits."
15
15
 
@@ -33,7 +33,7 @@ module Git
33
33
 
34
34
  def process arguments
35
35
  analyzer.call commits: git.commits(*arguments) do |collector, reporter|
36
- kernel.puts reporter
36
+ io.puts reporter
37
37
  kernel.abort if collector.errors?
38
38
  end
39
39
  end
@@ -9,7 +9,7 @@ module Git
9
9
  module Actions
10
10
  # Handles unsaved Git commit action.
11
11
  class Hook < Sod::Action
12
- include Git::Lint::Import[:git, :kernel, :logger]
12
+ include Git::Lint::Import[:git, :logger, :kernel, :io]
13
13
 
14
14
  description "Hook for analyzing unsaved commits."
15
15
 
@@ -22,7 +22,7 @@ module Git
22
22
 
23
23
  def call path
24
24
  analyzer.call commits: commits(path) do |collector, reporter|
25
- kernel.puts reporter
25
+ io.puts reporter
26
26
  kernel.abort if collector.errors?
27
27
  end
28
28
  end
@@ -4,102 +4,102 @@ module Git
4
4
  module Lint
5
5
  module Configuration
6
6
  # Defines configuration content as the primary source of truth for use throughout the gem.
7
- Model = Data.define :commits_author_capitalization_enabled,
8
- :commits_author_capitalization_severity,
9
- :commits_author_email_enabled,
10
- :commits_author_email_severity,
11
- :commits_author_name_enabled,
12
- :commits_author_name_severity,
13
- :commits_author_name_minimum,
14
- :commits_body_bullet_capitalization_enabled,
15
- :commits_body_bullet_capitalization_severity,
16
- :commits_body_bullet_capitalization_includes,
17
- :commits_body_bullet_delimiter_enabled,
18
- :commits_body_bullet_delimiter_severity,
19
- :commits_body_bullet_delimiter_includes,
20
- :commits_body_bullet_only_enabled,
21
- :commits_body_bullet_only_severity,
22
- :commits_body_bullet_only_includes,
23
- :commits_body_leading_line_enabled,
24
- :commits_body_leading_line_severity,
25
- :commits_body_line_length_enabled,
26
- :commits_body_line_length_severity,
27
- :commits_body_line_length_maximum,
28
- :commits_body_paragraph_capitalization_enabled,
29
- :commits_body_paragraph_capitalization_severity,
30
- :commits_body_phrase_enabled,
31
- :commits_body_phrase_severity,
32
- :commits_body_phrase_excludes,
33
- :commits_body_presence_enabled,
34
- :commits_body_presence_severity,
35
- :commits_body_presence_minimum,
36
- :commits_body_word_repeat_enabled,
37
- :commits_body_word_repeat_severity,
38
- :commits_body_tracker_shorthand_enabled,
39
- :commits_body_tracker_shorthand_severity,
40
- :commits_body_tracker_shorthand_excludes,
41
- :commits_signature_enabled,
42
- :commits_signature_severity,
43
- :commits_signature_includes,
44
- :commits_subject_length_enabled,
45
- :commits_subject_length_severity,
46
- :commits_subject_length_maximum,
47
- :commits_subject_prefix_enabled,
48
- :commits_subject_prefix_severity,
49
- :commits_subject_prefix_delimiter,
50
- :commits_subject_prefix_includes,
51
- :commits_subject_suffix_enabled,
52
- :commits_subject_suffix_severity,
53
- :commits_subject_suffix_excludes,
54
- :commits_subject_word_repeat_enabled,
55
- :commits_subject_word_repeat_severity,
56
- :commits_trailer_collaborator_capitalization_enabled,
57
- :commits_trailer_collaborator_capitalization_severity,
58
- :commits_trailer_collaborator_email_enabled,
59
- :commits_trailer_collaborator_email_severity,
60
- :commits_trailer_collaborator_key_enabled,
61
- :commits_trailer_collaborator_key_severity,
62
- :commits_trailer_collaborator_name_enabled,
63
- :commits_trailer_collaborator_name_severity,
64
- :commits_trailer_collaborator_name_minimum,
65
- :commits_trailer_duplicate_enabled,
66
- :commits_trailer_duplicate_severity,
67
- :commits_trailer_format_key_enabled,
68
- :commits_trailer_format_key_severity,
69
- :commits_trailer_format_value_enabled,
70
- :commits_trailer_format_value_severity,
71
- :commits_trailer_format_value_includes,
72
- :commits_trailer_issue_key_enabled,
73
- :commits_trailer_issue_key_severity,
74
- :commits_trailer_issue_value_enabled,
75
- :commits_trailer_issue_value_severity,
76
- :commits_trailer_issue_value_includes,
77
- :commits_trailer_milestone_key_enabled,
78
- :commits_trailer_milestone_key_severity,
79
- :commits_trailer_milestone_value_enabled,
80
- :commits_trailer_milestone_value_severity,
81
- :commits_trailer_milestone_value_includes,
82
- :commits_trailer_order_enabled,
83
- :commits_trailer_order_severity,
84
- :commits_trailer_reviewer_key_enabled,
85
- :commits_trailer_reviewer_key_severity,
86
- :commits_trailer_reviewer_value_enabled,
87
- :commits_trailer_reviewer_value_severity,
88
- :commits_trailer_reviewer_value_includes,
89
- :commits_trailer_signer_capitalization_enabled,
90
- :commits_trailer_signer_capitalization_severity,
91
- :commits_trailer_signer_email_enabled,
92
- :commits_trailer_signer_email_severity,
93
- :commits_trailer_signer_key_enabled,
94
- :commits_trailer_signer_key_severity,
95
- :commits_trailer_signer_name_enabled,
96
- :commits_trailer_signer_name_severity,
97
- :commits_trailer_signer_name_minimum,
98
- :commits_trailer_tracker_key_enabled,
99
- :commits_trailer_tracker_key_severity,
100
- :commits_trailer_tracker_value_enabled,
101
- :commits_trailer_tracker_value_severity,
102
- :commits_trailer_tracker_value_includes
7
+ Model = Struct.new :commits_author_capitalization_enabled,
8
+ :commits_author_capitalization_severity,
9
+ :commits_author_email_enabled,
10
+ :commits_author_email_severity,
11
+ :commits_author_name_enabled,
12
+ :commits_author_name_severity,
13
+ :commits_author_name_minimum,
14
+ :commits_body_bullet_capitalization_enabled,
15
+ :commits_body_bullet_capitalization_severity,
16
+ :commits_body_bullet_capitalization_includes,
17
+ :commits_body_bullet_delimiter_enabled,
18
+ :commits_body_bullet_delimiter_severity,
19
+ :commits_body_bullet_delimiter_includes,
20
+ :commits_body_bullet_only_enabled,
21
+ :commits_body_bullet_only_severity,
22
+ :commits_body_bullet_only_includes,
23
+ :commits_body_leading_line_enabled,
24
+ :commits_body_leading_line_severity,
25
+ :commits_body_line_length_enabled,
26
+ :commits_body_line_length_severity,
27
+ :commits_body_line_length_maximum,
28
+ :commits_body_paragraph_capitalization_enabled,
29
+ :commits_body_paragraph_capitalization_severity,
30
+ :commits_body_phrase_enabled,
31
+ :commits_body_phrase_severity,
32
+ :commits_body_phrase_excludes,
33
+ :commits_body_presence_enabled,
34
+ :commits_body_presence_severity,
35
+ :commits_body_presence_minimum,
36
+ :commits_body_word_repeat_enabled,
37
+ :commits_body_word_repeat_severity,
38
+ :commits_body_tracker_shorthand_enabled,
39
+ :commits_body_tracker_shorthand_severity,
40
+ :commits_body_tracker_shorthand_excludes,
41
+ :commits_signature_enabled,
42
+ :commits_signature_severity,
43
+ :commits_signature_includes,
44
+ :commits_subject_length_enabled,
45
+ :commits_subject_length_severity,
46
+ :commits_subject_length_maximum,
47
+ :commits_subject_prefix_enabled,
48
+ :commits_subject_prefix_severity,
49
+ :commits_subject_prefix_delimiter,
50
+ :commits_subject_prefix_includes,
51
+ :commits_subject_suffix_enabled,
52
+ :commits_subject_suffix_severity,
53
+ :commits_subject_suffix_excludes,
54
+ :commits_subject_word_repeat_enabled,
55
+ :commits_subject_word_repeat_severity,
56
+ :commits_trailer_collaborator_capitalization_enabled,
57
+ :commits_trailer_collaborator_capitalization_severity,
58
+ :commits_trailer_collaborator_email_enabled,
59
+ :commits_trailer_collaborator_email_severity,
60
+ :commits_trailer_collaborator_key_enabled,
61
+ :commits_trailer_collaborator_key_severity,
62
+ :commits_trailer_collaborator_name_enabled,
63
+ :commits_trailer_collaborator_name_severity,
64
+ :commits_trailer_collaborator_name_minimum,
65
+ :commits_trailer_duplicate_enabled,
66
+ :commits_trailer_duplicate_severity,
67
+ :commits_trailer_format_key_enabled,
68
+ :commits_trailer_format_key_severity,
69
+ :commits_trailer_format_value_enabled,
70
+ :commits_trailer_format_value_severity,
71
+ :commits_trailer_format_value_includes,
72
+ :commits_trailer_issue_key_enabled,
73
+ :commits_trailer_issue_key_severity,
74
+ :commits_trailer_issue_value_enabled,
75
+ :commits_trailer_issue_value_severity,
76
+ :commits_trailer_issue_value_includes,
77
+ :commits_trailer_milestone_key_enabled,
78
+ :commits_trailer_milestone_key_severity,
79
+ :commits_trailer_milestone_value_enabled,
80
+ :commits_trailer_milestone_value_severity,
81
+ :commits_trailer_milestone_value_includes,
82
+ :commits_trailer_order_enabled,
83
+ :commits_trailer_order_severity,
84
+ :commits_trailer_reviewer_key_enabled,
85
+ :commits_trailer_reviewer_key_severity,
86
+ :commits_trailer_reviewer_value_enabled,
87
+ :commits_trailer_reviewer_value_severity,
88
+ :commits_trailer_reviewer_value_includes,
89
+ :commits_trailer_signer_capitalization_enabled,
90
+ :commits_trailer_signer_capitalization_severity,
91
+ :commits_trailer_signer_email_enabled,
92
+ :commits_trailer_signer_email_severity,
93
+ :commits_trailer_signer_key_enabled,
94
+ :commits_trailer_signer_key_severity,
95
+ :commits_trailer_signer_name_enabled,
96
+ :commits_trailer_signer_name_severity,
97
+ :commits_trailer_signer_name_minimum,
98
+ :commits_trailer_tracker_key_enabled,
99
+ :commits_trailer_tracker_key_severity,
100
+ :commits_trailer_tracker_value_enabled,
101
+ :commits_trailer_tracker_value_severity,
102
+ :commits_trailer_tracker_value_includes
103
103
  end
104
104
  end
105
105
  end
@@ -3,7 +3,7 @@
3
3
  module Git
4
4
  module Lint
5
5
  module Configuration
6
- # Defines trailer configuration as a subset of the primary configuration.
6
+ # Defines trailer configuration as a subset of the primary settings.
7
7
  Trailer = Data.define :name, :pattern
8
8
  end
9
9
  end
@@ -66,24 +66,22 @@ module Git
66
66
  register(:local) { Commits::Hosts::Local.new }
67
67
  end
68
68
 
69
- register :configuration do
70
- self[:defaults].add_loader(Etcher::Loaders::YAML.new(self[:xdg_config].active))
71
- .then { |registry| Etcher.call registry }
72
- end
73
-
74
- register :defaults do
69
+ register :registry do
75
70
  Etcher::Registry.new(contract: Configuration::Contract, model: Configuration::Model)
76
- .add_loader(Etcher::Loaders::YAML.new(self[:defaults_path]))
71
+ .add_loader(:yaml, self[:defaults_path])
72
+ .add_loader(:yaml, self[:xdg_config].active)
77
73
  end
78
74
 
75
+ register(:settings) { Etcher.call(self[:registry]).dup }
79
76
  register(:defaults_path) { Pathname(__dir__).join("configuration/defaults.yml") }
80
77
  register(:specification) { Spek::Loader.call "#{__dir__}/../../../git-lint.gemspec" }
81
78
  register(:color) { Tone.new }
82
79
  register :environment, ENV
83
80
  register(:git) { Gitt::Repository.new }
84
- register(:xdg_config) { Runcom::Config.new "git-lint/configuration.yml" }
81
+ register(:xdg_config) { Runcom::Config.new "git-lint/settings.yml" }
85
82
  register(:logger) { Cogger.new id: "git-lint" }
86
83
  register :kernel, Kernel
84
+ register :io, STDOUT
87
85
  end
88
86
  end
89
87
  end
@@ -6,7 +6,7 @@ module Git
6
6
  # The root class of gem related errors.
7
7
  class Base < StandardError
8
8
  def initialize message = "Invalid Git Lint action."
9
- super message
9
+ super
10
10
  end
11
11
  end
12
12
  end
data.tar.gz.sig CHANGED
Binary file
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: git-lint
3
3
  version: !ruby/object:Gem::Version
4
- version: 7.4.0
4
+ version: 8.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Brooke Kuhlmann
@@ -35,7 +35,7 @@ cert_chain:
35
35
  3n5C8/6Zh9DYTkpcwPSuIfAga6wf4nXc9m6JAw8AuMLaiWN/r/2s4zJsUHYERJEu
36
36
  gZGm4JqtuSg8pYjPeIJxS960owq+SfuC+jxqmRA54BisFCv/0VOJi7tiJVY=
37
37
  -----END CERTIFICATE-----
38
- date: 2024-05-16 00:00:00.000000000 Z
38
+ date: 2024-07-06 00:00:00.000000000 Z
39
39
  dependencies:
40
40
  - !ruby/object:Gem::Dependency
41
41
  name: cogger
@@ -43,28 +43,28 @@ dependencies:
43
43
  requirements:
44
44
  - - "~>"
45
45
  - !ruby/object:Gem::Version
46
- version: '0.15'
46
+ version: '0.21'
47
47
  type: :runtime
48
48
  prerelease: false
49
49
  version_requirements: !ruby/object:Gem::Requirement
50
50
  requirements:
51
51
  - - "~>"
52
52
  - !ruby/object:Gem::Version
53
- version: '0.15'
53
+ version: '0.21'
54
54
  - !ruby/object:Gem::Dependency
55
55
  name: containable
56
56
  requirement: !ruby/object:Gem::Requirement
57
57
  requirements:
58
58
  - - "~>"
59
59
  - !ruby/object:Gem::Version
60
- version: '0.0'
60
+ version: '0.2'
61
61
  type: :runtime
62
62
  prerelease: false
63
63
  version_requirements: !ruby/object:Gem::Requirement
64
64
  requirements:
65
65
  - - "~>"
66
66
  - !ruby/object:Gem::Version
67
- version: '0.0'
67
+ version: '0.2'
68
68
  - !ruby/object:Gem::Dependency
69
69
  name: core
70
70
  requirement: !ruby/object:Gem::Requirement
@@ -113,56 +113,56 @@ dependencies:
113
113
  requirements:
114
114
  - - "~>"
115
115
  - !ruby/object:Gem::Version
116
- version: '1.3'
116
+ version: '2.0'
117
117
  type: :runtime
118
118
  prerelease: false
119
119
  version_requirements: !ruby/object:Gem::Requirement
120
120
  requirements:
121
121
  - - "~>"
122
122
  - !ruby/object:Gem::Version
123
- version: '1.3'
123
+ version: '2.0'
124
124
  - !ruby/object:Gem::Dependency
125
125
  name: gitt
126
126
  requirement: !ruby/object:Gem::Requirement
127
127
  requirements:
128
128
  - - "~>"
129
129
  - !ruby/object:Gem::Version
130
- version: '3.2'
130
+ version: '3.6'
131
131
  type: :runtime
132
132
  prerelease: false
133
133
  version_requirements: !ruby/object:Gem::Requirement
134
134
  requirements:
135
135
  - - "~>"
136
136
  - !ruby/object:Gem::Version
137
- version: '3.2'
137
+ version: '3.6'
138
138
  - !ruby/object:Gem::Dependency
139
139
  name: infusible
140
140
  requirement: !ruby/object:Gem::Requirement
141
141
  requirements:
142
142
  - - "~>"
143
143
  - !ruby/object:Gem::Version
144
- version: '3.5'
144
+ version: '3.8'
145
145
  type: :runtime
146
146
  prerelease: false
147
147
  version_requirements: !ruby/object:Gem::Requirement
148
148
  requirements:
149
149
  - - "~>"
150
150
  - !ruby/object:Gem::Version
151
- version: '3.5'
151
+ version: '3.8'
152
152
  - !ruby/object:Gem::Dependency
153
153
  name: refinements
154
154
  requirement: !ruby/object:Gem::Requirement
155
155
  requirements:
156
156
  - - "~>"
157
157
  - !ruby/object:Gem::Version
158
- version: '12.1'
158
+ version: '12.5'
159
159
  type: :runtime
160
160
  prerelease: false
161
161
  version_requirements: !ruby/object:Gem::Requirement
162
162
  requirements:
163
163
  - - "~>"
164
164
  - !ruby/object:Gem::Version
165
- version: '12.1'
165
+ version: '12.5'
166
166
  - !ruby/object:Gem::Dependency
167
167
  name: runcom
168
168
  requirement: !ruby/object:Gem::Requirement
@@ -183,14 +183,14 @@ dependencies:
183
183
  requirements:
184
184
  - - "~>"
185
185
  - !ruby/object:Gem::Version
186
- version: '0.8'
186
+ version: '0.12'
187
187
  type: :runtime
188
188
  prerelease: false
189
189
  version_requirements: !ruby/object:Gem::Requirement
190
190
  requirements:
191
191
  - - "~>"
192
192
  - !ruby/object:Gem::Version
193
- version: '0.8'
193
+ version: '0.12'
194
194
  - !ruby/object:Gem::Dependency
195
195
  name: spek
196
196
  requirement: !ruby/object:Gem::Requirement
@@ -345,7 +345,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
345
345
  - !ruby/object:Gem::Version
346
346
  version: '0'
347
347
  requirements: []
348
- rubygems_version: 3.5.10
348
+ rubygems_version: 3.5.14
349
349
  signing_key:
350
350
  specification_version: 4
351
351
  summary: A command line interface for linting Git commits.
metadata.gz.sig CHANGED
Binary file