git-lint 3.0.0 → 3.2.0

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: c2059ee0fcb8ba35c1b7a5954889073194ecdab5fa9083010801501c1db599fb
4
- data.tar.gz: ae17d7f572abbab27c8f7cd3e71524574019aa5923d4a9c1aad95116dc73af50
3
+ metadata.gz: 26dd0563eae8d604d947e6e2ed64c5af922134ff7953d0b4c7b3d66216c1770e
4
+ data.tar.gz: 6d12427265bea6004348cb5331a0f95533d67157c9ba818b7ce8c537fa542c57
5
5
  SHA512:
6
- metadata.gz: f888c4f9de1657f80d0686799763e1d6e4aaa104afadf62f792e6cc843cf4944a24af87ebb64c3a43aa485f598619d7415b66dc57afb1573e737e8b000beb73d
7
- data.tar.gz: b0f06b649c9808095c2b8ce1ff401e3571c3656bb14c5c048e5327e4b3c1cfdf1dc174b370ad71442737f614baa6169a02042631edd8a1c43ead0a10429344de
6
+ metadata.gz: 2eea7fdb6239227b1e6801a7cfe95076a18f17e6f2fc61d439dd8dab98a0555da807e3e9936b5613d99bf7c777b4e446d5f1396783ba922e8e17ffc0f17d51de
7
+ data.tar.gz: 4b4c13b33bbd423350f74f2bf8b270f0a914c8dcfcb3541bc2889cbbec2faade9acd84019370b15e57936d86d9701acfc37d3b93901144b5aa6c1fff61356785
checksums.yaml.gz.sig CHANGED
@@ -1 +1,2 @@
1
- �Y�~Y�Ⱥ�:"�n�슧�s���)X�����/<-o�1�TMW�T��. ���k��G��XH~�3Ͻ;&����!��ۦ�]k�a��H��u��3?6�=,��BOG����}��9cl���[������4�У>��w1�$�ްf{Z҅�*�./��߉���������3k-q�d��:�x��P�����a�R;��@0*�NN.���x��O�ķ@(?+iA4����KP.alݴ���*]
1
+ u��58V2Ȓi8,J@�*-
2
+ H�^���|
data/README.adoc CHANGED
@@ -6,15 +6,6 @@
6
6
 
7
7
  = Git Lint
8
8
 
9
- [link=http://badge.fury.io/rb/git-lint]
10
- image::https://badge.fury.io/rb/git-lint.svg[Gem Version]
11
- [link=https://www.alchemists.io/projects/code_quality]
12
- image::https://img.shields.io/badge/code_style-alchemists-brightgreen.svg[Alchemists Style Guide]
13
- [link=https://circleci.com/gh/bkuhlmann/git-lint]
14
- image::https://circleci.com/gh/bkuhlmann/git-lint.svg?style=svg[Circle CI Status]
15
- [link=https://app.netlify.com/sites/git-lint/deploys]
16
- image::https://api.netlify.com/api/v1/badges/7e23b422-3412-4e7f-b654-65c0417a0b1f/deploy-status[Netlify CI Status]
17
-
18
9
  Git Lint is a command line interface for linting Git commits by ensuring you maintain a clean, easy
19
10
  to read, debuggable, and maintainable project history. Having a consistent commit history leads to
20
11
  improved code reviews and is a perfect companion to tools like
@@ -1005,35 +996,17 @@ To test, run:
1005
996
  bundle exec rake
1006
997
  ----
1007
998
 
1008
- == Versioning
1009
-
1010
- Read link:https://semver.org[Semantic Versioning] for details. Briefly, it means:
1011
-
1012
- * Major (X.y.z) - Incremented for any backwards incompatible public API changes.
1013
- * Minor (x.Y.z) - Incremented for new, backwards compatible, public API enhancements/fixes.
1014
- * Patch (x.y.Z) - Incremented for small, backwards compatible, bug fixes.
1015
-
1016
- == Code of Conduct
1017
-
1018
- Please note that this project is released with a link:CODE_OF_CONDUCT.adoc[CODE OF CONDUCT]. By
1019
- participating in this project you agree to abide by its terms.
1020
-
1021
- == Contributions
1022
-
1023
- Read link:CONTRIBUTING.adoc[CONTRIBUTING] for details.
1024
-
1025
- == Community
999
+ == link:https://www.alchemists.io/policies/license[License]
1026
1000
 
1027
- Feel free to link:https://www.alchemists.io/community[join the commmunity] for discussions related
1028
- to this project and much more.
1001
+ == link:https://www.alchemists.io/policies/security[Security]
1029
1002
 
1030
- == License
1003
+ == link:https://www.alchemists.io/policies/code_of_conduct[Code of Conduct]
1031
1004
 
1032
- Read link:LICENSE.adoc[LICENSE] for details.
1005
+ == link:https://www.alchemists.io/policies/contributions[Contributions]
1033
1006
 
1034
- == Changes
1007
+ == link:https://www.alchemists.io/projects/git-lint/versions[Versions]
1035
1008
 
1036
- Read link:CHANGES.adoc[CHANGES] for details.
1009
+ == link:https://www.alchemists.io/community[Community]
1037
1010
 
1038
1011
  == Credits
1039
1012
 
data/exe/git-lint CHANGED
@@ -3,5 +3,4 @@
3
3
 
4
4
  require "git/lint"
5
5
 
6
- Process.setproctitle Git::Lint::Identity::VERSION_LABEL
7
6
  Git::Lint::CLI::Shell.new.call ARGV
data/git-lint.gemspec ADDED
@@ -0,0 +1,37 @@
1
+ # frozen_string_literal: true
2
+
3
+ Gem::Specification.new do |spec|
4
+ spec.name = "git-lint"
5
+ spec.version = "3.2.0"
6
+ spec.authors = ["Brooke Kuhlmann"]
7
+ spec.email = ["brooke@alchemists.io"]
8
+ spec.homepage = "https://www.alchemists.io/projects/git-lint"
9
+ spec.summary = "A command line interface for linting Git commits."
10
+ spec.license = "Hippocratic-3.0"
11
+
12
+ spec.metadata = {
13
+ "bug_tracker_uri" => "https://github.com/bkuhlmann/git-lint/issues",
14
+ "changelog_uri" => "https://www.alchemists.io/projects/git-lint/versions",
15
+ "documentation_uri" => "https://www.alchemists.io/projects/git-lint",
16
+ "label" => "Git Lint",
17
+ "rubygems_mfa_required" => "true",
18
+ "source_code_uri" => "https://github.com/bkuhlmann/git-lint"
19
+ }
20
+
21
+ spec.signing_key = Gem.default_key_path
22
+ spec.cert_chain = [Gem.default_cert_path]
23
+
24
+ spec.required_ruby_version = "~> 3.1"
25
+ spec.add_dependency "dry-container", "~> 0.9.0"
26
+ spec.add_dependency "git_plus", "~> 1.1"
27
+ spec.add_dependency "pastel", "~> 0.8"
28
+ spec.add_dependency "refinements", "~> 9.1"
29
+ spec.add_dependency "runcom", "~> 8.2"
30
+ spec.add_dependency "spek", "~> 0.0"
31
+ spec.add_dependency "zeitwerk", "~> 2.5"
32
+
33
+ spec.bindir = "exe"
34
+ spec.executables << "git-lint"
35
+ spec.extra_rdoc_files = Dir["README*", "LICENSE*"]
36
+ spec.files = Dir["*.gemspec", "lib/**/*"]
37
+ end
@@ -12,13 +12,16 @@ module Git
12
12
 
13
13
  def self.call(...) = new(...).call
14
14
 
15
- def initialize configuration = Container[:configuration], client: Parser::CLIENT
15
+ def initialize configuration = Container[:configuration],
16
+ client: Parser::CLIENT,
17
+ container: Container
16
18
  @configuration = configuration
17
19
  @client = client
20
+ @container = container
18
21
  end
19
22
 
20
23
  def call arguments = []
21
- client.banner = "#{Identity::LABEL} - #{Identity::SUMMARY}"
24
+ client.banner = specification.labeled_summary
22
25
  client.separator "\nUSAGE:\n"
23
26
  collate
24
27
  client.parse arguments
@@ -27,7 +30,7 @@ module Git
27
30
 
28
31
  private
29
32
 
30
- attr_reader :configuration, :client
33
+ attr_reader :configuration, :client, :container
31
34
 
32
35
  def collate = private_methods.sort.grep(/add_/).each { |method| __send__ method }
33
36
 
@@ -56,7 +59,7 @@ module Git
56
59
 
57
60
  def add_version
58
61
  client.on "-v", "--version", "Show gem version." do
59
- configuration.merge! action_version: Identity::VERSION_LABEL
62
+ configuration.merge! action_version: true
60
63
  end
61
64
  end
62
65
 
@@ -65,6 +68,8 @@ module Git
65
68
  configuration.merge! action_help: true
66
69
  end
67
70
  end
71
+
72
+ def specification = container[__method__]
68
73
  end
69
74
  end
70
75
  end
@@ -34,7 +34,7 @@ module Git
34
34
  in action_analyze: true, analyze_sha: String => sha then analyze_commit sha
35
35
  in action_config: Symbol => action then config action
36
36
  in action_hook: Pathname => path then hook path
37
- in action_version: String => version then logger.info version
37
+ in action_version: true then logger.info { specification.labeled_version }
38
38
  else usage
39
39
  end
40
40
  end
@@ -49,6 +49,8 @@ module Git
49
49
 
50
50
  def usage = logger.unknown { parser.to_s }
51
51
 
52
+ def specification = container[__method__]
53
+
52
54
  def logger = container[__method__]
53
55
  end
54
56
  end
@@ -15,7 +15,7 @@ module Git
15
15
  using ::Refinements::Structs
16
16
 
17
17
  DEFAULTS = YAML.load_file(Pathname(__dir__).join("defaults.yml")).freeze
18
- CLIENT = Runcom::Config.new "#{Identity::NAME}/configuration.yml", defaults: DEFAULTS
18
+ CLIENT = Runcom::Config.new "git-lint/configuration.yml", defaults: DEFAULTS
19
19
 
20
20
  def self.call = new.call
21
21
 
@@ -4,6 +4,7 @@ require "dry-container"
4
4
  require "git_plus"
5
5
  require "logger"
6
6
  require "pastel"
7
+ require "spek"
7
8
 
8
9
  module Git
9
10
  module Lint
@@ -13,6 +14,7 @@ module Git
13
14
 
14
15
  register(:configuration) { Configuration::Loader.call }
15
16
  register(:repository) { GitPlus::Repository.new }
17
+ register(:specification) { Spek::Loader.call "#{__dir__}/../../../git-lint.gemspec" }
16
18
  register(:colorizer) { Pastel.new enabled: $stdout.tty? }
17
19
  register(:kernel) { Kernel }
18
20
 
@@ -5,7 +5,7 @@ module Git
5
5
  module Errors
6
6
  # The root class of gem related errors.
7
7
  class Base < StandardError
8
- def initialize message = "Invalid #{Identity::LABEL} action."
8
+ def initialize message = "Invalid Git Lint action."
9
9
  super message
10
10
  end
11
11
  end
@@ -15,7 +15,7 @@ module Git
15
15
  end
16
16
 
17
17
  def to_s
18
- "Running #{Identity::LABEL}...#{branch_report}\n" \
18
+ "Running Git Lint...#{branch_report}\n" \
19
19
  "#{commit_total}. #{issue_totals}.\n"
20
20
  end
21
21
 
data/lib/git/lint.rb CHANGED
@@ -10,7 +10,7 @@ Zeitwerk::Loader.new.then do |loader|
10
10
  "netlify_ci" => "NetlifyCI",
11
11
  "travis_ci" => "TravisCI"
12
12
  loader.push_dir "#{__dir__}/.."
13
- loader.ignore "#{__dir__}/lint/rake/setup.rb"
13
+ loader.ignore "#{__dir__}/lint/rake"
14
14
  loader.setup
15
15
  end
16
16
 
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: 3.0.0
4
+ version: 3.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Brooke Kuhlmann
@@ -28,7 +28,7 @@ cert_chain:
28
28
  lkHilIrX69jq8wMPpBhlaw2mRmeSL50Wv5u6xVBvOHhXFSP1crXM95vfLhLyRYod
29
29
  W2A=
30
30
  -----END CERTIFICATE-----
31
- date: 2021-12-27 00:00:00.000000000 Z
31
+ date: 2022-02-06 00:00:00.000000000 Z
32
32
  dependencies:
33
33
  - !ruby/object:Gem::Dependency
34
34
  name: dry-container
@@ -50,14 +50,14 @@ dependencies:
50
50
  requirements:
51
51
  - - "~>"
52
52
  - !ruby/object:Gem::Version
53
- version: '1.0'
53
+ version: '1.1'
54
54
  type: :runtime
55
55
  prerelease: false
56
56
  version_requirements: !ruby/object:Gem::Requirement
57
57
  requirements:
58
58
  - - "~>"
59
59
  - !ruby/object:Gem::Version
60
- version: '1.0'
60
+ version: '1.1'
61
61
  - !ruby/object:Gem::Dependency
62
62
  name: pastel
63
63
  requirement: !ruby/object:Gem::Requirement
@@ -78,28 +78,42 @@ dependencies:
78
78
  requirements:
79
79
  - - "~>"
80
80
  - !ruby/object:Gem::Version
81
- version: '9.0'
81
+ version: '9.1'
82
82
  type: :runtime
83
83
  prerelease: false
84
84
  version_requirements: !ruby/object:Gem::Requirement
85
85
  requirements:
86
86
  - - "~>"
87
87
  - !ruby/object:Gem::Version
88
- version: '9.0'
88
+ version: '9.1'
89
89
  - !ruby/object:Gem::Dependency
90
90
  name: runcom
91
91
  requirement: !ruby/object:Gem::Requirement
92
92
  requirements:
93
93
  - - "~>"
94
94
  - !ruby/object:Gem::Version
95
- version: '8.0'
95
+ version: '8.2'
96
96
  type: :runtime
97
97
  prerelease: false
98
98
  version_requirements: !ruby/object:Gem::Requirement
99
99
  requirements:
100
100
  - - "~>"
101
101
  - !ruby/object:Gem::Version
102
- version: '8.0'
102
+ version: '8.2'
103
+ - !ruby/object:Gem::Dependency
104
+ name: spek
105
+ requirement: !ruby/object:Gem::Requirement
106
+ requirements:
107
+ - - "~>"
108
+ - !ruby/object:Gem::Version
109
+ version: '0.0'
110
+ type: :runtime
111
+ prerelease: false
112
+ version_requirements: !ruby/object:Gem::Requirement
113
+ requirements:
114
+ - - "~>"
115
+ - !ruby/object:Gem::Version
116
+ version: '0.0'
103
117
  - !ruby/object:Gem::Dependency
104
118
  name: zeitwerk
105
119
  requirement: !ruby/object:Gem::Requirement
@@ -127,6 +141,7 @@ files:
127
141
  - LICENSE.adoc
128
142
  - README.adoc
129
143
  - exe/git-lint
144
+ - git-lint.gemspec
130
145
  - lib/git/lint.rb
131
146
  - lib/git/lint/analyzer.rb
132
147
  - lib/git/lint/analyzers/abstract.rb
@@ -174,7 +189,6 @@ files:
174
189
  - lib/git/lint/errors/base.rb
175
190
  - lib/git/lint/errors/severity.rb
176
191
  - lib/git/lint/errors/sha.rb
177
- - lib/git/lint/identity.rb
178
192
  - lib/git/lint/kit/filter_list.rb
179
193
  - lib/git/lint/parsers/trailers/collaborator.rb
180
194
  - lib/git/lint/rake/setup.rb
@@ -193,8 +207,9 @@ licenses:
193
207
  - Hippocratic-3.0
194
208
  metadata:
195
209
  bug_tracker_uri: https://github.com/bkuhlmann/git-lint/issues
196
- changelog_uri: https://www.alchemists.io/projects/git-lint/changes.html
210
+ changelog_uri: https://www.alchemists.io/projects/git-lint/versions
197
211
  documentation_uri: https://www.alchemists.io/projects/git-lint
212
+ label: Git Lint
198
213
  rubygems_mfa_required: 'true'
199
214
  source_code_uri: https://github.com/bkuhlmann/git-lint
200
215
  post_install_message:
@@ -212,7 +227,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
212
227
  - !ruby/object:Gem::Version
213
228
  version: '0'
214
229
  requirements: []
215
- rubygems_version: 3.3.3
230
+ rubygems_version: 3.3.6
216
231
  signing_key:
217
232
  specification_version: 4
218
233
  summary: A command line interface for linting Git commits.
metadata.gz.sig CHANGED
Binary file
@@ -1,14 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- module Git
4
- module Lint
5
- # Gem identity information.
6
- module Identity
7
- NAME = "git-lint"
8
- LABEL = "Git Lint"
9
- VERSION = "3.0.0"
10
- VERSION_LABEL = "#{LABEL} #{VERSION}".freeze
11
- SUMMARY = "A command line interface for linting Git commits."
12
- end
13
- end
14
- end