git-lint 5.1.0 → 5.1.2
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 +4 -4
- checksums.yaml.gz.sig +0 -0
- data/README.adoc +17 -17
- data/git-lint.gemspec +4 -4
- data/lib/git/lint/analyzer.rb +9 -5
- data/lib/git/lint/analyzers/abstract.rb +2 -2
- data/lib/git/lint/cli/actions/analyze/branch.rb +2 -2
- data/lib/git/lint/cli/actions/analyze/commit.rb +2 -2
- data/lib/git/lint/cli/actions/config.rb +2 -2
- data/lib/git/lint/cli/actions/hook.rb +2 -2
- data/lib/git/lint/cli/parser.rb +2 -2
- data/lib/git/lint/cli/parsers/core.rb +2 -4
- data/lib/git/lint/cli/shell.rb +4 -4
- data.tar.gz.sig +0 -0
- metadata +30 -23
- metadata.gz.sig +0 -0
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 979c80bd2907a9a0a5b3035e82c861dacacae1fc8282f37679357bc79f6ac5a0
|
4
|
+
data.tar.gz: 6175e280b6b538a262c2f3cbf6d566ffde5d7e91feb81abd50e0fcf4f0994ccf
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 577c1ba631c684d659de0bf543cba7b8ef56dc5fec373fcd013969884d3d582db012cf53c5397bd4a7d3218d6f77580366b11cd66a9276ebe027e17193b2a625
|
7
|
+
data.tar.gz: 7c0ed96012c7ee151b5faba3d554075e3d07d8336772897a1ff229ad4a4a01859277600968b69a9ce07c529223717284261f2e782f4605c9058b087d4019fbc8
|
checksums.yaml.gz.sig
CHANGED
Binary file
|
data/README.adoc
CHANGED
@@ -2,14 +2,14 @@
|
|
2
2
|
:toclevels: 5
|
3
3
|
:figure-caption!:
|
4
4
|
|
5
|
-
:git_rebase_workflow_link: link:https://
|
5
|
+
:git_rebase_workflow_link: link:https://alchemists.io/articles/git_rebase[Git Rebase Workflow]
|
6
6
|
|
7
7
|
= Git Lint
|
8
8
|
|
9
9
|
Git Lint is a command line interface for linting Git commits by ensuring you maintain a clean, easy
|
10
10
|
to read, debuggable, and maintainable project history. Having a consistent commit history leads to
|
11
11
|
improved code reviews and is a perfect companion to tools like
|
12
|
-
link:https://
|
12
|
+
link:https://alchemists.io/projects/milestoner[Milestoner] for versioning and producing
|
13
13
|
automated release notes of your deploys.
|
14
14
|
|
15
15
|
toc::[]
|
@@ -96,7 +96,7 @@ This gem can be configured via a global configuration:
|
|
96
96
|
$HOME/.config/git-lint/configuration.yml
|
97
97
|
....
|
98
98
|
|
99
|
-
It can also be configured via link:https://
|
99
|
+
It can also be configured via link:https://alchemists.io/projects/xdg[XDG] environment
|
100
100
|
variables. The default configuration is:
|
101
101
|
|
102
102
|
[source,yaml]
|
@@ -587,9 +587,9 @@ In practice, it is quite rare to need a prefix other than what has been detailed
|
|
587
587
|
_what_ is being committed. These prefixes are not only short and easy to remember but also have the
|
588
588
|
added benefit of categorizing the commits for building release notes, change logs, etc. This becomes
|
589
589
|
handy when coupled with another tool,
|
590
|
-
link:https://
|
590
|
+
link:https://alchemists.io/projects/milestoner[Milestoner], for producing consistent project
|
591
591
|
milestones and Git tag histories. For a deeper dive on subject prefixes and good commit messages in
|
592
|
-
general, please read about link:https://
|
592
|
+
general, please read about link:https://alchemists.io/articles/git_commit_anatomy[commit anatomy
|
593
593
|
] to learn more. 🎉
|
594
594
|
|
595
595
|
Each prefix is delimited by a space which is the default setting but can be customized if desired.
|
@@ -609,7 +609,7 @@ a Git Hook in order to not disturb interactive rebase workflows.
|
|
609
609
|
|
610
610
|
Ensures commit subjects are suffixed consistently. The exclude list _is_ case sensitive and prevents
|
611
611
|
the use of punctuation. This is handy when coupled with a tool, like
|
612
|
-
link:https://
|
612
|
+
link:https://alchemists.io/projects/milestoner[Milestoner], which automates project milestone
|
613
613
|
releases.
|
614
614
|
|
615
615
|
==== Commit Trailer Collaborator Capitalization
|
@@ -1139,7 +1139,7 @@ configuration disabled.
|
|
1139
1139
|
|
1140
1140
|
=== Tags
|
1141
1141
|
|
1142
|
-
* Use tags to denote link:https://
|
1142
|
+
* Use tags to denote link:https://alchemists.io/projects/milestoner[milestones]/releases:
|
1143
1143
|
** Makes it easier to record milestones and capture associated release notes.
|
1144
1144
|
** Makes it easier to compare differences between versions.
|
1145
1145
|
** Provides a starting point for debugging production issues (if any).
|
@@ -1165,7 +1165,7 @@ configuration disabled.
|
|
1165
1165
|
=== Code Reviews
|
1166
1166
|
|
1167
1167
|
For an in depth look at how to conduct code reviews, please read my
|
1168
|
-
link:https://
|
1168
|
+
link:https://alchemists.io/articles/code_reviews[article] on this subject to learn more.
|
1169
1169
|
|
1170
1170
|
== Development
|
1171
1171
|
|
@@ -1191,22 +1191,22 @@ To test, run:
|
|
1191
1191
|
|
1192
1192
|
[source,bash]
|
1193
1193
|
----
|
1194
|
-
|
1194
|
+
bin/rake
|
1195
1195
|
----
|
1196
1196
|
|
1197
|
-
== link:https://
|
1197
|
+
== link:https://alchemists.io/policies/license[License]
|
1198
1198
|
|
1199
|
-
== link:https://
|
1199
|
+
== link:https://alchemists.io/policies/security[Security]
|
1200
1200
|
|
1201
|
-
== link:https://
|
1201
|
+
== link:https://alchemists.io/policies/code_of_conduct[Code of Conduct]
|
1202
1202
|
|
1203
|
-
== link:https://
|
1203
|
+
== link:https://alchemists.io/policies/contributions[Contributions]
|
1204
1204
|
|
1205
|
-
== link:https://
|
1205
|
+
== link:https://alchemists.io/projects/git-lint/versions[Versions]
|
1206
1206
|
|
1207
|
-
== link:https://
|
1207
|
+
== link:https://alchemists.io/community[Community]
|
1208
1208
|
|
1209
1209
|
== Credits
|
1210
1210
|
|
1211
|
-
* Built with link:https://
|
1212
|
-
* Engineered by link:https://
|
1211
|
+
* Built with link:https://alchemists.io/projects/gemsmith[Gemsmith].
|
1212
|
+
* Engineered by link:https://alchemists.io/team/brooke_kuhlmann[Brooke Kuhlmann].
|
data/git-lint.gemspec
CHANGED
@@ -2,17 +2,17 @@
|
|
2
2
|
|
3
3
|
Gem::Specification.new do |spec|
|
4
4
|
spec.name = "git-lint"
|
5
|
-
spec.version = "5.1.
|
5
|
+
spec.version = "5.1.2"
|
6
6
|
spec.authors = ["Brooke Kuhlmann"]
|
7
7
|
spec.email = ["brooke@alchemists.io"]
|
8
|
-
spec.homepage = "https://
|
8
|
+
spec.homepage = "https://alchemists.io/projects/git-lint"
|
9
9
|
spec.summary = "A command line interface for linting Git commits."
|
10
10
|
spec.license = "Hippocratic-2.1"
|
11
11
|
|
12
12
|
spec.metadata = {
|
13
13
|
"bug_tracker_uri" => "https://github.com/bkuhlmann/git-lint/issues",
|
14
|
-
"changelog_uri" => "https://
|
15
|
-
"documentation_uri" => "https://
|
14
|
+
"changelog_uri" => "https://alchemists.io/projects/git-lint/versions",
|
15
|
+
"documentation_uri" => "https://alchemists.io/projects/git-lint",
|
16
16
|
"funding_uri" => "https://github.com/sponsors/bkuhlmann",
|
17
17
|
"label" => "Git Lint",
|
18
18
|
"rubygems_mfa_required" => "true",
|
data/lib/git/lint/analyzer.rb
CHANGED
@@ -6,6 +6,7 @@ module Git
|
|
6
6
|
class Analyzer
|
7
7
|
include Import[:configuration]
|
8
8
|
|
9
|
+
# rubocop:todo Metrics/CollectionLiteralLength
|
9
10
|
ANALYZERS = [
|
10
11
|
Analyzers::CommitAuthorCapitalization,
|
11
12
|
Analyzers::CommitAuthorEmail,
|
@@ -40,13 +41,16 @@ module Git
|
|
40
41
|
Analyzers::CommitTrailerTrackerKey,
|
41
42
|
Analyzers::CommitTrailerTrackerValue
|
42
43
|
].freeze
|
44
|
+
# rubocop:enable Metrics/CollectionLiteralLength
|
43
45
|
|
44
46
|
# rubocop:disable Metrics/ParameterLists
|
45
|
-
def initialize
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
47
|
+
def initialize(
|
48
|
+
analyzers: ANALYZERS,
|
49
|
+
collector: Collector.new,
|
50
|
+
reporter: Reporters::Branch,
|
51
|
+
**
|
52
|
+
)
|
53
|
+
super(**)
|
50
54
|
@analyzers = analyzers
|
51
55
|
@collector = collector
|
52
56
|
@reporter = reporter
|
@@ -8,8 +8,8 @@ module Git
|
|
8
8
|
class Config
|
9
9
|
include Git::Lint::Import[:kernel, :logger]
|
10
10
|
|
11
|
-
def initialize
|
12
|
-
super(**
|
11
|
+
def initialize(configuration: Configuration::Loader::CLIENT, **)
|
12
|
+
super(**)
|
13
13
|
@configuration = configuration
|
14
14
|
end
|
15
15
|
|
data/lib/git/lint/cli/parser.rb
CHANGED
@@ -13,8 +13,8 @@ module Git
|
|
13
13
|
CLIENT = OptionParser.new nil, 40, " "
|
14
14
|
SECTIONS = [Parsers::Core, Parsers::Analyze].freeze # Order matters.
|
15
15
|
|
16
|
-
def initialize
|
17
|
-
super(**
|
16
|
+
def initialize(sections: SECTIONS, client: CLIENT, **)
|
17
|
+
super(**)
|
18
18
|
@sections = sections
|
19
19
|
@client = client
|
20
20
|
@configuration_duplicate = configuration.dup
|
@@ -15,10 +15,8 @@ module Git
|
|
15
15
|
|
16
16
|
def self.call(...) = new(...).call
|
17
17
|
|
18
|
-
def initialize
|
19
|
-
|
20
|
-
**dependencies
|
21
|
-
super(**dependencies)
|
18
|
+
def initialize(configuration = Container[:configuration], client: Parser::CLIENT, **)
|
19
|
+
super(**)
|
22
20
|
@configuration = configuration
|
23
21
|
@client = client
|
24
22
|
end
|
data/lib/git/lint/cli/shell.rb
CHANGED
@@ -16,13 +16,13 @@ module Git
|
|
16
16
|
:logger
|
17
17
|
]
|
18
18
|
|
19
|
-
def initialize
|
20
|
-
super(**
|
19
|
+
def initialize(parser: Parser.new, **)
|
20
|
+
super(**)
|
21
21
|
@parser = parser
|
22
22
|
end
|
23
23
|
|
24
24
|
def call arguments = Core::EMPTY_ARRAY
|
25
|
-
|
25
|
+
act_on parser.call(arguments)
|
26
26
|
rescue OptionParser::ParseError, Errors::Base => error
|
27
27
|
logger.error { error.message }
|
28
28
|
end
|
@@ -31,7 +31,7 @@ module Git
|
|
31
31
|
|
32
32
|
attr_reader :parser
|
33
33
|
|
34
|
-
def
|
34
|
+
def act_on configuration
|
35
35
|
case configuration
|
36
36
|
in action_analyze: true, analyze_sha: nil then analyze_branch.call
|
37
37
|
in action_analyze: true, analyze_sha: String => sha then analyze_commit.call sha
|
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: 5.1.
|
4
|
+
version: 5.1.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Brooke Kuhlmann
|
@@ -10,25 +10,32 @@ bindir: exe
|
|
10
10
|
cert_chain:
|
11
11
|
- |
|
12
12
|
-----BEGIN CERTIFICATE-----
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
13
|
+
MIIEeDCCAuCgAwIBAgIBATANBgkqhkiG9w0BAQsFADBBMQ8wDQYDVQQDDAZicm9v
|
14
|
+
a2UxGjAYBgoJkiaJk/IsZAEZFgphbGNoZW1pc3RzMRIwEAYKCZImiZPyLGQBGRYC
|
15
|
+
aW8wHhcNMjMwMzIyMTYxNDQxWhcNMjUwMzIxMTYxNDQxWjBBMQ8wDQYDVQQDDAZi
|
16
|
+
cm9va2UxGjAYBgoJkiaJk/IsZAEZFgphbGNoZW1pc3RzMRIwEAYKCZImiZPyLGQB
|
17
|
+
GRYCaW8wggGiMA0GCSqGSIb3DQEBAQUAA4IBjwAwggGKAoIBgQCro8tj5/E1Hg88
|
18
|
+
f4qfiwPVd2zJQHvdYt4GHVvuHRRgx4H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DKJRcusZ12lNBeDfgqACz/BBJF8FLodgk6rGMRZz7+ZmjjHEmpG5bQpR6Q2BuWL
|
34
|
+
XMtYk/QzaWuhiR7pWjiF8jbdd7RO6or0ohq7iFkokz/5xrtQ/vPzU2RQ3Qc6YaKw
|
35
|
+
3n5C8/6Zh9DYTkpcwPSuIfAga6wf4nXc9m6JAw8AuMLaiWN/r/2s4zJsUHYERJEu
|
36
|
+
gZGm4JqtuSg8pYjPeIJxS960owq+SfuC+jxqmRA54BisFCv/0VOJi7tiJVY=
|
30
37
|
-----END CERTIFICATE-----
|
31
|
-
date: 2023-
|
38
|
+
date: 2023-03-22 00:00:00.000000000 Z
|
32
39
|
dependencies:
|
33
40
|
- !ruby/object:Gem::Dependency
|
34
41
|
name: cogger
|
@@ -271,13 +278,13 @@ files:
|
|
271
278
|
- lib/git/lint/validators/capitalization.rb
|
272
279
|
- lib/git/lint/validators/email.rb
|
273
280
|
- lib/git/lint/validators/name.rb
|
274
|
-
homepage: https://
|
281
|
+
homepage: https://alchemists.io/projects/git-lint
|
275
282
|
licenses:
|
276
283
|
- Hippocratic-2.1
|
277
284
|
metadata:
|
278
285
|
bug_tracker_uri: https://github.com/bkuhlmann/git-lint/issues
|
279
|
-
changelog_uri: https://
|
280
|
-
documentation_uri: https://
|
286
|
+
changelog_uri: https://alchemists.io/projects/git-lint/versions
|
287
|
+
documentation_uri: https://alchemists.io/projects/git-lint
|
281
288
|
funding_uri: https://github.com/sponsors/bkuhlmann
|
282
289
|
label: Git Lint
|
283
290
|
rubygems_mfa_required: 'true'
|
@@ -297,7 +304,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
297
304
|
- !ruby/object:Gem::Version
|
298
305
|
version: '0'
|
299
306
|
requirements: []
|
300
|
-
rubygems_version: 3.4.
|
307
|
+
rubygems_version: 3.4.9
|
301
308
|
signing_key:
|
302
309
|
specification_version: 4
|
303
310
|
summary: A command line interface for linting Git commits.
|
metadata.gz.sig
CHANGED
Binary file
|