metanorma-release 0.2.2 → 0.2.3

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.
Files changed (66) hide show
  1. checksums.yaml +4 -4
  2. data/.rubocop.yml +19 -1
  3. data/.rubocop_todo.yml +250 -319
  4. data/README.adoc +120 -233
  5. data/Rakefile +2 -2
  6. data/exe/metanorma-release +2 -2
  7. data/lib/metanorma/release/aggregation_pipeline.rb +59 -45
  8. data/lib/metanorma/release/asset_processor.rb +10 -8
  9. data/lib/metanorma/release/cache_store.rb +6 -6
  10. data/lib/metanorma/release/change_detector.rb +7 -3
  11. data/lib/metanorma/release/channel.rb +13 -39
  12. data/lib/metanorma/release/channel_filter.rb +26 -10
  13. data/lib/metanorma/release/cli.rb +129 -100
  14. data/lib/metanorma/release/commands/aggregate.rb +39 -54
  15. data/lib/metanorma/release/commands/package.rb +20 -12
  16. data/lib/metanorma/release/commands/{publish.rb → release_command.rb} +20 -12
  17. data/lib/metanorma/release/config.rb +104 -0
  18. data/lib/metanorma/release/content_hash.rb +11 -3
  19. data/lib/metanorma/release/delta_state.rb +55 -18
  20. data/lib/metanorma/release/file_routing.rb +8 -5
  21. data/lib/metanorma/release/index.rb +132 -0
  22. data/lib/metanorma/release/interfaces.rb +15 -15
  23. data/lib/metanorma/release/platform/github/manifest_reader.rb +4 -4
  24. data/lib/metanorma/release/platform/github/publisher.rb +23 -11
  25. data/lib/metanorma/release/platform/github/release_fetcher.rb +12 -3
  26. data/lib/metanorma/release/platform/github.rb +10 -7
  27. data/lib/metanorma/release/platform/local/directory_discoverer.rb +1 -1
  28. data/lib/metanorma/release/platform/local/fetcher.rb +17 -12
  29. data/lib/metanorma/release/platform/local/publisher.rb +9 -7
  30. data/lib/metanorma/release/platform/local.rb +4 -4
  31. data/lib/metanorma/release/platform/null/publisher.rb +3 -2
  32. data/lib/metanorma/release/platform/null.rb +1 -1
  33. data/lib/metanorma/release/platform.rb +3 -3
  34. data/lib/metanorma/release/platform_factory.rb +48 -29
  35. data/lib/metanorma/release/publication.rb +335 -0
  36. data/lib/metanorma/release/release_pipeline.rb +85 -52
  37. data/lib/metanorma/release/repo_ref.rb +5 -2
  38. data/lib/metanorma/release/site.rb +66 -0
  39. data/lib/metanorma/release/slug_strategy.rb +163 -0
  40. data/lib/metanorma/release/version.rb +1 -1
  41. data/lib/metanorma/release/zip_packager.rb +31 -8
  42. data/lib/metanorma/release.rb +68 -94
  43. metadata +22 -26
  44. data/lib/metanorma/release/aggregation_interfaces.rb +0 -27
  45. data/lib/metanorma/release/channel_audience.rb +0 -24
  46. data/lib/metanorma/release/channel_config.rb +0 -55
  47. data/lib/metanorma/release/channel_manifest.rb +0 -192
  48. data/lib/metanorma/release/channel_registry.rb +0 -60
  49. data/lib/metanorma/release/config_fetcher.rb +0 -11
  50. data/lib/metanorma/release/config_locator.rb +0 -37
  51. data/lib/metanorma/release/config_resolver.rb +0 -37
  52. data/lib/metanorma/release/document_id.rb +0 -45
  53. data/lib/metanorma/release/document_index.rb +0 -183
  54. data/lib/metanorma/release/document_metadata.rb +0 -39
  55. data/lib/metanorma/release/document_stage.rb +0 -86
  56. data/lib/metanorma/release/document_type.rb +0 -55
  57. data/lib/metanorma/release/document_version.rb +0 -50
  58. data/lib/metanorma/release/naming_strategy.rb +0 -158
  59. data/lib/metanorma/release/platform/github/config_fetcher.rb +0 -40
  60. data/lib/metanorma/release/platform/local/config_fetcher.rb +0 -20
  61. data/lib/metanorma/release/rake_tasks.rb +0 -71
  62. data/lib/metanorma/release/relaton_enricher.rb +0 -138
  63. data/lib/metanorma/release/release_metadata.rb +0 -79
  64. data/lib/metanorma/release/release_tag.rb +0 -49
  65. data/lib/metanorma/release/rxl_extractor.rb +0 -115
  66. data/lib/metanorma/release/stage_filter.rb +0 -18
data/.rubocop_todo.yml CHANGED
@@ -1,330 +1,284 @@
1
1
  # This configuration was generated by
2
2
  # `rubocop --auto-gen-config`
3
- # on 2026-05-15 16:10:17 UTC using RuboCop version 1.86.2.
3
+ # on 2026-05-17 05:08:25 UTC using RuboCop version 1.86.2.
4
4
  # The point is for the user to remove these configuration records
5
5
  # one by one as the offenses are removed from the code base.
6
6
  # Note that changes in the inspected code, or installation of new
7
7
  # versions of RuboCop, may require this file to be generated again.
8
8
 
9
- # Offense count: 1
9
+ # Offense count: 2
10
10
  # This cop supports safe autocorrection (--autocorrect).
11
11
  # Configuration parameters: TreatCommentsAsGroupSeparators, ConsiderPunctuation.
12
- Gemspec/OrderedDependencies:
12
+ Bundler/OrderedGems:
13
+ Exclude:
14
+ - 'Gemfile'
15
+
16
+ # Offense count: 2
17
+ # This cop supports safe autocorrection (--autocorrect).
18
+ Gemspec/AddRuntimeDependency:
19
+ Exclude:
20
+ - 'metanorma-release.gemspec'
21
+
22
+ # Offense count: 2
23
+ # Configuration parameters: EnforcedStyle, AllowedGems.
24
+ # SupportedStyles: Gemfile, gems.rb, gemspec
25
+ Gemspec/DevelopmentDependencies:
26
+ Exclude:
27
+ - 'metanorma-release.gemspec'
28
+
29
+ # Offense count: 1
30
+ Gemspec/RequiredRubyVersion:
13
31
  Exclude:
14
32
  - 'metanorma-release.gemspec'
15
33
 
16
- # Offense count: 29
34
+ # Offense count: 121
17
35
  # This cop supports safe autocorrection (--autocorrect).
18
36
  # Configuration parameters: EnforcedStyle, IndentationWidth.
19
37
  # SupportedStyles: with_first_argument, with_fixed_indentation
20
38
  Layout/ArgumentAlignment:
39
+ Enabled: false
40
+
41
+ # Offense count: 2
42
+ # This cop supports safe autocorrection (--autocorrect).
43
+ # Configuration parameters: EnforcedStyle, IndentationWidth.
44
+ # SupportedStyles: with_first_element, with_fixed_indentation
45
+ Layout/ArrayAlignment:
21
46
  Exclude:
22
- - 'lib/metanorma/release/cli.rb'
23
- - 'lib/metanorma/release/document_index.rb'
24
- - 'spec/aggregation/aggregation_pipeline_spec.rb'
25
- - 'spec/aggregation/file_routing_spec.rb'
26
- - 'spec/domain/naming_strategy_spec.rb'
27
- - 'spec/integration/channel_filtering_spec.rb'
28
- - 'spec/integration/delta_dedup_spec.rb'
29
- - 'spec/integration/file_routing_spec.rb'
30
- - 'spec/integration/local_round_trip_spec.rb'
31
- - 'spec/integration/release_publish_spec.rb'
32
- - 'spec/integration/verification_spec.rb'
47
+ - 'lib/metanorma/release/platform/local/fetcher.rb'
48
+ - 'spec/cli_spec.rb'
33
49
 
34
- # Offense count: 13
50
+ # Offense count: 1
51
+ # This cop supports safe autocorrection (--autocorrect).
52
+ # Configuration parameters: IndentationWidth.
53
+ Layout/AssignmentIndentation:
54
+ Exclude:
55
+ - 'metanorma-release.gemspec'
56
+
57
+ # Offense count: 19
35
58
  # This cop supports safe autocorrection (--autocorrect).
36
59
  # Configuration parameters: EnforcedStyleAlignWith.
37
60
  # SupportedStylesAlignWith: either, start_of_block, start_of_line
38
61
  Layout/BlockAlignment:
39
62
  Exclude:
40
- - 'lib/metanorma/release/relaton_enricher.rb'
63
+ - 'lib/metanorma/release/channel_filter.rb'
64
+ - 'lib/metanorma/release/cli.rb'
65
+ - 'lib/metanorma/release/content_hash.rb'
66
+ - 'lib/metanorma/release/index.rb'
67
+ - 'lib/metanorma/release/platform/github/publisher.rb'
68
+ - 'lib/metanorma/release/platform_factory.rb'
69
+ - 'lib/metanorma/release/release_pipeline.rb'
70
+ - 'lib/metanorma/release/zip_packager.rb'
71
+ - 'spec/aggregation/delta_state_spec.rb'
72
+ - 'spec/aggregation/file_routing_spec.rb'
41
73
  - 'spec/cli_spec.rb'
74
+ - 'spec/domain/config_spec.rb'
75
+ - 'spec/domain/repo_ref_spec.rb'
76
+ - 'spec/platform_factory_spec.rb'
42
77
 
43
- # Offense count: 13
78
+ # Offense count: 19
44
79
  # This cop supports safe autocorrection (--autocorrect).
45
80
  Layout/BlockEndNewline:
46
81
  Exclude:
47
- - 'lib/metanorma/release/relaton_enricher.rb'
82
+ - 'lib/metanorma/release/channel_filter.rb'
83
+ - 'lib/metanorma/release/cli.rb'
84
+ - 'lib/metanorma/release/content_hash.rb'
85
+ - 'lib/metanorma/release/index.rb'
86
+ - 'lib/metanorma/release/platform/github/publisher.rb'
87
+ - 'lib/metanorma/release/platform_factory.rb'
88
+ - 'lib/metanorma/release/release_pipeline.rb'
89
+ - 'lib/metanorma/release/zip_packager.rb'
90
+ - 'spec/aggregation/delta_state_spec.rb'
91
+ - 'spec/aggregation/file_routing_spec.rb'
48
92
  - 'spec/cli_spec.rb'
93
+ - 'spec/domain/config_spec.rb'
94
+ - 'spec/domain/repo_ref_spec.rb'
95
+ - 'spec/platform_factory_spec.rb'
49
96
 
50
- # Offense count: 2
97
+ # Offense count: 3
51
98
  # This cop supports safe autocorrection (--autocorrect).
52
99
  # Configuration parameters: IndentationWidth.
53
100
  Layout/ClosingParenthesisIndentation:
54
101
  Exclude:
102
+ - 'spec/integration/file_routing_spec.rb'
55
103
  - 'spec/integration/local_round_trip_spec.rb'
56
104
  - 'spec/integration/release_publish_spec.rb'
57
105
 
58
- # Offense count: 15
59
- # This cop supports safe autocorrection (--autocorrect).
60
- Layout/EmptyLineAfterGuardClause:
61
- Exclude:
62
- - 'lib/metanorma/release/aggregation_pipeline.rb'
63
- - 'lib/metanorma/release/cache_store.rb'
64
- - 'lib/metanorma/release/channel_manifest.rb'
65
- - 'lib/metanorma/release/cli.rb'
66
- - 'lib/metanorma/release/platform_factory.rb'
67
- - 'lib/metanorma/release/repo_ref.rb'
68
- - 'lib/metanorma/release/rxl_extractor.rb'
69
- - 'lib/metanorma/release/stage_filter.rb'
70
-
71
- # Offense count: 2
106
+ # Offense count: 1
72
107
  # This cop supports safe autocorrection (--autocorrect).
73
- # Configuration parameters: EmptyLineBetweenMethodDefs, EmptyLineBetweenClassDefs, EmptyLineBetweenModuleDefs, DefLikeMacros, AllowAdjacentOneLineDefs, NumberOfEmptyLines.
74
- Layout/EmptyLineBetweenDefs:
108
+ Layout/ElseAlignment:
75
109
  Exclude:
76
- - 'lib/metanorma/release/channel_registry.rb'
77
- - 'lib/metanorma/release/document_index.rb'
110
+ - 'lib/metanorma/release/content_hash.rb'
78
111
 
79
- # Offense count: 4
112
+ # Offense count: 3
80
113
  # This cop supports safe autocorrection (--autocorrect).
81
114
  Layout/EmptyLines:
82
115
  Exclude:
83
- - 'lib/metanorma/release/channel_config.rb'
84
- - 'lib/metanorma/release/channel_manifest.rb'
85
- - 'lib/metanorma/release/channel_registry.rb'
86
- - 'lib/metanorma/release/document_index.rb'
87
-
88
- # Offense count: 4
89
- # This cop supports safe autocorrection (--autocorrect).
90
- # Configuration parameters: EnforcedStyle.
91
- # SupportedStyles: empty_lines, no_empty_lines
92
- Layout/EmptyLinesAroundBlockBody:
93
- Exclude:
94
- - 'lib/metanorma/release/aggregation_pipeline.rb'
95
- - 'lib/metanorma/release/rxl_extractor.rb'
116
+ - 'lib/metanorma/release/delta_state.rb'
117
+ - 'spec/platform/local/fetcher_spec.rb'
118
+ - 'spec/platform/local/publisher_spec.rb'
96
119
 
97
120
  # Offense count: 1
98
121
  # This cop supports safe autocorrection (--autocorrect).
99
- Layout/EmptyLinesAroundMethodBody:
122
+ Layout/EmptyLinesAfterModuleInclusion:
100
123
  Exclude:
101
- - 'lib/metanorma/release/channel_manifest.rb'
124
+ - 'lib/metanorma/release/platform_factory.rb'
102
125
 
103
- # Offense count: 13
126
+ # Offense count: 1
104
127
  # This cop supports safe autocorrection (--autocorrect).
105
- # Configuration parameters: AllowForAlignment, AllowBeforeTrailingComments, ForceEqualSignAlignment.
106
- Layout/ExtraSpacing:
128
+ # Configuration parameters: EnforcedStyleAlignWith.
129
+ # SupportedStylesAlignWith: keyword, variable, start_of_line
130
+ Layout/EndAlignment:
107
131
  Exclude:
108
- - 'lib/metanorma/release/cache_store.rb'
109
- - 'lib/metanorma/release/document_type.rb'
110
- - 'lib/metanorma/release/relaton_enricher.rb'
132
+ - 'lib/metanorma/release/content_hash.rb'
111
133
 
112
- # Offense count: 2
134
+ # Offense count: 3
113
135
  # This cop supports safe autocorrection (--autocorrect).
114
136
  # Configuration parameters: EnforcedStyle, IndentationWidth.
115
137
  # SupportedStyles: consistent, consistent_relative_to_receiver, special_for_inner_method_call, special_for_inner_method_call_in_parentheses
116
138
  Layout/FirstArgumentIndentation:
117
139
  Exclude:
140
+ - 'spec/integration/file_routing_spec.rb'
118
141
  - 'spec/integration/local_round_trip_spec.rb'
119
142
  - 'spec/integration/release_publish_spec.rb'
120
143
 
121
- # Offense count: 2
122
- # This cop supports safe autocorrection (--autocorrect).
123
- # Configuration parameters: EnforcedStyle, IndentationWidth.
124
- # SupportedStyles: special_inside_parentheses, consistent, align_brackets
125
- Layout/FirstArrayElementIndentation:
126
- Exclude:
127
- - 'spec/platform/github/release_fetcher_spec.rb'
128
-
129
- # Offense count: 16
130
- # This cop supports safe autocorrection (--autocorrect).
131
- # Configuration parameters: EnforcedStyle, IndentationWidth.
132
- # SupportedStyles: special_inside_parentheses, consistent, align_braces
133
- Layout/FirstHashElementIndentation:
134
- Exclude:
135
- - 'spec/aggregation/document_index_spec.rb'
136
- - 'spec/platform/local/fetcher_spec.rb'
137
-
138
- # Offense count: 50
144
+ # Offense count: 68
139
145
  # This cop supports safe autocorrection (--autocorrect).
140
146
  # Configuration parameters: AllowMultipleStyles, EnforcedHashRocketStyle, EnforcedColonStyle, EnforcedLastArgumentHashStyle.
141
147
  # SupportedHashRocketStyles: key, separator, table
142
148
  # SupportedColonStyles: key, separator, table
143
149
  # SupportedLastArgumentHashStyles: always_inspect, always_ignore, ignore_implicit, ignore_explicit
144
150
  Layout/HashAlignment:
145
- Exclude:
146
- - 'lib/metanorma/release/cli.rb'
147
- - 'spec/aggregation/aggregation_pipeline_spec.rb'
148
- - 'spec/aggregation/document_index_spec.rb'
149
- - 'spec/aggregation/relaton_enricher_spec.rb'
150
- - 'spec/domain/document_type_spec.rb'
151
- - 'spec/integration/channel_filtering_spec.rb'
152
- - 'spec/integration/delta_dedup_spec.rb'
153
- - 'spec/integration/file_routing_spec.rb'
154
- - 'spec/integration/local_round_trip_spec.rb'
155
- - 'spec/integration/release_publish_spec.rb'
156
- - 'spec/integration/verification_spec.rb'
157
- - 'spec/platform/local/fetcher_spec.rb'
158
-
159
- # Offense count: 49
160
- # This cop supports safe autocorrection (--autocorrect).
161
- # Configuration parameters: EnforcedStyle.
162
- # SupportedStyles: normal, indented_internal_methods
163
- Layout/IndentationConsistency:
164
- Exclude:
165
- - 'lib/metanorma/release/channel_manifest.rb'
166
- - 'lib/metanorma/release/relaton_enricher.rb'
151
+ Enabled: false
167
152
 
168
- # Offense count: 28
153
+ # Offense count: 40
169
154
  # This cop supports safe autocorrection (--autocorrect).
170
155
  # Configuration parameters: Width, EnforcedStyleAlignWith, AllowedPatterns.
171
156
  # SupportedStylesAlignWith: start_of_line, relative_to_receiver
172
157
  Layout/IndentationWidth:
173
158
  Exclude:
174
- - 'lib/metanorma/release/aggregation_pipeline.rb'
175
- - 'lib/metanorma/release/relaton_enricher.rb'
176
- - 'lib/metanorma/release/rxl_extractor.rb'
159
+ - 'lib/metanorma/release/channel_filter.rb'
160
+ - 'lib/metanorma/release/cli.rb'
161
+ - 'lib/metanorma/release/content_hash.rb'
162
+ - 'lib/metanorma/release/index.rb'
163
+ - 'lib/metanorma/release/platform/github/publisher.rb'
164
+ - 'lib/metanorma/release/platform_factory.rb'
165
+ - 'lib/metanorma/release/release_pipeline.rb'
166
+ - 'lib/metanorma/release/zip_packager.rb'
167
+ - 'spec/aggregation/delta_state_spec.rb'
168
+ - 'spec/aggregation/file_routing_spec.rb'
177
169
  - 'spec/cli_spec.rb'
170
+ - 'spec/domain/config_spec.rb'
171
+ - 'spec/domain/repo_ref_spec.rb'
172
+ - 'spec/platform_factory_spec.rb'
178
173
 
179
- # Offense count: 12
174
+ # Offense count: 234
180
175
  # This cop supports safe autocorrection (--autocorrect).
181
- Layout/MultilineBlockLayout:
182
- Exclude:
183
- - 'lib/metanorma/release/relaton_enricher.rb'
176
+ # Configuration parameters: Max, AllowHeredoc, AllowURI, AllowQualifiedName, URISchemes, AllowRBSInlineAnnotation, AllowCopDirectives, AllowedPatterns, SplitStrings.
177
+ # URISchemes: http, https
178
+ Layout/LineLength:
179
+ Enabled: false
184
180
 
185
- # Offense count: 2
181
+ # Offense count: 3
186
182
  # This cop supports safe autocorrection (--autocorrect).
187
183
  # Configuration parameters: EnforcedStyle.
188
184
  # SupportedStyles: symmetrical, new_line, same_line
189
185
  Layout/MultilineMethodCallBraceLayout:
190
186
  Exclude:
187
+ - 'spec/integration/file_routing_spec.rb'
191
188
  - 'spec/integration/local_round_trip_spec.rb'
192
189
  - 'spec/integration/release_publish_spec.rb'
193
190
 
194
- # Offense count: 2
191
+ # Offense count: 7
195
192
  # This cop supports safe autocorrection (--autocorrect).
196
193
  # Configuration parameters: EnforcedStyle, IndentationWidth.
197
194
  # SupportedStyles: aligned, indented, indented_relative_to_receiver
198
195
  Layout/MultilineMethodCallIndentation:
199
196
  Exclude:
197
+ - 'lib/metanorma/release/asset_processor.rb'
200
198
  - 'lib/metanorma/release/cache_store.rb'
199
+ - 'lib/metanorma/release/publication.rb'
201
200
 
202
- # Offense count: 2
203
- # This cop supports safe autocorrection (--autocorrect).
204
- Layout/RescueEnsureAlignment:
205
- Exclude:
206
- - 'lib/metanorma/release/aggregation_pipeline.rb'
207
- - 'lib/metanorma/release/rxl_extractor.rb'
208
-
209
- # Offense count: 1
210
- # This cop supports safe autocorrection (--autocorrect).
211
- # Configuration parameters: EnforcedStyleInsidePipes.
212
- # SupportedStylesInsidePipes: space, no_space
213
- Layout/SpaceAroundBlockParameters:
214
- Exclude:
215
- - 'lib/metanorma/release/cache_store.rb'
216
-
217
- # Offense count: 28
201
+ # Offense count: 110
218
202
  # This cop supports safe autocorrection (--autocorrect).
219
203
  # Configuration parameters: AllowInHeredoc.
220
204
  Layout/TrailingWhitespace:
221
- Exclude:
222
- - 'lib/metanorma/release/aggregation_pipeline.rb'
223
- - 'lib/metanorma/release/channel_manifest.rb'
224
- - 'lib/metanorma/release/cli.rb'
225
- - 'lib/metanorma/release/document_index.rb'
226
- - 'lib/metanorma/release/relaton_enricher.rb'
227
- - 'lib/metanorma/release/rxl_extractor.rb'
228
- - 'spec/aggregation/aggregation_pipeline_spec.rb'
229
- - 'spec/integration/channel_filtering_spec.rb'
230
- - 'spec/integration/delta_dedup_spec.rb'
231
- - 'spec/integration/file_routing_spec.rb'
232
- - 'spec/integration/local_round_trip_spec.rb'
233
- - 'spec/integration/release_publish_spec.rb'
234
- - 'spec/integration/verification_spec.rb'
205
+ Enabled: false
235
206
 
236
- # Offense count: 3
207
+ # Offense count: 4
237
208
  Lint/IneffectiveAccessModifier:
238
209
  Exclude:
239
- - 'lib/metanorma/release/channel_manifest.rb'
210
+ - 'lib/metanorma/release/publication.rb'
240
211
 
241
- # Offense count: 1
242
- # This cop supports safe autocorrection (--autocorrect).
243
- Lint/RedundantStringCoercion:
212
+ # Offense count: 5
213
+ # This cop supports unsafe autocorrection (--autocorrect-all).
214
+ Lint/NonAtomicFileOperation:
244
215
  Exclude:
245
- - 'spec/aggregation/aggregation_pipeline_spec.rb'
216
+ - 'lib/metanorma/release/cache_store.rb'
217
+ - 'lib/metanorma/release/platform/local/publisher.rb'
218
+ - 'lib/metanorma/release/zip_packager.rb'
219
+ - 'spec/platform/local/fetcher_spec.rb'
246
220
 
247
- # Offense count: 4
221
+ # Offense count: 3
248
222
  Lint/StructNewOverride:
249
223
  Exclude:
250
- - 'lib/metanorma/release/interfaces.rb'
251
224
  - 'lib/metanorma/release/platform/github/release_fetcher.rb'
252
225
  - 'lib/metanorma/release/platform/local/fetcher.rb'
253
- - 'spec/aggregation/aggregation_pipeline_spec.rb'
226
+ - 'lib/metanorma/release/zip_packager.rb'
254
227
 
255
- # Offense count: 16
228
+ # Offense count: 7
256
229
  # This cop supports safe autocorrection (--autocorrect).
257
230
  # Configuration parameters: AllowUnusedKeywordArguments, IgnoreEmptyMethods, IgnoreNotImplementedMethods, NotImplementedExceptions.
258
231
  # NotImplementedExceptions: NotImplementedError
259
232
  Lint/UnusedMethodArgument:
260
233
  Exclude:
261
- - 'lib/metanorma/release/aggregation_pipeline.rb'
262
- - 'lib/metanorma/release/naming_strategy.rb'
263
- - 'lib/metanorma/release/platform/github/publisher.rb'
264
234
  - 'lib/metanorma/release/platform/github/release_fetcher.rb'
265
235
  - 'lib/metanorma/release/platform/local/fetcher.rb'
266
236
  - 'lib/metanorma/release/platform/local/publisher.rb'
267
237
  - 'lib/metanorma/release/platform/null/publisher.rb'
268
- - 'lib/metanorma/release/release_pipeline.rb'
269
238
  - 'spec/aggregation/aggregation_pipeline_spec.rb'
270
239
  - 'spec/release/release_pipeline_spec.rb'
271
240
 
272
- # Offense count: 4
273
- # This cop supports safe autocorrection (--autocorrect).
274
- # Configuration parameters: ContextCreatingMethods, MethodCreatingMethods.
275
- Lint/UselessAccessModifier:
276
- Exclude:
277
- - 'lib/metanorma/release/channel_config.rb'
278
- - 'lib/metanorma/release/channel_manifest.rb'
279
- - 'lib/metanorma/release/channel_registry.rb'
280
- - 'lib/metanorma/release/document_index.rb'
281
-
282
- # Offense count: 3
283
- # This cop supports safe autocorrection (--autocorrect).
284
- Lint/UselessAssignment:
285
- Exclude:
286
- - 'spec/release/release_pipeline_spec.rb'
287
-
288
- # Offense count: 20
289
- # Configuration parameters: AllowedMethods, AllowedPatterns, CountRepeatedAttributes.
241
+ # Offense count: 25
242
+ # Configuration parameters: AllowedMethods, AllowedPatterns, CountRepeatedAttributes, Max.
290
243
  Metrics/AbcSize:
291
- Max: 87
244
+ Enabled: false
292
245
 
293
- # Offense count: 54
294
- # Configuration parameters: CountComments, CountAsOne, AllowedMethods, AllowedPatterns.
246
+ # Offense count: 1
247
+ # Configuration parameters: CountComments, CountAsOne, AllowedMethods, AllowedPatterns, inherit_mode.
295
248
  # AllowedMethods: refine
296
249
  Metrics/BlockLength:
297
- Max: 232
298
-
299
- # Offense count: 2
300
- # Configuration parameters: CountComments, CountAsOne.
301
- Metrics/ClassLength:
302
- Max: 118
250
+ Max: 29
303
251
 
304
- # Offense count: 4
305
- # Configuration parameters: AllowedMethods, AllowedPatterns.
252
+ # Offense count: 8
253
+ # Configuration parameters: AllowedMethods, AllowedPatterns, Max.
306
254
  Metrics/CyclomaticComplexity:
307
- Max: 15
255
+ Exclude:
256
+ - 'lib/metanorma/release/aggregation_pipeline.rb'
257
+ - 'lib/metanorma/release/commands/aggregate.rb'
258
+ - 'lib/metanorma/release/config.rb'
259
+ - 'lib/metanorma/release/publication.rb'
260
+ - 'lib/metanorma/release/release_pipeline.rb'
261
+ - 'lib/metanorma/release/site.rb'
308
262
 
309
- # Offense count: 32
263
+ # Offense count: 26
310
264
  # Configuration parameters: CountComments, CountAsOne, AllowedMethods, AllowedPatterns.
311
265
  Metrics/MethodLength:
312
- Max: 51
313
-
314
- # Offense count: 1
315
- # Configuration parameters: CountComments, CountAsOne.
316
- Metrics/ModuleLength:
317
- Max: 182
266
+ Max: 43
318
267
 
319
- # Offense count: 3
268
+ # Offense count: 2
320
269
  # Configuration parameters: CountKeywordArgs, MaxOptionalParameters.
321
270
  Metrics/ParameterLists:
322
271
  Max: 11
323
272
 
324
- # Offense count: 3
325
- # Configuration parameters: AllowedMethods, AllowedPatterns.
273
+ # Offense count: 6
274
+ # Configuration parameters: AllowedMethods, AllowedPatterns, Max.
326
275
  Metrics/PerceivedComplexity:
327
- Max: 15
276
+ Exclude:
277
+ - 'lib/metanorma/release/aggregation_pipeline.rb'
278
+ - 'lib/metanorma/release/commands/aggregate.rb'
279
+ - 'lib/metanorma/release/config.rb'
280
+ - 'lib/metanorma/release/publication.rb'
281
+ - 'lib/metanorma/release/release_pipeline.rb'
328
282
 
329
283
  # Offense count: 1
330
284
  # Configuration parameters: MinNameLength, AllowNamesEndingInNumbers, AllowedNames, ForbiddenNames.
@@ -333,172 +287,149 @@ Naming/MethodParameterName:
333
287
  Exclude:
334
288
  - 'lib/metanorma/release/platform/github/release_fetcher.rb'
335
289
 
336
- # Offense count: 4
337
- # This cop supports safe autocorrection (--autocorrect).
338
- # Configuration parameters: EnforcedStyle.
339
- # SupportedStyles: separated, grouped
340
- Style/AccessorGrouping:
290
+ # Offense count: 5
291
+ # Configuration parameters: IgnoredMetadata.
292
+ RSpec/DescribeClass:
341
293
  Exclude:
342
- - 'lib/metanorma/release/channel_manifest.rb'
343
- - 'lib/metanorma/release/document_index.rb'
294
+ - 'spec/integration/channel_filtering_spec.rb'
295
+ - 'spec/integration/delta_dedup_spec.rb'
296
+ - 'spec/integration/file_routing_spec.rb'
297
+ - 'spec/integration/local_round_trip_spec.rb'
298
+ - 'spec/integration/release_publish_spec.rb'
344
299
 
345
- # Offense count: 20
300
+ # Offense count: 5
346
301
  # This cop supports safe autocorrection (--autocorrect).
347
- # Configuration parameters: EnforcedStyle, ProceduralMethods, FunctionalMethods, AllowedMethods, AllowedPatterns, AllowBracesOnProceduralOneLiners, BracesRequiredMethods.
348
- # SupportedStyles: line_count_based, semantic, braces_for_chaining, always_braces
349
- # ProceduralMethods: benchmark, bm, bmbm, create, each_with_object, measure, new, realtime, tap, with_object
350
- # FunctionalMethods: let, let!, subject, watch
351
- # AllowedMethods: lambda, proc, it
352
- Style/BlockDelimiters:
302
+ RSpec/EmptyLineAfterFinalLet:
353
303
  Exclude:
354
- - 'lib/metanorma/release/relaton_enricher.rb'
355
- - 'spec/cli_spec.rb'
356
- - 'spec/platform/null/publisher_spec.rb'
357
-
358
- # Offense count: 75
359
- # Configuration parameters: AllowedConstants.
360
- Style/Documentation:
361
- Enabled: false
304
+ - 'spec/integration/delta_dedup_spec.rb'
305
+ - 'spec/integration/local_round_trip_spec.rb'
306
+ - 'spec/platform/local/directory_discoverer_spec.rb'
307
+ - 'spec/platform/local/fetcher_spec.rb'
308
+ - 'spec/platform/local/publisher_spec.rb'
362
309
 
363
- # Offense count: 1
364
- # This cop supports safe autocorrection (--autocorrect).
365
- # Configuration parameters: MinBodyLength, AllowConsecutiveConditionals.
366
- Style/GuardClause:
367
- Exclude:
368
- - 'lib/metanorma/release/channel_manifest.rb'
310
+ # Offense count: 79
311
+ # Configuration parameters: CountAsOne.
312
+ RSpec/ExampleLength:
313
+ Max: 59
369
314
 
370
315
  # Offense count: 5
371
- # This cop supports safe autocorrection (--autocorrect).
372
- Style/IfUnlessModifier:
316
+ RSpec/MultipleDescribes:
373
317
  Exclude:
374
- - 'lib/metanorma/release/channel_manifest.rb'
375
- - 'lib/metanorma/release/cli.rb'
376
- - 'lib/metanorma/release/platform_factory.rb'
377
- - 'lib/metanorma/release/rake_tasks.rb'
378
- - 'lib/metanorma/release/relaton_enricher.rb'
318
+ - 'spec/aggregation/cache_store_spec.rb'
319
+ - 'spec/aggregation/delta_state_spec.rb'
320
+ - 'spec/aggregation/file_routing_spec.rb'
321
+ - 'spec/domain/publication_spec.rb'
322
+ - 'spec/domain/slug_strategy_spec.rb'
379
323
 
380
- # Offense count: 1
381
- # This cop supports safe autocorrection (--autocorrect).
382
- # Configuration parameters: EnforcedStyle.
383
- # SupportedStyles: line_count_dependent, lambda, literal
384
- Style/Lambda:
385
- Exclude:
386
- - 'lib/metanorma/release/platform_factory.rb'
324
+ # Offense count: 59
325
+ RSpec/MultipleExpectations:
326
+ Max: 9
387
327
 
388
328
  # Offense count: 1
389
- Style/MultilineBlockChain:
390
- Exclude:
391
- - 'spec/cli_spec.rb'
329
+ # Configuration parameters: AllowSubject.
330
+ RSpec/MultipleMemoizedHelpers:
331
+ Max: 7
392
332
 
393
- # Offense count: 2
333
+ # Offense count: 7
394
334
  # This cop supports safe autocorrection (--autocorrect).
395
- Style/MultilineIfModifier:
335
+ RSpec/ScatteredLet:
396
336
  Exclude:
397
- - 'lib/metanorma/release/document_index.rb'
337
+ - 'spec/platform/local/fetcher_spec.rb'
338
+ - 'spec/platform/local/publisher_spec.rb'
398
339
 
399
- # Offense count: 1
400
- # This cop supports unsafe autocorrection (--autocorrect-all).
401
- # Configuration parameters: EnforcedStyle, AllowedMethods, AllowedPatterns.
402
- # SupportedStyles: predicate, comparison
403
- Style/NumericPredicate:
404
- Exclude:
405
- - 'spec/**/*'
406
- - 'lib/metanorma/release/cli.rb'
340
+ # Offense count: 25
341
+ # Configuration parameters: CustomTransform, IgnoreMethods, IgnoreMetadata, InflectorPath, EnforcedInflector.
342
+ # SupportedInflectors: default, active_support
343
+ RSpec/SpecFilePathFormat:
344
+ Enabled: false
407
345
 
408
- # Offense count: 2
346
+ # Offense count: 23
409
347
  # This cop supports safe autocorrection (--autocorrect).
410
- Style/RedundantBegin:
348
+ # Configuration parameters: EnforcedStyle, ProceduralMethods, FunctionalMethods, AllowedMethods, AllowedPatterns, AllowBracesOnProceduralOneLiners, BracesRequiredMethods.
349
+ # SupportedStyles: line_count_based, semantic, braces_for_chaining, always_braces
350
+ # ProceduralMethods: benchmark, bm, bmbm, create, each_with_object, measure, new, realtime, tap, with_object
351
+ # FunctionalMethods: let, let!, subject, watch
352
+ # AllowedMethods: lambda, proc, it
353
+ Style/BlockDelimiters:
411
354
  Exclude:
412
- - 'lib/metanorma/release/aggregation_pipeline.rb'
413
- - 'lib/metanorma/release/rxl_extractor.rb'
355
+ - 'lib/metanorma/release/channel_filter.rb'
356
+ - 'lib/metanorma/release/cli.rb'
357
+ - 'lib/metanorma/release/content_hash.rb'
358
+ - 'lib/metanorma/release/index.rb'
359
+ - 'lib/metanorma/release/platform/github/publisher.rb'
360
+ - 'lib/metanorma/release/release_pipeline.rb'
361
+ - 'lib/metanorma/release/zip_packager.rb'
362
+ - 'spec/aggregation/delta_state_spec.rb'
363
+ - 'spec/aggregation/file_routing_spec.rb'
364
+ - 'spec/cli_spec.rb'
365
+ - 'spec/domain/config_spec.rb'
366
+ - 'spec/domain/repo_ref_spec.rb'
367
+ - 'spec/platform_factory_spec.rb'
414
368
 
415
369
  # Offense count: 1
416
370
  # This cop supports safe autocorrection (--autocorrect).
417
- Style/RedundantParentheses:
371
+ # Configuration parameters: EnforcedStyle, AllowedParentClasses.
372
+ # SupportedStyles: class_keyword, class_new, class_definition
373
+ Style/EmptyClassDefinition:
418
374
  Exclude:
419
- - 'lib/metanorma/release/cli.rb'
375
+ - 'lib/metanorma/release/index.rb'
420
376
 
421
- # Offense count: 16
377
+ # Offense count: 13
422
378
  # This cop supports safe autocorrection (--autocorrect).
423
- # Configuration parameters: EnforcedStyle, AllowInnerSlashes.
424
- # SupportedStyles: slashes, percent_r, mixed
425
- Style/RegexpLiteral:
379
+ Style/MultilineIfModifier:
426
380
  Exclude:
427
- - 'lib/metanorma/release/document_type.rb'
428
- - 'lib/metanorma/release/platform/local/config_fetcher.rb'
381
+ - 'lib/metanorma/release/cli.rb'
382
+ - 'lib/metanorma/release/config.rb'
383
+ - 'lib/metanorma/release/file_routing.rb'
384
+ - 'lib/metanorma/release/index.rb'
385
+ - 'lib/metanorma/release/platform/local/fetcher.rb'
386
+ - 'lib/metanorma/release/platform_factory.rb'
387
+ - 'lib/metanorma/release/publication.rb'
388
+ - 'lib/metanorma/release/repo_ref.rb'
429
389
 
430
390
  # Offense count: 1
431
391
  # This cop supports safe autocorrection (--autocorrect).
432
- Style/RescueModifier:
392
+ Style/MultilineTernaryOperator:
433
393
  Exclude:
434
- - 'lib/metanorma/release/platform/github/publisher.rb'
394
+ - 'lib/metanorma/release/content_hash.rb'
435
395
 
436
396
  # Offense count: 1
437
- # This cop supports safe autocorrection (--autocorrect).
438
- # Configuration parameters: EnforcedStyle.
439
- # SupportedStyles: implicit, explicit
440
- Style/RescueStandardError:
441
- Exclude:
442
- - 'lib/metanorma/release/platform/github/publisher.rb'
443
-
444
- # Offense count: 3
445
397
  # This cop supports unsafe autocorrection (--autocorrect-all).
446
- # Configuration parameters: ConvertCodeThatCanStartToReturnNil, AllowedMethods, MaxChainLength.
447
- # AllowedMethods: present?, blank?, presence, try, try!
448
- Style/SafeNavigation:
449
- Exclude:
450
- - 'lib/metanorma/release/channel_manifest.rb'
451
- - 'lib/metanorma/release/rake_tasks.rb'
452
-
453
- # Offense count: 12
454
- # This cop supports safe autocorrection (--autocorrect).
455
- # Configuration parameters: AllowAsExpressionSeparator.
456
- Style/Semicolon:
457
- Exclude:
458
- - 'lib/metanorma/release/relaton_enricher.rb'
459
-
460
- # Offense count: 3
461
- # This cop supports safe autocorrection (--autocorrect).
462
- Style/StderrPuts:
398
+ # Configuration parameters: AllowComments.
399
+ Style/RedundantInitialize:
463
400
  Exclude:
464
- - 'lib/metanorma/release/cli.rb'
401
+ - 'lib/metanorma/release/delta_state.rb'
465
402
 
466
- # Offense count: 2269
403
+ # Offense count: 1628
467
404
  # This cop supports safe autocorrection (--autocorrect).
468
405
  # Configuration parameters: EnforcedStyle, ConsistentQuotesInMultiline.
469
406
  # SupportedStyles: single_quotes, double_quotes
470
407
  Style/StringLiterals:
471
408
  Enabled: false
472
409
 
473
- # Offense count: 7
474
- # This cop supports safe autocorrection (--autocorrect).
475
- # Configuration parameters: ExactNameMatch, AllowPredicates, AllowDSLWriters, IgnoreClassMethods, AllowedMethods.
476
- # AllowedMethods: to_ary, to_a, to_c, to_enum, to_h, to_hash, to_i, to_int, to_io, to_open, to_path, to_proc, to_r, to_regexp, to_str, to_s, to_sym
477
- Style/TrivialAccessors:
478
- Exclude:
479
- - 'lib/metanorma/release/channel_manifest.rb'
480
- - 'lib/metanorma/release/channel_registry.rb'
481
- - 'lib/metanorma/release/document_index.rb'
482
- - 'lib/metanorma/release/relaton_enricher.rb'
483
-
484
- # Offense count: 2
410
+ # Offense count: 42
485
411
  # This cop supports safe autocorrection (--autocorrect).
486
- Style/UnpackFirst:
487
- Exclude:
488
- - 'lib/metanorma/release/platform/github/config_fetcher.rb'
489
- - 'lib/metanorma/release/platform/github/manifest_reader.rb'
412
+ # Configuration parameters: EnforcedStyleForMultiline.
413
+ # SupportedStylesForMultiline: comma, consistent_comma, diff_comma, no_comma
414
+ Style/TrailingCommaInArguments:
415
+ Enabled: false
490
416
 
491
417
  # Offense count: 1
492
418
  # This cop supports safe autocorrection (--autocorrect).
493
- # Configuration parameters: WordRegex.
494
- # SupportedStyles: percent, brackets
495
- Style/WordArray:
496
- EnforcedStyle: percent
497
- MinSize: 3
419
+ # Configuration parameters: EnforcedStyleForMultiline.
420
+ # SupportedStylesForMultiline: comma, consistent_comma, diff_comma, no_comma
421
+ Style/TrailingCommaInArrayLiteral:
422
+ Exclude:
423
+ - 'spec/platform/github/release_fetcher_spec.rb'
498
424
 
499
- # Offense count: 17
425
+ # Offense count: 11
500
426
  # This cop supports safe autocorrection (--autocorrect).
501
- # Configuration parameters: AllowHeredoc, AllowURI, AllowQualifiedName, URISchemes, AllowRBSInlineAnnotation, AllowCopDirectives, AllowedPatterns, SplitStrings.
502
- # URISchemes: http, https
503
- Layout/LineLength:
504
- Max: 153
427
+ # Configuration parameters: EnforcedStyleForMultiline.
428
+ # SupportedStylesForMultiline: comma, consistent_comma, diff_comma, no_comma
429
+ Style/TrailingCommaInHashLiteral:
430
+ Exclude:
431
+ - 'lib/metanorma/release/commands/aggregate.rb'
432
+ - 'lib/metanorma/release/delta_state.rb'
433
+ - 'lib/metanorma/release/file_routing.rb'
434
+ - 'lib/metanorma/release/index.rb'
435
+ - 'lib/metanorma/release/platform_factory.rb'