hanami-utils 2.0.0.alpha6 → 2.0.0.rc1

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: b31e4f747bffab786626dab7e503b8c1109e79bfbe1b4a7bed5e0bdda029e0cb
4
- data.tar.gz: fef75e02594d51e4b681ba5101ea0c310af329806d1b18da2f1260abad934fd6
3
+ metadata.gz: e32b8748a32b673f476ffc41c81608f5e6d372f610e990594488c214e27fdfd1
4
+ data.tar.gz: 0e043561435c85f622bd8a1b1f341a5ad77b1359578fd00923c0ee19c6150b63
5
5
  SHA512:
6
- metadata.gz: c62234ebc6ba706c83601b939d30eeb840eb34f11b9ff4bb9bc765acbe6c8182973a63ea088add5ad8ff26510b51f1293fcb2b54442d1b11ebbe7ff9dbc586ad
7
- data.tar.gz: b52814d32d41e12b5f4bfd59f1b7bb0185871434eb92df3fbbd5e8d43249edfaf6acc1b4f001a64266d37e47e4ef09882ec23eb1a9a2a4be86d9636a00fb892c
6
+ metadata.gz: dbedf69794dbd7ee0ae949ef77a2891fe29c5439feb7cb3c6e2e91b87b3fae16f74e6f624357e646cb68c47668120d5be0cc8e8961c198c75106f0636cb4373e
7
+ data.tar.gz: 615330821eadb25847032710fff58adab597281783b09767e92da9ecf3523cb511dff516ed5f6640d06b5d8d5cfaaa8c93ffcb45f1be5db520ec7ccdb058a84d
data/CHANGELOG.md CHANGED
@@ -1,30 +1,58 @@
1
1
  # Hanami::Utils
2
- Ruby core extentions and class utilities for Hanami
2
+
3
+ Ruby core extensions and class utilities for Hanami
4
+
5
+ ## v2.0.0.rc1 - 2022-11-08
6
+
7
+ ### Fixed
8
+
9
+ - [Benjamin Klotz] Ensure `Hanami::Utils::String.underscore` to replace `"."` (dot character) into underscore
10
+
11
+ ### Changed
12
+
13
+ - [Luca Guidi] Removed `Hanami::Logger` in favor of `Dry::Logger`
14
+
15
+ ## v2.0.0.beta1 - 2022-07-20
16
+
17
+ ### Changed
18
+
19
+ - [Luca Guidi] Removed `Hanami::Utils::BasicObject` (moved to `dry-core` as `Dry::Core::BasicObject`)
20
+ - [Luca Guidi] Removed `Hanami::Interactor`
3
21
 
4
22
  ## v2.0.0.alpha6 - 2022-02-10
23
+
5
24
  ### Added
25
+
6
26
  - [Luca Guidi] Official support for Ruby: MRI 3.0 and 3.1
7
27
 
8
28
  ### Fixed
29
+
9
30
  - [Rob Jacoby] Allow `Hanami::Logger#initialize` to accept `File::NULL` as `stream:` argument
10
31
 
11
32
  ### Changed
33
+
12
34
  - [Luca Guidi] Drop support for Ruby: MRI 2.6 and 2.7.
13
35
 
14
36
  ## v2.0.0.alpha3 - 2021-11-09
37
+
15
38
  No changes.
16
39
 
17
40
  ## v2.0.0.alpha2 - 2021-05-04
41
+
18
42
  ### Changed
43
+
19
44
  - [Luca Guidi] Drop support for Ruby: MRI 2.5.
20
45
  - [Luca Guidi] Transform `Utils::String` from class to module
21
46
 
22
47
  ## v2.0.0.alpha1 - 2019-01-30
48
+
23
49
  ### Added
50
+
24
51
  - [Gustavo Caso] Introduce `Hanami::Middleware` namespace
25
52
  - [Luca Guidi] Introduce `Callbacks::Chain#dup`
26
53
 
27
54
  ### Changed
55
+
28
56
  - [Luca Guidi] Drop support for Ruby: MRI 2.3, and 2.4.
29
57
  - [Luca Guidi] Remove `Utils::Duplicable`
30
58
  - [Luca Guidi] Remove `Utils::Inflector`
@@ -37,62 +65,85 @@ No changes.
37
65
  - [Vladimir Suvorov] Remove `Utils::Class.load_from_pattern!`
38
66
 
39
67
  ## v1.3.8 - 2021-05-03
68
+
40
69
  ### Fixed
70
+
41
71
  - [Hiếu Nguyễn] Ensure `Hanami::Interactor#initialize` to accept keyword arguments while working with Ruby 3
42
72
 
43
73
  ## v1.3.7 - 2021-01-04
74
+
44
75
  ### Added
76
+
45
77
  - [Luca Guidi] Official support for Ruby: MRI 3.0
46
78
  - [Khai Le] Allow `Hanami::Logger` to filter sensitive data for an array of hashes
47
79
 
48
80
  ### Fixed
81
+
49
82
  - [Hiếu Nguyễn] Ensure `Hanami::Logger` to not mutate `Hash` input when filtering sensitive data
50
83
 
51
84
  ## v1.3.6 - 2020-01-07
85
+
52
86
  ### Added
87
+
53
88
  - [Luca Guidi] Official support for Ruby: MRI 2.7
54
89
 
55
90
  ### Fixed
91
+
56
92
  - [ippachi] `Utils::Files.append`: don't check breakline if file is empty
57
93
 
58
94
  ## v1.3.5 - 2019-10-25
95
+
59
96
  ### Fixed
97
+
60
98
  - [Ivan Kabluchkov] Ensure `Hanami::Logger` filters to not crash when logger stream is a closed tempfile
61
99
  - [Luca Guidi] Ensure `Utils::Files.append` to append contents properly when existing file doesn't end with a newline
62
100
 
63
101
  ## v1.3.4 - 2019-09-27
102
+
64
103
  ### Added
104
+
65
105
  - [Luca Guidi] Let `Utils::BasicObject` to lookup constants at the top-level namespace
66
106
 
67
107
  ## v1.3.3 - 2019-09-13
108
+
68
109
  ### Fixed
110
+
69
111
  - [Mauro Morales] Ensure `Utils::Inflector.pluralize` and `.singularize` to work with words that contain an underscore (`_`)
70
112
 
71
113
  ## v1.3.2 - 2019-06-21
114
+
72
115
  ### Added
116
+
73
117
  - [Vladislav Yashin & Luca Guidi] Added `Utils::BasicObject#instance_of?`, `#is_a?`, and `#kind_of`
74
118
 
75
119
  ## v1.3.1 - 2019-01-18
120
+
76
121
  ### Added
122
+
77
123
  - [Luca Guidi] Official support for Ruby: MRI 2.6
78
124
  - [Luca Guidi] Support `bundler` 2.0+
79
125
 
80
126
  ### Fixed
127
+
81
128
  - [Alfonso Uceda] Fix `Hash` serialization for `Utils::Logger`
82
129
  - [Jeff Dickey] Add missing `pathname` require in `lib/hanami/utils.rb`
83
130
 
84
131
  ## v1.3.0 - 2018-10-24
85
132
 
86
133
  ## v1.3.0.beta1 - 2018-08-08
134
+
87
135
  ### Added
136
+
88
137
  - [Luca Guidi] Official support for JRuby 9.2.0.0
89
138
  - [graywolf] Add `Utils::Files.inject_line_before_last` and `.inject_line_after_last`
90
139
 
91
140
  ### Fixed
141
+
92
142
  - [graywolf] Don't show `Fixnum` Ruby warning for 2.4+
93
143
  - [Luca Guidi] Fix pluralization of `"fee"`
94
144
 
95
145
  ### Deprecated
146
+
96
147
  - [Luca Guidi & Marion Schleifer] Deprecate `Utils::String` as Ruby type. Please use `Utils::String` class methods instead of `Utils::String.new("")`.
97
148
  - [Luca Guidi & Marion Schleifer] Deprecate `Utils::Hash` as Ruby type. Please use `Utils::Hash` class methods instead of `Utils::Hash.new({})`.
98
149
  - [Luca Guidi & Marion Schleifer] Deprecate `Utils::String.pluralize` and `.singularize`.
@@ -101,14 +152,19 @@ No changes.
101
152
  ## v1.2.0 - 2018-04-11
102
153
 
103
154
  ## v1.2.0.rc2 - 2018-04-06
155
+
104
156
  ### Added
157
+
105
158
  - [Luca Guidi] Use different colors for each `Hanami::Logger` level
106
159
 
107
160
  ## v1.2.0.rc1 - 2018-03-30
161
+
108
162
  ### Added
163
+
109
164
  - [Oana Sipos & Sean Collins & Luca Guidi] Colored logging
110
165
 
111
166
  ### Fixed
167
+
112
168
  - [Luca Guidi] Make `Hanami::Logger` to properly log hash messages
113
169
 
114
170
  ## v1.2.0.beta2 - 2018-03-23
@@ -116,25 +172,34 @@ No changes.
116
172
  ## v1.2.0.beta1 - 2018-02-28
117
173
 
118
174
  ## v1.1.2 - 2018-02-02
175
+
119
176
  ### Added
177
+
120
178
  - [Luca Guidi] Official support for Ruby: MRI 2.5
121
179
 
122
180
  ### Fixed
181
+
123
182
  - [Sean Collins & Luca Guidi] Make `Utils::Files.write` idempotent: ensure to truncate the file before to write
124
183
  - [Sean Collins & Luca Guidi] Don't erase file contents when invoking `Utils::Files.touch`
125
184
 
126
185
  ### Changed
186
+
127
187
  - [Sean Collins & Luca Guidi] Deprecate `Utils::Files.rewrite` in favor of `.write`
128
188
 
129
189
  ## v1.1.1 - 2017-11-22
190
+
130
191
  ### Added
192
+
131
193
  - [Luca Guidi] Introduce `Utils::Hash.deep_stringify` to recursively stringify a hash
132
194
 
133
195
  ### Fixed
196
+
134
197
  - [Yuta Tokitake] Ensure `Interactor#call` to accept non-keyword arguments
135
198
 
136
199
  ## v1.1.0 - 2017-10-25
200
+
137
201
  ### Added
202
+
138
203
  - [Luca Guidi] Introduce `Utils::Hash.deep_serialize` to recursively serialize input into `::Hash`
139
204
 
140
205
  ## v1.1.0.rc1 - 2017-10-16
@@ -142,11 +207,15 @@ No changes.
142
207
  ## v1.1.0.beta3 - 2017-10-04
143
208
 
144
209
  ## v1.1.0.beta2 - 2017-10-03
210
+
145
211
  ### Added
212
+
146
213
  - [Alfonso Uceda] Auto create directory for `Hanami::Logger`
147
214
 
148
215
  ## v1.1.0.beta1 - 2017-08-11
216
+
149
217
  ### Added
218
+
150
219
  - [Marion Duprey] Allow `Hanami::Interactor#call` to accept arguments. `#initialize` should be used for Dependency Injection, while `#call` should be used for input
151
220
  - [Marion Schleifer] Introduce `Utils::Hash.stringify`
152
221
  - [Marion Schleifer] Introduce `Utils::String.titleize`, `.capitalize`, `.classify`, `.underscore`, `.dasherize`, `.demodulize`, `.namespace`, `.pluralize`, `.singularize`, and `.rsub`
@@ -155,101 +224,136 @@ No changes.
155
224
  - [Marion Duprey & Gabriel Gizotti] Filter sensitive informations for `Hanami::Logger`
156
225
 
157
226
  ## v1.0.4 - 2017-10-02
227
+
158
228
  ### Fixed
229
+
159
230
  - [Luca Guidi] Make `Hanami::Utils::BasicObject` to be fully compatible with Ruby's `pp` and to be inspected by Pry.
160
231
  - [Thiago Kenji Okada] Fix pluralization/singularization for `"release" => "releases"`
161
232
 
162
233
  ## v1.0.3 - 2017-09-06
234
+
163
235
  ### Fixed
236
+
164
237
  - [Malina Sulca] Fix pluralization/singularization for `"exercise" => "exercises"`
165
238
  - [Xavier Barbosa] Fix pluralization/singularization for `"area" => "areas"`
166
239
 
167
240
  ## v1.0.2 - 2017-07-10
241
+
168
242
  ### Fixed
243
+
169
244
  - [Anton Davydov] Fix pluralization/singularization for `"phrase" => "phrases"`
170
245
 
171
246
  ## v1.0.1 - 2017-06-23
247
+
172
248
  ### Added
249
+
173
250
  - [Luca Guidi] Introduced `Utils::Hash.symbolize` and `.deep_symbolize`
174
251
  - [Luca Guidi] Introduced `Utils::Hash.deep_dup`
175
252
 
176
253
  ### Fixed
254
+
177
255
  - [choallin] Ensure `Utils::String#classify` to return output identical to the input for already classified strings.
178
256
  - [Marion Duprey & Jonas Amundsen] Ensure `Utils::Hash#initialize` to accept frozen `Hash` as argument.
179
257
 
180
258
  ## v1.0.0 - 2017-04-06
181
259
 
182
260
  ## v1.0.0.rc1 - 2017-03-31
261
+
183
262
  ### Added
263
+
184
264
  - [Luca Guidi] Allow `Hanami::Logger#initialize` to accept arguments to be compliant with Ruby's `Logger`
185
265
 
186
266
  ## v1.0.0.beta3 - 2017-03-17
267
+
187
268
  ### Fixed
269
+
188
270
  - [Luca Guidi] Use `$stdout` instead of `STDOUT` as default stream for `Hanami::Logger`
189
271
 
190
272
  ### Changed
273
+
191
274
  - [Luca Guidi] Removed `Utils::Attributes`
192
275
  - [Luca Guidi] Removed deprecated `Hanami::Interactor::Result#failing?`
193
276
  - [Luca Guidi] Removed deprecated `Utils::Json.load` and `.dump`
194
277
 
195
278
  ## v1.0.0.beta2 - 2017-03-02
279
+
196
280
  ### Changed
281
+
197
282
  - [Anton Davydov] Made `Utils::Blank` private API
198
283
 
199
284
  ## v1.0.0.beta1 - 2017-02-14
285
+
200
286
  ### Added
287
+
201
288
  - [Luca Guidi] Official support for Ruby: MRI 2.4
202
289
  - [alexd16] Introduced `Utils::Hash#deep_symbolize!` for deep symbolization
203
290
  - [Luca Guidi] Introduced `Hanami::Utils.reload!` as a mechanism to force code reloading in development
204
291
 
205
292
  ### Fixed
293
+
206
294
  - [alexd16 & Alfonso Uceda & Luca Guidi] Don't deeply symbolize `Hanami::Interactor::Result` payload
207
295
  - [Alfonso Uceda] `Hanami::Interactor::Result`: Don't transform objects that respond to `#to_hash` (like entities)
208
296
  - [Bhanu Prakash] Use `Utils::Json.generate` instead of the deprecated `.dump` for `Hanami::Logger` JSON formatter
209
297
  - [Luca Guidi] `Hanami::Logger`: when a `Hash` message is passed, don't nest it under `:message` key, but unwrap at the top level
210
298
 
211
299
  ### Changed
300
+
212
301
  - [alexd16] `Utils::Hash#symbolize!` no longer symbolizes deep structures
213
302
  - [Luca Guidi & Alfonso Uceda] Improve readability for default logger formatter
214
303
  - [Luca Guidi] Use ISO-8601 time format for JSON logger formatter
215
304
 
216
305
  ## v0.9.2 - 2016-12-19
306
+
217
307
  ### Added
308
+
218
309
  - [Grachev Mikhail] Introduced `Hanami::Interactor::Result#failure?`
219
310
 
220
311
  ### Fixed
312
+
221
313
  - [Paweł Świątkowski] `Utils::Inflector.pluralize` Pluralize -en to -ens instead of -ina
222
314
 
223
315
  ### Changed
316
+
224
317
  - [Grachev Mikhail] Deprecate `Hanami::Interactor::Result#failing?` in favor of `#failure?`
225
318
 
226
319
  ## v0.9.1 - 2016-11-18
320
+
227
321
  ### Added
322
+
228
323
  - [Luca Guidi] Introduced `Utils::Json.parse` and `.generate`
229
324
 
230
325
  ### Fixed
326
+
231
327
  - [Luca Guidi] Ensure `Utils::Json` parsing to not eval untrusted input
232
328
 
233
329
  ### Changed
330
+
234
331
  - [Luca Guidi] Deprecated `Utils::Json.load` in favor of `.parse`
235
332
  - [Luca Guidi] Deprecated `Utils::Json.dump` in favor of `.generate`
236
333
 
237
334
  ## v0.9.0 - 2016-11-15
335
+
238
336
  ### Added
337
+
239
338
  – [Luca Guidi] Introduced `Utils.require!` to recursively require Ruby files with an order that is consistent across platforms
240
339
  – [Luca Guidi] Introduced `Utils::FileList` as cross-platform ordered list of files, alternative to `Dir.glob`
340
+
241
341
  - [Luca Guidi] Make `Utils::BasicObject` pretty printable
242
342
  - [Grachev Mikhail] Added `Interactor::Result#successful?` and `#failing?`
243
343
 
244
344
  ### Fixed
345
+
245
346
  - [Pascal Betz] Ensure `Utils::Class.load!` to lookup constant only within the given namespace
246
347
 
247
348
  ### Changed
349
+
248
350
  - [Luca Guidi] Make `Utils::Hash` only compatible with objects that respond to `#to_hash`
249
351
  - [Luca Guidi] Official support for Ruby: MRI 2.3+ and JRuby 9.1.5.0+
250
352
 
251
353
  ## v0.8.0 - 2016-07-22
354
+
252
355
  ### Added
356
+
253
357
  - [Andrey Morskov] Introduced `Hanami::Utils::Blank`
254
358
  - [Anton Davydov] Allow to specify a default log level for `Hanami::Logger`
255
359
  - [Anton Davydov] Introduced default and JSON formatters for `Hanami::Logger`
@@ -263,101 +367,139 @@ No changes.
263
367
  - [Rogério Ramos] Fix English pluralization for words ending with `"ice"`
264
368
 
265
369
  ### Changed
370
+
266
371
  - [Luca Guidi] Drop support for Ruby 2.0, 2.1 and Rubinius. Official support for JRuby 9.0.5.0+.
267
372
 
268
373
  ## v0.7.1 - 2016-02-05
374
+
269
375
  ### Fixed
376
+
270
377
  - [Yuuji Yaginuma] `Hanami::Utils::Escape`: fixed Ruby warning for `String#chars` with a block, which is deprecated. Using `String#each_char` now.
271
378
  - [Sean Collins] Allow non string objects to be escaped by `Hanami::Utils::Escape`.
272
379
 
273
380
  ## v0.7.0 - 2016-01-22
381
+
274
382
  ### Changed
383
+
275
384
  - [Luca Guidi] Renamed the project
276
385
 
277
386
  ## v0.6.1 - 2016-01-19
387
+
278
388
  ### Fixed
389
+
279
390
  - [Anton Davydov] Ensure `Lotus::Utils::String#classify` to work properly with dashes (eg. `"app-store" => "App::Store"`)
280
391
 
281
392
  ## v0.6.0 - 2016-01-12
393
+
282
394
  ### Added
395
+
283
396
  - [Luca Guidi] Official support for Ruby 2.3
284
397
  - [Luca Guidi] Custom inflections
285
398
  - [Luca Guidi] Introduced `Lotus::Utils::Duplicable` as a safe dup logic for Ruby types
286
399
  - [Luca Guidi] Added `Lotus::Utils::String#rsub` replace rightmost occurrence
287
400
 
288
401
  ### Fixed
402
+
289
403
  - [Luca Guidi] Fix `Lotus::Utils::PathPrefix#join` and `#relative_join` by rejecting arguments that are equal to the separator
290
404
  - [Karim Kiatlottiavi] Fix `Encoding::UndefinedConversionError` in `Lotus::Utils::Escape.encode`
291
405
 
292
406
  ### Changed
407
+
293
408
  - [Luca Guidi] Deprecate Ruby 2.0 and 2.1
294
409
  - [Luca Guidi] Removed `Lotus::Utils::Callbacks#add` in favor of `#append`
295
410
  - [Luca Guidi] Removed pattern support for `Utils::Class.load!` (eg. `Articles(Controller|::Controller)`)
296
411
 
297
412
  ## v0.5.2 - 2015-09-30
413
+
298
414
  ### Added
415
+
299
416
  - [Luca Guidi] Added `Lotus::Utils::String#capitalize`
300
417
  - [Trung Lê] Official support for JRuby 9k+
301
418
 
302
419
  ## v0.5.1 - 2015-07-10
420
+
303
421
  ### Fixed
422
+
304
423
  - [Thiago Felippe] Ensure `Lotus::Utils::PathPrefix#join` won't remote duplicate entries (eg `/admin/dashboard/admin`)
305
424
 
306
425
  ## v0.5.0 - 2015-06-23
426
+
307
427
  ### Added
428
+
308
429
  - [Luca Guidi] Extracted `Lotus::Logger` from `hanamirb`
309
430
 
310
431
  ### Changed
432
+
311
433
  - [Luca Guidi] `Lotus::Interactor::Result` contains only objects explicitly exposed via `Lotus::Interactor.expose`.
312
434
 
313
435
  ## v0.4.3 - 2015-05-22
436
+
314
437
  ### Added
438
+
315
439
  - [François Beausoleil] Improved `Lotus::Utils::Kernel` messages for `TypeError`.
316
440
 
317
441
  ## v0.4.2 - 2015-05-15
442
+
318
443
  ### Fixed
444
+
319
445
  - [Luca Guidi] Ensure `Lotus::Utils::Attributes#to_h` to return `::Hash`
320
446
 
321
447
  ## v0.4.1 - 2015-05-15
448
+
322
449
  ### Added
450
+
323
451
  - [Luca Guidi & Alfonso Uceda Pompa] Introduced `Lotus::Utils::Inflector`, `Lotus::Utils::String#pluralize` and `#singularize`
324
452
 
325
453
  ### Fixed
454
+
326
455
  - [Luca Guidi] Ensure `Lotus::Utils::Attributes#to_h` to safely return nested `::Hash` instances for complex data structures.
327
456
  - [Luca Guidi] Let `Lotus::Interactor#error` to return a falsey value for control flow. (eg. `check_permissions or error "You can't access"`)
328
457
 
329
458
  ## v0.4.0 - 2015-03-23
459
+
330
460
  ### Added
461
+
331
462
  - [Luca Guidi] Introduced `Lotus::Utils::Escape`. It implements OWASP/ESAPI suggestions for HTML, HTML attribute and URL escape utilities.
332
463
  - [Luca Guidi] Introduced `Lotus::Utils::String#dasherize`
333
464
  - [Luca Guidi] Introduced `Lotus::Utils::String#titleize`
334
465
 
335
466
  ## v0.3.5 - 2015-03-12
467
+
336
468
  ### Added
469
+
337
470
  - [Luca Guidi] Introduced `Lotus::Interactor`
338
471
  - [Luca Guidi] Introduced `Lotus::Utils::BasicObject`
339
472
 
340
473
  ## v0.3.4 - 2015-01-30
474
+
341
475
  ### Added
476
+
342
477
  - [Alfonso Uceda Pompa] Aliased `Lotus::Utils::Attributes#get` with `#[]`
343
478
  - [Simone Carletti] Introduced `Lotus::Utils::Callbacks::Chain#prepend` and `#append`
344
479
 
345
480
  ### Deprecated
481
+
346
482
  - [Luca Guidi] Deprecated `Lotus::Utils::Callbacks::Chain#add` in favor of `#append`
347
483
 
348
484
  ## v0.3.3 - 2015-01-08
485
+
349
486
  ### Fixed
487
+
350
488
  - [Luca Guidi] Ensure to return the right offending object if a missing method is called with Utils::String and Hash (eg. `Utils::Hash.new(a: 1).all? {|_, v| v.foo }` blame `v` instead of `Hash`)
351
489
  - [Luca Guidi] Raise an error if try to coerce non numeric strings into Integer, Float & BigDecimal (eg. `Utils::Kernel.Integer("hello") # => raise TypeError`)
352
490
 
353
491
  ## v0.3.2 - 2014-12-23
492
+
354
493
  ### Added
494
+
355
495
  - [Luca Guidi] Official support for Ruby 2.2
356
496
  - [Luca Guidi] Introduced `Utils::Attributes`
357
497
  - [Luca Guidi] Added `Utils::Hash#stringify!`
358
498
 
359
499
  ## v0.3.1 - 2014-11-23
500
+
360
501
  ### Added
502
+
361
503
  - [Luca Guidi] Allow `Utils::Class.load!` to accept any object that implements `#to_s`
362
504
  - [Trung Lê] Allow `Utils::Class.load!` to accept a class
363
505
  - [Luca Guidi] Introduced `Utils::Class.load_from_pattern!`
@@ -371,14 +513,18 @@ No changes.
371
513
  - [Luca Guidi] Made `Utils::PathPrefix#join` to accept multiple argument
372
514
 
373
515
  ### Fixed
516
+
374
517
  - [Luca Guidi] Made `Utils::PathPrefix#join` remove trailing occurrences for `@separator` from the output
375
518
  - [Luca Guidi] Made `Utils::PathPrefix#relative_join` to correctly replace all the instances of `@separator` from the output
376
519
 
377
520
  ### Deprecated
521
+
378
522
  - [Luca Guidi] Deprecated `Utils::Class.load!` with a pattern like `Articles(Controller|::Controller)`, use `Utils::Class.load_from_pattern!` instead
379
523
 
380
524
  ## v0.3.0 - 2014-10-23
525
+
381
526
  ### Added
527
+
382
528
  - [Celso Fernandes] Add BigDecimal coercion to Lotus::Utils::Kernel
383
529
  - [Luca Guidi] Define `Boolean` constant, if missing
384
530
  - [Luca Guidi] Use composition over inheritance for `Lotus::Utils::PathPrefix`
@@ -386,6 +532,7 @@ No changes.
386
532
  - [Luca Guidi] Use composition over inheritance for `Lotus::Utils::String`
387
533
 
388
534
  ### Fixed
535
+
389
536
  - [Luca Guidi] Improved error message for `Utils::Class.load!`
390
537
  - [Tom Kadwill] Improved error `NameError` message by passing in the whole constant name to `Utils::Class.load!`
391
538
  - [Luca Guidi] `Utils::Hash#to_h` return instances of `::Hash` in case of nested symbolized data structure
@@ -395,7 +542,9 @@ No changes.
395
542
  - [Luca Guidi] Ensure `Utils::Hash#inspect` output to be the same of `::Hash#inspect`
396
543
 
397
544
  ## v0.2.0 - 2014-06-23
545
+
398
546
  ### Added
547
+
399
548
  - [Luca Guidi] Implemented `Lotus::Utils::Kernel.Symbol`
400
549
  - [Luca Guidi] Made `Kernel.Pathname` to raise an error when `nil` is passed as argument
401
550
  - [Luca Guidi] Implemented `Lotus::Utils::LoadPaths#freeze` in order to prevent modification after the object has been frozen
@@ -406,9 +555,11 @@ No changes.
406
555
  - [Luca Guidi] Implemented `Lotus::Utils::Kernel.Pathname`
407
556
 
408
557
  ### Fixed
558
+
409
559
  - [Luca Guidi] Implemented `Lotus::Utils::LoadPaths#initialize_copy` in order to safely `#dup` and `#clone`
410
560
 
411
561
  ### Changed
562
+
412
563
  - [Luca Guidi] Implemented `Lotus::Utils::Callbacks::Chain#freeze` in order to prevent modification after the object has been frozen
413
564
  - [Luca Guidi] All the `Utils::Kernel` methods will raise `TypeError` in case of failed coercion.
414
565
  - [Luca Guidi] Made `Kernel.Time` to raise an error when `nil` is passed as argument
@@ -424,7 +575,9 @@ No changes.
424
575
  - [Luca Guidi] Use composition over inheritance for `Lotus::Utils::Callbacks::Chain`
425
576
 
426
577
  ## v0.1.1 - 2014-04-23
578
+
427
579
  ### Added
580
+
428
581
  - [Luca Guidi] Implemented `Lotus::Utils::Kernel.Time`
429
582
  - [Luca Guidi] Implemented `Lotus::Utils::Kernel.DateTime`
430
583
  - [Luca Guidi] Implemented `Lotus::Utils::Kernel.Date`
@@ -437,10 +590,13 @@ No changes.
437
590
  - [Luca Guidi] Implemented `Lotus::Utils::Kernel.Array`
438
591
 
439
592
  ### Fixed
593
+
440
594
  - [Christopher Keele] Add missing stdlib `Set` require to `Utils::ClassAttribute`
441
595
 
442
596
  ## v0.1.0 - 2014-01-23
597
+
443
598
  ### Added
599
+
444
600
  - [Luca Guidi] Introduced `Lotus::Utils::String#demodulize`
445
601
  - [Luca Guidi] Introduced `Lotus::Utils::IO.silence_warnings`
446
602
  - [Luca Guidi] Introduced class loading mechanism from a string: `Utils::Class.load!`
data/README.md CHANGED
@@ -10,23 +10,22 @@ Ruby core extensions and class utilities for [Hanami](http://hanamirb.org)
10
10
  [![Depfu](https://badges.depfu.com/badges/a8545fb67cf32a2c75b6227bc0821027/overview.svg)](https://depfu.com/github/hanami/utils?project=Bundler)
11
11
  [![Inline Docs](http://inch-ci.org/github/hanami/utils.svg)](http://inch-ci.org/github/hanami/utils)
12
12
 
13
-
14
13
  ## Version
15
14
 
16
15
  **This branch contains the code for `hanami-utils` 2.x.**
17
16
 
18
17
  ## Contact
19
18
 
20
- * Home page: http://hanamirb.org
21
- * Mailing List: http://hanamirb.org/mailing-list
22
- * API Doc: http://rdoc.info/gems/hanami-utils
23
- * Bugs/Issues: https://github.com/hanami/utils/issues
24
- * Support: http://stackoverflow.com/questions/tagged/hanami
25
- * Chat: http://chat.hanamirb.org
19
+ - Home page: http://hanamirb.org
20
+ - Mailing List: http://hanamirb.org/mailing-list
21
+ - API Doc: http://rdoc.info/gems/hanami-utils
22
+ - Bugs/Issues: https://github.com/hanami/utils/issues
23
+ - Support: http://stackoverflow.com/questions/tagged/hanami
24
+ - Chat: http://chat.hanamirb.org
26
25
 
27
26
  ## Rubies
28
27
 
29
- __Hanami::Utils__ supports Ruby (MRI) 3.0+
28
+ **Hanami::Utils** supports Ruby (MRI) 3.0+
30
29
 
31
30
  ## Installation
32
31
 
@@ -46,23 +45,15 @@ Or install it yourself as:
46
45
 
47
46
  ## Usage
48
47
 
49
- __Hanami::Utils__ is designed to enhance Ruby's code and stdlib.
48
+ **Hanami::Utils** is designed to enhance Ruby's code and stdlib.
50
49
  **By default this gem doesn't load any code, you must require what you need.**
51
50
 
52
51
  ## Features
53
52
 
54
- ### Hanami::Interactor
55
-
56
- Standardized Service Object with small interface and rich returning result. [[API doc](http://www.rubydoc.info/gems/hanami-utils/Hanami/Interactor)]
57
-
58
53
  ### Hanami::Logger
59
54
 
60
55
  Enhanced version of Ruby's `Logger`. [[API doc](http://www.rubydoc.info/gems/hanami-utils/Hanami/Logger)]
61
56
 
62
- ### Hanami::Utils::BasicObject
63
-
64
- Enhanced version of Ruby's `BasicObject`. [[API doc](http://www.rubydoc.info/gems/hanami-utils/Hanami/Utils/BasicObject)]
65
-
66
57
  ### Hanami::Utils::Blank
67
58
 
68
59
  Checks for blank. [[API doc](http://www.rubydoc.info/gems/hanami-utils/Hanami/Utils/Blank)]
@@ -133,7 +124,7 @@ Enhanced version of Ruby's `String`. [[API doc](http://www.rubydoc.info/gems/han
133
124
 
134
125
  ## Versioning
135
126
 
136
- __Hanami::Utils__ uses [Semantic Versioning 2.0.0](http://semver.org)
127
+ **Hanami::Utils** uses [Semantic Versioning 2.0.0](http://semver.org)
137
128
 
138
129
  ## Contributing
139
130
 
data/hanami-utils.gemspec CHANGED
@@ -16,7 +16,6 @@ Gem::Specification.new do |spec|
16
16
 
17
17
  spec.files = `git ls-files -- lib/* CHANGELOG.md LICENSE.md README.md hanami-utils.gemspec`.split($/)
18
18
  spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
19
- spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
20
19
  spec.require_paths = ["lib"]
21
20
  spec.metadata["rubygems_mfa_required"] = "true"
22
21
  spec.required_ruby_version = ">= 3.0"
@@ -231,7 +231,7 @@ module Hanami
231
231
  string.gsub!(NAMESPACE_SEPARATOR, UNDERSCORE_SEPARATOR)
232
232
  string.gsub!(/([A-Z\d]+)([A-Z][a-z])/, UNDERSCORE_DIVISION_TARGET)
233
233
  string.gsub!(/([a-z\d])([A-Z])/, UNDERSCORE_DIVISION_TARGET)
234
- string.gsub!(/[[:space:]]|-/, UNDERSCORE_DIVISION_TARGET)
234
+ string.gsub!(/[[:space:]]|-|\./, UNDERSCORE_DIVISION_TARGET)
235
235
  string.downcase
236
236
  end
237
237
 
@@ -2,9 +2,7 @@
2
2
 
3
3
  module Hanami
4
4
  module Utils
5
- # Defines the version
6
- #
7
- # @since 0.1.0
8
- VERSION = "2.0.0.alpha6"
5
+ # @api public
6
+ VERSION = "2.0.0.rc1"
9
7
  end
10
8
  end