nanoc-core 4.11.12 → 4.11.17

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 (78) hide show
  1. checksums.yaml +4 -4
  2. data/lib/nanoc/core.rb +37 -0
  3. data/lib/nanoc/core/basic_item_rep_collection_view.rb +88 -0
  4. data/lib/nanoc/core/basic_item_rep_view.rb +83 -0
  5. data/lib/nanoc/core/basic_item_view.rb +54 -0
  6. data/lib/nanoc/core/changes_stream.rb +55 -0
  7. data/lib/nanoc/core/checksum_store.rb +1 -1
  8. data/lib/nanoc/core/checksummer.rb +4 -2
  9. data/lib/nanoc/core/compilation_item_rep_collection_view.rb +12 -0
  10. data/lib/nanoc/core/compilation_item_rep_view.rb +57 -0
  11. data/lib/nanoc/core/compilation_item_view.rb +47 -0
  12. data/lib/nanoc/core/compilation_phases/abstract.rb +48 -0
  13. data/lib/nanoc/core/compilation_phases/cache.rb +43 -0
  14. data/lib/nanoc/core/compilation_phases/mark_done.rb +23 -0
  15. data/lib/nanoc/core/compilation_phases/notify.rb +19 -0
  16. data/lib/nanoc/core/compilation_phases/recalculate.rb +49 -0
  17. data/lib/nanoc/core/compilation_phases/resume.rb +52 -0
  18. data/lib/nanoc/core/compilation_phases/write.rb +84 -0
  19. data/lib/nanoc/core/compilation_stages/build_reps.rb +36 -0
  20. data/lib/nanoc/core/compilation_stages/calculate_checksums.rb +42 -0
  21. data/lib/nanoc/core/compilation_stages/cleanup.rb +43 -0
  22. data/lib/nanoc/core/compilation_stages/compile_reps.rb +96 -0
  23. data/lib/nanoc/core/compilation_stages/determine_outdatedness.rb +49 -0
  24. data/lib/nanoc/core/compilation_stages/forget_outdated_dependencies.rb +20 -0
  25. data/lib/nanoc/core/compilation_stages/load_stores.rb +35 -0
  26. data/lib/nanoc/core/compilation_stages/postprocess.rb +21 -0
  27. data/lib/nanoc/core/compilation_stages/preprocess.rb +32 -0
  28. data/lib/nanoc/core/compilation_stages/prune.rb +30 -0
  29. data/lib/nanoc/core/compilation_stages/store_post_compilation_state.rb +20 -0
  30. data/lib/nanoc/core/compilation_stages/store_pre_compilation_state.rb +32 -0
  31. data/lib/nanoc/core/compiled_content_cache.rb +2 -2
  32. data/lib/nanoc/core/compiler.rb +214 -0
  33. data/lib/nanoc/core/compiler_loader.rb +48 -0
  34. data/lib/nanoc/core/config_loader.rb +95 -0
  35. data/lib/nanoc/core/config_view.rb +67 -0
  36. data/lib/nanoc/core/configuration.rb +2 -4
  37. data/lib/nanoc/core/contracts_support.rb +20 -0
  38. data/lib/nanoc/core/dependency_store.rb +3 -3
  39. data/lib/nanoc/core/document_view_mixin.rb +87 -0
  40. data/lib/nanoc/core/errors.rb +108 -0
  41. data/lib/nanoc/core/executor.rb +134 -0
  42. data/lib/nanoc/core/feature.rb +92 -0
  43. data/lib/nanoc/core/filter.rb +269 -0
  44. data/lib/nanoc/core/identifiable_collection_view.rb +111 -0
  45. data/lib/nanoc/core/item_collection_with_reps_view.rb +12 -0
  46. data/lib/nanoc/core/item_collection_without_reps_view.rb +12 -0
  47. data/lib/nanoc/core/item_rep_builder.rb +54 -0
  48. data/lib/nanoc/core/item_rep_selector.rb +67 -0
  49. data/lib/nanoc/core/item_rep_writer.rb +85 -0
  50. data/lib/nanoc/core/layout_collection_view.rb +12 -0
  51. data/lib/nanoc/core/layout_view.rb +9 -0
  52. data/lib/nanoc/core/mutable_config_view.rb +16 -0
  53. data/lib/nanoc/core/mutable_document_view_mixin.rb +60 -0
  54. data/lib/nanoc/core/mutable_identifiable_collection_view.rb +19 -0
  55. data/lib/nanoc/core/mutable_item_collection_view.rb +34 -0
  56. data/lib/nanoc/core/mutable_item_view.rb +9 -0
  57. data/lib/nanoc/core/mutable_layout_collection_view.rb +26 -0
  58. data/lib/nanoc/core/mutable_layout_view.rb +9 -0
  59. data/lib/nanoc/core/outdatedness_checker.rb +222 -0
  60. data/lib/nanoc/core/outdatedness_rules/attributes_modified.rb +41 -0
  61. data/lib/nanoc/core/outdatedness_rules/code_snippets_modified.rb +31 -0
  62. data/lib/nanoc/core/outdatedness_rules/content_modified.rb +21 -0
  63. data/lib/nanoc/core/outdatedness_rules/item_collection_extended.rb +20 -0
  64. data/lib/nanoc/core/outdatedness_rules/layout_collection_extended.rb +20 -0
  65. data/lib/nanoc/core/outdatedness_rules/not_written.rb +17 -0
  66. data/lib/nanoc/core/outdatedness_rules/rules_modified.rb +45 -0
  67. data/lib/nanoc/core/outdatedness_rules/uses_always_outdated_filter.rb +26 -0
  68. data/lib/nanoc/core/post_compile_item_collection_view.rb +12 -0
  69. data/lib/nanoc/core/post_compile_item_rep_collection_view.rb +12 -0
  70. data/lib/nanoc/core/post_compile_item_rep_view.rb +33 -0
  71. data/lib/nanoc/core/post_compile_item_view.rb +20 -0
  72. data/lib/nanoc/core/pruner.rb +123 -0
  73. data/lib/nanoc/core/site_loader.rb +102 -0
  74. data/lib/nanoc/core/trivial_error.rb +10 -0
  75. data/lib/nanoc/core/version.rb +1 -1
  76. data/lib/nanoc/core/view.rb +43 -0
  77. data/lib/nanoc/core/view_context_for_compilation.rb +6 -6
  78. metadata +97 -3
@@ -37,12 +37,12 @@ module Nanoc
37
37
  end
38
38
 
39
39
  content_or_filename_assigns.merge(
40
- item: Nanoc::CompilationItemView.new(rep.item, self),
41
- rep: Nanoc::CompilationItemRepView.new(rep, self),
42
- item_rep: Nanoc::CompilationItemRepView.new(rep, self),
43
- items: Nanoc::ItemCollectionWithRepsView.new(site.items, self),
44
- layouts: Nanoc::LayoutCollectionView.new(site.layouts, self),
45
- config: Nanoc::ConfigView.new(site.config, self),
40
+ item: Nanoc::Core::CompilationItemView.new(rep.item, self),
41
+ rep: Nanoc::Core::CompilationItemRepView.new(rep, self),
42
+ item_rep: Nanoc::Core::CompilationItemRepView.new(rep, self),
43
+ items: Nanoc::Core::ItemCollectionWithRepsView.new(site.items, self),
44
+ layouts: Nanoc::Core::LayoutCollectionView.new(site.layouts, self),
45
+ config: Nanoc::Core::ConfigView.new(site.config, self),
46
46
  )
47
47
  end
48
48
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: nanoc-core
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.11.12
4
+ version: 4.11.17
5
5
  platform: ruby
6
6
  authors:
7
7
  - Denis Defreyne
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-09-21 00:00:00.000000000 Z
11
+ date: 2020-06-12 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: ddmemoize
@@ -94,6 +94,34 @@ dependencies:
94
94
  - - "~>"
95
95
  - !ruby/object:Gem::Version
96
96
  version: '1.0'
97
+ - !ruby/object:Gem::Dependency
98
+ name: tomlrb
99
+ requirement: !ruby/object:Gem::Requirement
100
+ requirements:
101
+ - - "~>"
102
+ - !ruby/object:Gem::Version
103
+ version: '1.2'
104
+ type: :runtime
105
+ prerelease: false
106
+ version_requirements: !ruby/object:Gem::Requirement
107
+ requirements:
108
+ - - "~>"
109
+ - !ruby/object:Gem::Version
110
+ version: '1.2'
111
+ - !ruby/object:Gem::Dependency
112
+ name: tty-platform
113
+ requirement: !ruby/object:Gem::Requirement
114
+ requirements:
115
+ - - "~>"
116
+ - !ruby/object:Gem::Version
117
+ version: '0.2'
118
+ type: :runtime
119
+ prerelease: false
120
+ version_requirements: !ruby/object:Gem::Requirement
121
+ requirements:
122
+ - - "~>"
123
+ - !ruby/object:Gem::Version
124
+ version: '0.2'
97
125
  - !ruby/object:Gem::Dependency
98
126
  name: zeitwerk
99
127
  requirement: !ruby/object:Gem::Requirement
@@ -124,16 +152,46 @@ files:
124
152
  - lib/nanoc/core/action_sequence_store.rb
125
153
  - lib/nanoc/core/aggregate_data_source.rb
126
154
  - lib/nanoc/core/assertions.rb
155
+ - lib/nanoc/core/basic_item_rep_collection_view.rb
156
+ - lib/nanoc/core/basic_item_rep_view.rb
157
+ - lib/nanoc/core/basic_item_view.rb
127
158
  - lib/nanoc/core/binary_compiled_content_cache.rb
128
159
  - lib/nanoc/core/binary_content.rb
160
+ - lib/nanoc/core/changes_stream.rb
129
161
  - lib/nanoc/core/checksum_collection.rb
130
162
  - lib/nanoc/core/checksum_store.rb
131
163
  - lib/nanoc/core/checksummer.rb
132
164
  - lib/nanoc/core/code_snippet.rb
133
165
  - lib/nanoc/core/compilation_context.rb
166
+ - lib/nanoc/core/compilation_item_rep_collection_view.rb
167
+ - lib/nanoc/core/compilation_item_rep_view.rb
168
+ - lib/nanoc/core/compilation_item_view.rb
169
+ - lib/nanoc/core/compilation_phases/abstract.rb
170
+ - lib/nanoc/core/compilation_phases/cache.rb
171
+ - lib/nanoc/core/compilation_phases/mark_done.rb
172
+ - lib/nanoc/core/compilation_phases/notify.rb
173
+ - lib/nanoc/core/compilation_phases/recalculate.rb
174
+ - lib/nanoc/core/compilation_phases/resume.rb
175
+ - lib/nanoc/core/compilation_phases/write.rb
134
176
  - lib/nanoc/core/compilation_stage.rb
177
+ - lib/nanoc/core/compilation_stages/build_reps.rb
178
+ - lib/nanoc/core/compilation_stages/calculate_checksums.rb
179
+ - lib/nanoc/core/compilation_stages/cleanup.rb
180
+ - lib/nanoc/core/compilation_stages/compile_reps.rb
181
+ - lib/nanoc/core/compilation_stages/determine_outdatedness.rb
182
+ - lib/nanoc/core/compilation_stages/forget_outdated_dependencies.rb
183
+ - lib/nanoc/core/compilation_stages/load_stores.rb
184
+ - lib/nanoc/core/compilation_stages/postprocess.rb
185
+ - lib/nanoc/core/compilation_stages/preprocess.rb
186
+ - lib/nanoc/core/compilation_stages/prune.rb
187
+ - lib/nanoc/core/compilation_stages/store_post_compilation_state.rb
188
+ - lib/nanoc/core/compilation_stages/store_pre_compilation_state.rb
135
189
  - lib/nanoc/core/compiled_content_cache.rb
136
190
  - lib/nanoc/core/compiled_content_store.rb
191
+ - lib/nanoc/core/compiler.rb
192
+ - lib/nanoc/core/compiler_loader.rb
193
+ - lib/nanoc/core/config_loader.rb
194
+ - lib/nanoc/core/config_view.rb
137
195
  - lib/nanoc/core/configuration-schema.json
138
196
  - lib/nanoc/core/configuration.rb
139
197
  - lib/nanoc/core/content.rb
@@ -149,41 +207,77 @@ files:
149
207
  - lib/nanoc/core/dependency_tracker.rb
150
208
  - lib/nanoc/core/directed_graph.rb
151
209
  - lib/nanoc/core/document.rb
210
+ - lib/nanoc/core/document_view_mixin.rb
152
211
  - lib/nanoc/core/error.rb
153
212
  - lib/nanoc/core/errors.rb
213
+ - lib/nanoc/core/executor.rb
214
+ - lib/nanoc/core/feature.rb
215
+ - lib/nanoc/core/filter.rb
154
216
  - lib/nanoc/core/identifiable_collection.rb
217
+ - lib/nanoc/core/identifiable_collection_view.rb
155
218
  - lib/nanoc/core/identifier.rb
156
219
  - lib/nanoc/core/in_memory_data_source.rb
157
220
  - lib/nanoc/core/instrumentor.rb
158
221
  - lib/nanoc/core/item.rb
159
222
  - lib/nanoc/core/item_collection.rb
223
+ - lib/nanoc/core/item_collection_with_reps_view.rb
224
+ - lib/nanoc/core/item_collection_without_reps_view.rb
160
225
  - lib/nanoc/core/item_rep.rb
226
+ - lib/nanoc/core/item_rep_builder.rb
161
227
  - lib/nanoc/core/item_rep_repo.rb
162
228
  - lib/nanoc/core/item_rep_router.rb
229
+ - lib/nanoc/core/item_rep_selector.rb
230
+ - lib/nanoc/core/item_rep_writer.rb
163
231
  - lib/nanoc/core/layout.rb
164
232
  - lib/nanoc/core/layout_collection.rb
233
+ - lib/nanoc/core/layout_collection_view.rb
234
+ - lib/nanoc/core/layout_view.rb
165
235
  - lib/nanoc/core/lazy_value.rb
236
+ - lib/nanoc/core/mutable_config_view.rb
237
+ - lib/nanoc/core/mutable_document_view_mixin.rb
238
+ - lib/nanoc/core/mutable_identifiable_collection_view.rb
239
+ - lib/nanoc/core/mutable_item_collection_view.rb
240
+ - lib/nanoc/core/mutable_item_view.rb
241
+ - lib/nanoc/core/mutable_layout_collection_view.rb
242
+ - lib/nanoc/core/mutable_layout_view.rb
166
243
  - lib/nanoc/core/notification_center.rb
244
+ - lib/nanoc/core/outdatedness_checker.rb
167
245
  - lib/nanoc/core/outdatedness_reasons.rb
168
246
  - lib/nanoc/core/outdatedness_rule.rb
247
+ - lib/nanoc/core/outdatedness_rules/attributes_modified.rb
248
+ - lib/nanoc/core/outdatedness_rules/code_snippets_modified.rb
249
+ - lib/nanoc/core/outdatedness_rules/content_modified.rb
250
+ - lib/nanoc/core/outdatedness_rules/item_collection_extended.rb
251
+ - lib/nanoc/core/outdatedness_rules/layout_collection_extended.rb
252
+ - lib/nanoc/core/outdatedness_rules/not_written.rb
253
+ - lib/nanoc/core/outdatedness_rules/rules_modified.rb
254
+ - lib/nanoc/core/outdatedness_rules/uses_always_outdated_filter.rb
169
255
  - lib/nanoc/core/outdatedness_status.rb
170
256
  - lib/nanoc/core/outdatedness_store.rb
171
257
  - lib/nanoc/core/pattern.rb
258
+ - lib/nanoc/core/post_compile_item_collection_view.rb
259
+ - lib/nanoc/core/post_compile_item_rep_collection_view.rb
260
+ - lib/nanoc/core/post_compile_item_rep_view.rb
261
+ - lib/nanoc/core/post_compile_item_view.rb
172
262
  - lib/nanoc/core/prefixed_data_source.rb
173
263
  - lib/nanoc/core/processing_action.rb
174
264
  - lib/nanoc/core/processing_actions.rb
175
265
  - lib/nanoc/core/processing_actions/filter.rb
176
266
  - lib/nanoc/core/processing_actions/layout.rb
177
267
  - lib/nanoc/core/processing_actions/snapshot.rb
268
+ - lib/nanoc/core/pruner.rb
178
269
  - lib/nanoc/core/regexp_pattern.rb
179
270
  - lib/nanoc/core/site.rb
271
+ - lib/nanoc/core/site_loader.rb
180
272
  - lib/nanoc/core/snapshot_def.rb
181
273
  - lib/nanoc/core/store.rb
182
274
  - lib/nanoc/core/string_pattern.rb
183
275
  - lib/nanoc/core/temp_filename_factory.rb
184
276
  - lib/nanoc/core/textual_compiled_content_cache.rb
185
277
  - lib/nanoc/core/textual_content.rb
278
+ - lib/nanoc/core/trivial_error.rb
186
279
  - lib/nanoc/core/version.rb
280
+ - lib/nanoc/core/view.rb
187
281
  - lib/nanoc/core/view_context_for_compilation.rb
188
282
  - lib/nanoc/core/view_context_for_pre_compilation.rb
189
283
  - lib/nanoc/core/view_context_for_shell.rb
@@ -206,7 +300,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
206
300
  - !ruby/object:Gem::Version
207
301
  version: '0'
208
302
  requirements: []
209
- rubygems_version: 3.0.6
303
+ rubygems_version: 3.1.4
210
304
  signing_key:
211
305
  specification_version: 4
212
306
  summary: Core of Nanoc