amazing_print 1.6.0 → 1.8.0

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 (71) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +19 -2
  3. data/README.md +2 -2
  4. data/lib/amazing_print/core_ext/awesome_method_array.rb +2 -2
  5. data/lib/amazing_print/ext/active_record.rb +32 -2
  6. data/lib/amazing_print/ext/mongo_mapper.rb +2 -2
  7. data/lib/amazing_print/ext/nobrainer.rb +2 -2
  8. data/lib/amazing_print/formatter.rb +1 -1
  9. data/lib/amazing_print/formatters/base_formatter.rb +7 -3
  10. data/lib/amazing_print/formatters/hash_formatter.rb +29 -9
  11. data/lib/amazing_print/formatters/mswin_helper.rb +4 -4
  12. data/lib/amazing_print/formatters/object_formatter.rb +2 -2
  13. data/lib/amazing_print/formatters/struct_formatter.rb +2 -2
  14. data/lib/amazing_print/inspector.rb +3 -3
  15. data/lib/amazing_print/version.rb +1 -1
  16. metadata +6 -63
  17. data/.gitignore +0 -35
  18. data/Appraisals +0 -66
  19. data/Gemfile +0 -18
  20. data/Gemfile.lock +0 -94
  21. data/LICENSE +0 -22
  22. data/Rakefile +0 -25
  23. data/spec/active_record_helper.rb +0 -43
  24. data/spec/colors_spec.rb +0 -120
  25. data/spec/core_ext/logger_spec.rb +0 -70
  26. data/spec/ext/action_controller_spec.rb +0 -40
  27. data/spec/ext/action_view_spec.rb +0 -24
  28. data/spec/ext/active_model_spec.rb +0 -37
  29. data/spec/ext/active_record_spec.rb +0 -302
  30. data/spec/ext/active_support_spec.rb +0 -37
  31. data/spec/ext/mongo_mapper_spec.rb +0 -265
  32. data/spec/ext/mongoid_spec.rb +0 -135
  33. data/spec/ext/nobrainer_spec.rb +0 -64
  34. data/spec/ext/nokogiri_spec.rb +0 -52
  35. data/spec/ext/ostruct_spec.rb +0 -24
  36. data/spec/ext/ripple_spec.rb +0 -53
  37. data/spec/ext/sequel_spec.rb +0 -45
  38. data/spec/formats_spec.rb +0 -795
  39. data/spec/methods_spec.rb +0 -520
  40. data/spec/misc_spec.rb +0 -206
  41. data/spec/objects_spec.rb +0 -225
  42. data/spec/sequel_helper.rb +0 -18
  43. data/spec/spec_helper.rb +0 -112
  44. data/spec/support/active_record_data/3_2_diana.txt +0 -24
  45. data/spec/support/active_record_data/3_2_diana_legacy.txt +0 -24
  46. data/spec/support/active_record_data/3_2_multi.txt +0 -50
  47. data/spec/support/active_record_data/3_2_multi_legacy.txt +0 -50
  48. data/spec/support/active_record_data/4_0_diana.txt +0 -98
  49. data/spec/support/active_record_data/4_0_multi.txt +0 -198
  50. data/spec/support/active_record_data/4_1_diana.txt +0 -97
  51. data/spec/support/active_record_data/4_1_multi.txt +0 -196
  52. data/spec/support/active_record_data/4_2_diana.txt +0 -109
  53. data/spec/support/active_record_data/4_2_diana_legacy.txt +0 -109
  54. data/spec/support/active_record_data/4_2_multi.txt +0 -220
  55. data/spec/support/active_record_data/4_2_multi_legacy.txt +0 -220
  56. data/spec/support/active_record_data/5_0_diana.txt +0 -105
  57. data/spec/support/active_record_data/5_0_multi.txt +0 -212
  58. data/spec/support/active_record_data/5_1_diana.txt +0 -104
  59. data/spec/support/active_record_data/5_1_multi.txt +0 -210
  60. data/spec/support/active_record_data/5_2_diana.txt +0 -104
  61. data/spec/support/active_record_data/5_2_multi.txt +0 -210
  62. data/spec/support/active_record_data/6_0_diana.txt +0 -104
  63. data/spec/support/active_record_data/6_0_multi.txt +0 -210
  64. data/spec/support/active_record_data/6_1_diana.txt +0 -109
  65. data/spec/support/active_record_data/6_1_multi.txt +0 -220
  66. data/spec/support/active_record_data/7_0_diana.txt +0 -110
  67. data/spec/support/active_record_data/7_0_multi.txt +0 -222
  68. data/spec/support/active_record_data.rb +0 -22
  69. data/spec/support/ext_verifier.rb +0 -46
  70. data/spec/support/mongoid_versions.rb +0 -24
  71. data/spec/support/rails_versions.rb +0 -62
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 114d8297770972541aa0e40c8dd8fbc8dccf658089fe2b69d272fac2994b9621
4
- data.tar.gz: 4e26b60b130dfe0b8eb4ebfe1d91f61cb3ca3de60d07ce0166650257bf83bce9
3
+ metadata.gz: ab76db037a1c38f0bd372838a92ae03e453f2d81eb73e9c9df5c272b600747dc
4
+ data.tar.gz: 45a2b9d7de1d5b9f04a57277364646762fd0b84021e91ee71d7a01e966a9e6e7
5
5
  SHA512:
6
- metadata.gz: f1890155df4d922d6975a3ddca5c229a2d6f3c1326cc82836bea4816a068dade724f1dfcaadc8697b213474908fc17671aa75dc79d1758cbe378509267440534
7
- data.tar.gz: 270b1f75b7aa990b103325f69468ea985c29a09f5b23450cc0e7b9a600a5f3a3ea6805c813151e1b584801195784fd604e30881dae9fd1e2ab1107c769eadd52
6
+ metadata.gz: ba4f13b020e16874a0313582279b5e8d5e32455da5d8cdb6ccfac4fd21a150e6061000099558e5ae280c01ddd8c460bf8b2a1ea40301dec4e87fc47046678013
7
+ data.tar.gz: 1f60c6eb6b2b302aabb011323dae7d78ec37855b727d884c5b83256d075b416de84c87b35e6eb6d21d72e9a5670f53331f639a8310e8bbee285235e24a9c5782
data/CHANGELOG.md CHANGED
@@ -1,8 +1,25 @@
1
1
  # CHANGELOG
2
2
 
3
- ## Unreleased
3
+ ## v1.8.0
4
4
 
5
- ## V1.6.0
5
+ - Drop Ruby 3.0 and add Ruby 3.4 #125
6
+
7
+ ## v1.7.2
8
+
9
+ - update the version string in `AmazingPrint.version`
10
+
11
+ ## v1.7.1
12
+
13
+ - no changes, only linting
14
+
15
+ ## v1.7.0
16
+
17
+ - Require Ruby >= 3.0
18
+ - Add support for `::ActiveModel::Attributes`
19
+ - Preserve user defined color defaults
20
+ - Micro-optimization to `AmazingPrint::ActiveRecord#cast` (avoid calls to `#ancestors`)
21
+
22
+ ## v1.6.0
6
23
 
7
24
  - Use pager with Pry #96
8
25
  - Add Rails 7 appraisal #98
data/README.md CHANGED
@@ -14,8 +14,8 @@ AmazingPrint is a fork of [AwesomePrint](https://github.com/awesome-print/awesom
14
14
 
15
15
  ### Supported Versions ###
16
16
 
17
- - Ruby >= 2.5
18
- - Rails >= 5.2
17
+ - Ruby >= 3.1
18
+ - Rails >= 6.1
19
19
 
20
20
  ### Installation ###
21
21
  # Installing as Ruby gem
@@ -56,7 +56,7 @@ module AwesomeMethodArray # :nodoc:
56
56
  # the comment :-)
57
57
  #
58
58
  arr = if blk
59
- super(pattern) do |match|
59
+ super do |match|
60
60
  #
61
61
  # The binding can only be used with Ruby-defined methods, therefore
62
62
  # we must rescue potential "ArgumentError: Can't create Binding from
@@ -75,7 +75,7 @@ module AwesomeMethodArray # :nodoc:
75
75
  yield match
76
76
  end
77
77
  else
78
- super(pattern)
78
+ super
79
79
  end
80
80
  arr.instance_variable_set(:@__awesome_methods__, instance_variable_get(:@__awesome_methods__))
81
81
  arr.select! { |item| item.is_a?(Symbol) || item.is_a?(String) } # grep block might return crap.
@@ -20,11 +20,15 @@ module AmazingPrint
20
20
 
21
21
  if object.is_a?(::ActiveRecord::Base)
22
22
  cast = :active_record_instance
23
+ elsif object.is_a?(Class) && object.include?(::ActiveModel::Attributes)
24
+ cast = :active_model_class
25
+ elsif object.is_a?(::ActiveModel::Attributes)
26
+ cast = :active_model_instance
23
27
  elsif object.is_a?(::ActiveModel::Errors)
24
28
  cast = :active_model_error
25
- elsif object.is_a?(Class) && object.ancestors.include?(::ActiveRecord::Base)
29
+ elsif object.is_a?(Class) && object <= ::ActiveRecord::Base
26
30
  cast = :active_record_class
27
- elsif type == :activerecord_relation || object.class.ancestors.include?(::ActiveRecord::Relation)
31
+ elsif type == :activerecord_relation || object.is_a?(::ActiveRecord::Relation)
28
32
  cast = :array
29
33
  end
30
34
  cast
@@ -71,6 +75,32 @@ module AmazingPrint
71
75
  [awesome_simple("class #{object} < #{object.superclass}", :class), awesome_hash(data)].join(' ')
72
76
  end
73
77
 
78
+ # Format ActiveModel instance object.
79
+ #------------------------------------------------------------------------------
80
+ def awesome_active_model_instance(object)
81
+ return object.inspect unless defined?(::ActiveSupport::OrderedHash)
82
+ return awesome_object(object) if @options[:raw]
83
+
84
+ data = object.attributes.each_with_object(::ActiveSupport::OrderedHash.new) do |c, hash|
85
+ hash[c.first.to_sym] = c.last
86
+ end
87
+
88
+ [awesome_simple(object.to_s, :active_model_instance), awesome_hash(data)].join(' ')
89
+ end
90
+
91
+ # Format ActiveModel class object.
92
+ #------------------------------------------------------------------------------
93
+ def awesome_active_model_class(object)
94
+ return object.inspect unless defined?(::ActiveSupport::OrderedHash)
95
+ return awesome_class(object) if @options[:raw]
96
+
97
+ data = object.attribute_types.each_with_object(::ActiveSupport::OrderedHash.new) do |c, hash|
98
+ hash[c.first.to_sym] = c.last.type
99
+ end
100
+
101
+ [awesome_simple("class #{object} < #{object.superclass}", :class), awesome_hash(data)].join(' ')
102
+ end
103
+
74
104
  # Format ActiveModel error object.
75
105
  #------------------------------------------------------------------------------
76
106
  def awesome_active_model_error(object)
@@ -19,8 +19,8 @@ module AmazingPrint
19
19
  cast = cast_without_mongo_mapper(object, type)
20
20
 
21
21
  if defined?(::MongoMapper::Document)
22
- if object.is_a?(Class) && !(object.ancestors & [::MongoMapper::Document,
23
- ::MongoMapper::EmbeddedDocument]).empty?
22
+ if object.is_a?(Class) && !object.ancestors.intersect?([::MongoMapper::Document,
23
+ ::MongoMapper::EmbeddedDocument]).nil?
24
24
  cast = :mongo_mapper_class
25
25
  elsif object.is_a?(::MongoMapper::Document) || object.is_a?(::MongoMapper::EmbeddedDocument)
26
26
  cast = :mongo_mapper_instance
@@ -32,9 +32,9 @@ module AmazingPrint
32
32
  #------------------------------------------------------------------------------
33
33
  def awesome_nobrainer_class(object)
34
34
  name = "#{awesome_simple(object, :class)} < #{awesome_simple(object.superclass, :class)}"
35
- data = object.fields.map do |field, options|
35
+ data = object.fields.to_h do |field, options|
36
36
  [field, (options[:type] || Object).to_s.underscore.to_sym]
37
- end.to_h
37
+ end
38
38
 
39
39
  name = "class #{awesome_simple(object.to_s, :class)}"
40
40
  base = "< #{awesome_simple(object.superclass.to_s, :class)}"
@@ -48,7 +48,7 @@ module AmazingPrint
48
48
  elsif (hash = convert_to_hash(object))
49
49
  awesome_hash(hash)
50
50
  else
51
- awesome_simple(object.inspect.to_s, type, @inspector)
51
+ awesome_simple(object.inspect.to_s, type, @inspector) # rubocop:disable Lint/RedundantTypeConversion
52
52
  end
53
53
  end
54
54
 
@@ -110,8 +110,8 @@ module AmazingPrint
110
110
  inspector.current_indentation
111
111
  end
112
112
 
113
- def indented(&blk)
114
- inspector.increase_indentation(&blk)
113
+ def indented(&)
114
+ inspector.increase_indentation(&)
115
115
  end
116
116
 
117
117
  # precompute common indentations
@@ -143,8 +143,12 @@ module AmazingPrint
143
143
  end
144
144
  end
145
145
 
146
+ def colorless(string)
147
+ string.gsub(/\e\[[\d;]+m/, '')
148
+ end
149
+
146
150
  def colorless_size(string)
147
- string.gsub(/\e\[[\d;]+m/, '').size
151
+ colorless(string).size
148
152
  end
149
153
  end
150
154
  end
@@ -65,8 +65,18 @@ module AmazingPrint
65
65
  result
66
66
  end
67
67
 
68
+ def key_size(key)
69
+ return key.inspect.size if symbol?(key)
70
+
71
+ if options[:html]
72
+ single_line { inspector.awesome(key) }.size
73
+ else
74
+ plain_single_line { inspector.awesome(key) }.size
75
+ end
76
+ end
77
+
68
78
  def max_key_width(keys)
69
- keys.map { |key, _value| colorless_size(key) }.max || 0
79
+ keys.map { |key, _value| key_size(key) }.max || 0
70
80
  end
71
81
 
72
82
  def printable_keys
@@ -75,27 +85,37 @@ module AmazingPrint
75
85
  keys.sort! { |a, b| a.to_s <=> b.to_s } if options[:sort_keys]
76
86
 
77
87
  keys.map! do |key|
78
- plain_single_line do
79
- [inspector.awesome(key), hash[key]]
88
+ single_line do
89
+ [key, hash[key]]
80
90
  end
81
91
  end
82
92
  end
83
93
 
84
94
  def symbol?(key)
85
- key[0] == ':'
95
+ key.is_a?(Symbol)
86
96
  end
87
97
 
88
98
  def ruby19_syntax(key, value, width)
89
- key[0] = ''
90
- key << ':'
91
- "#{align(key, width)} #{inspector.awesome(value)}"
99
+ # Move the colon to the right side of the symbol
100
+ awesome_key = inspector.awesome(key).sub(/#{key.inspect}/, "#{key}:")
101
+
102
+ "#{align(awesome_key, width)} #{inspector.awesome(value)}"
92
103
  end
93
104
 
94
105
  def pre_ruby19_syntax(key, value, width)
95
- "#{align(key, width)}#{colorize(' => ', :hash)}#{inspector.awesome(value)}"
106
+ awesome_key = single_line { inspector.awesome(key) }
107
+ "#{align(awesome_key, width)}#{colorize(' => ', :hash)}#{inspector.awesome(value)}"
108
+ end
109
+
110
+ def plain_single_line(&)
111
+ plain = options[:plain]
112
+ options[:plain] = true
113
+ single_line(&)
114
+ ensure
115
+ options[:plain] = plain
96
116
  end
97
117
 
98
- def plain_single_line
118
+ def single_line
99
119
  multiline = options[:multiline]
100
120
  options[:multiline] = false
101
121
  yield
@@ -27,10 +27,10 @@ module AmazingPrint
27
27
  def mode
28
28
  r = ['-'] * 6
29
29
  r[0] = 'd' if @stat.directory?
30
- r[1] = 'a' unless (@attrs & FILE_ATTRIBUTE_ARCHIVE).zero?
31
- r[2] = 'r' unless (@attrs & FILE_ATTRIBUTE_READONLY).zero?
32
- r[3] = 'h' unless (@attrs & FILE_ATTRIBUTE_HIDDEN).zero?
33
- r[4] = 's' unless (@attrs & FILE_ATTRIBUTE_SYSTEM).zero?
30
+ r[1] = 'a' unless @attrs.nobits?(FILE_ATTRIBUTE_ARCHIVE)
31
+ r[2] = 'r' unless @attrs.nobits?(FILE_ATTRIBUTE_READONLY)
32
+ r[3] = 'h' unless @attrs.nobits?(FILE_ATTRIBUTE_HIDDEN)
33
+ r[4] = 's' unless @attrs.nobits?(FILE_ATTRIBUTE_SYSTEM)
34
34
  r[5] = 'l' if File.symlink? @fname
35
35
  r.join
36
36
  end
@@ -17,7 +17,7 @@ module AmazingPrint
17
17
 
18
18
  def format
19
19
  vars = variables.map do |var|
20
- property = var.to_s[1..-1].to_sym # to_s because of some monkey patching done by Puppet.
20
+ property = var.to_s[1..].to_sym # to_s because of some monkey patching done by Puppet.
21
21
  accessor = if object.respond_to?(:"#{property}=")
22
22
  object.respond_to?(property) ? :accessor : :writer
23
23
  else
@@ -68,7 +68,7 @@ module AmazingPrint
68
68
  # We need to ensure that the original Kernel#format is used here instead of the one
69
69
  # defined above.
70
70
  # rubocop:disable Style/ColonMethodCall
71
- str + Kernel::format(':0x%08x', (object.__id__ * 2))
71
+ str + Kernel::format(':0x%08x', object.__id__ * 2)
72
72
  # rubocop:enable Style/ColonMethodCall
73
73
  end
74
74
 
@@ -17,7 +17,7 @@ module AmazingPrint
17
17
 
18
18
  def format
19
19
  vars = variables.map do |var|
20
- property = var.to_s[1..-1].to_sym # to_s because of some monkey patching done by Puppet.
20
+ property = var.to_s[1..].to_sym # to_s because of some monkey patching done by Puppet.
21
21
  accessor = if struct.respond_to?(:"#{property}=")
22
22
  struct.respond_to?(property) ? :accessor : :writer
23
23
  else
@@ -61,7 +61,7 @@ module AmazingPrint
61
61
  # We need to ensure that the original Kernel#format is used here instead of the one defined
62
62
  # above.
63
63
  # rubocop:disable Style/ColonMethodCall
64
- Kernel::format("#{struct.class.superclass}:#{struct.class}:0x%08x", (struct.__id__ * 2))
64
+ Kernel::format("#{struct.class.superclass}:#{struct.class}:0x%08x", struct.__id__ * 2)
65
65
  # rubocop:enable Style/ColonMethodCall
66
66
  end
67
67
 
@@ -79,8 +79,8 @@ module AmazingPrint
79
79
  indentator.indentation
80
80
  end
81
81
 
82
- def increase_indentation(&blk)
83
- indentator.indent(&blk)
82
+ def increase_indentation(&)
83
+ indentator.indent(&)
84
84
  end
85
85
 
86
86
  # Dispatcher that detects data nesting and invokes object-aware formatter.
@@ -192,7 +192,7 @@ module AmazingPrint
192
192
  #---------------------------------------------------------------------------
193
193
  def merge_custom_defaults!
194
194
  load_dotfile
195
- merge_options!(AmazingPrint.defaults) if AmazingPrint.defaults.is_a?(Hash)
195
+ merge_options!(AmazingPrint.defaults.dup) if AmazingPrint.defaults.is_a?(Hash)
196
196
  rescue StandardError => e
197
197
  warn "Could not load '.aprc' from ENV['HOME']: #{e}"
198
198
  end
@@ -7,6 +7,6 @@
7
7
  #------------------------------------------------------------------------------
8
8
  module AmazingPrint
9
9
  def self.version
10
- '1.6.0'
10
+ '1.8.0'
11
11
  end
12
12
  end
metadata CHANGED
@@ -1,15 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: amazing_print
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.6.0
4
+ version: 1.8.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Michael Dvorkin
8
8
  - Kevin McCormackPatrik Wenger
9
- autorequire:
10
9
  bindir: bin
11
10
  cert_chain: []
12
- date: 2024-03-08 00:00:00.000000000 Z
11
+ date: 1980-01-02 00:00:00.000000000 Z
13
12
  dependencies: []
14
13
  description: 'Great Ruby debugging companion: pretty print Ruby objects to visualize
15
14
  their structure. Supports custom object formatting via plugins'
@@ -18,15 +17,9 @@ executables: []
18
17
  extensions: []
19
18
  extra_rdoc_files: []
20
19
  files:
21
- - ".gitignore"
22
- - Appraisals
23
20
  - CHANGELOG.md
24
21
  - CONTRIBUTING.md
25
- - Gemfile
26
- - Gemfile.lock
27
- - LICENSE
28
22
  - README.md
29
- - Rakefile
30
23
  - lib/amazing_print.rb
31
24
  - lib/amazing_print/colorize.rb
32
25
  - lib/amazing_print/colors.rb
@@ -64,60 +57,11 @@ files:
64
57
  - lib/amazing_print/inspector.rb
65
58
  - lib/amazing_print/version.rb
66
59
  - lib/ap.rb
67
- - spec/active_record_helper.rb
68
- - spec/colors_spec.rb
69
- - spec/core_ext/logger_spec.rb
70
- - spec/ext/action_controller_spec.rb
71
- - spec/ext/action_view_spec.rb
72
- - spec/ext/active_model_spec.rb
73
- - spec/ext/active_record_spec.rb
74
- - spec/ext/active_support_spec.rb
75
- - spec/ext/mongo_mapper_spec.rb
76
- - spec/ext/mongoid_spec.rb
77
- - spec/ext/nobrainer_spec.rb
78
- - spec/ext/nokogiri_spec.rb
79
- - spec/ext/ostruct_spec.rb
80
- - spec/ext/ripple_spec.rb
81
- - spec/ext/sequel_spec.rb
82
- - spec/formats_spec.rb
83
- - spec/methods_spec.rb
84
- - spec/misc_spec.rb
85
- - spec/objects_spec.rb
86
- - spec/sequel_helper.rb
87
- - spec/spec_helper.rb
88
- - spec/support/active_record_data.rb
89
- - spec/support/active_record_data/3_2_diana.txt
90
- - spec/support/active_record_data/3_2_diana_legacy.txt
91
- - spec/support/active_record_data/3_2_multi.txt
92
- - spec/support/active_record_data/3_2_multi_legacy.txt
93
- - spec/support/active_record_data/4_0_diana.txt
94
- - spec/support/active_record_data/4_0_multi.txt
95
- - spec/support/active_record_data/4_1_diana.txt
96
- - spec/support/active_record_data/4_1_multi.txt
97
- - spec/support/active_record_data/4_2_diana.txt
98
- - spec/support/active_record_data/4_2_diana_legacy.txt
99
- - spec/support/active_record_data/4_2_multi.txt
100
- - spec/support/active_record_data/4_2_multi_legacy.txt
101
- - spec/support/active_record_data/5_0_diana.txt
102
- - spec/support/active_record_data/5_0_multi.txt
103
- - spec/support/active_record_data/5_1_diana.txt
104
- - spec/support/active_record_data/5_1_multi.txt
105
- - spec/support/active_record_data/5_2_diana.txt
106
- - spec/support/active_record_data/5_2_multi.txt
107
- - spec/support/active_record_data/6_0_diana.txt
108
- - spec/support/active_record_data/6_0_multi.txt
109
- - spec/support/active_record_data/6_1_diana.txt
110
- - spec/support/active_record_data/6_1_multi.txt
111
- - spec/support/active_record_data/7_0_diana.txt
112
- - spec/support/active_record_data/7_0_multi.txt
113
- - spec/support/ext_verifier.rb
114
- - spec/support/mongoid_versions.rb
115
- - spec/support/rails_versions.rb
116
60
  homepage: https://github.com/amazing-print/amazing_print
117
61
  licenses:
118
62
  - MIT
119
- metadata: {}
120
- post_install_message:
63
+ metadata:
64
+ changelog_uri: https://github.com/amazing-print/amazing_print/blob/master/CHANGELOG.md
121
65
  rdoc_options: []
122
66
  require_paths:
123
67
  - lib
@@ -125,15 +69,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
125
69
  requirements:
126
70
  - - ">="
127
71
  - !ruby/object:Gem::Version
128
- version: 2.5.0
72
+ version: 3.1.0
129
73
  required_rubygems_version: !ruby/object:Gem::Requirement
130
74
  requirements:
131
75
  - - ">="
132
76
  - !ruby/object:Gem::Version
133
77
  version: '0'
134
78
  requirements: []
135
- rubygems_version: 3.5.6
136
- signing_key:
79
+ rubygems_version: 3.6.7
137
80
  specification_version: 4
138
81
  summary: Pretty print Ruby objects with proper indentation and colors
139
82
  test_files: []
data/.gitignore DELETED
@@ -1,35 +0,0 @@
1
- ## MAC OS
2
- .DS_Store
3
-
4
- ## TEXTMATE
5
- *.tmproj
6
- tmtags
7
-
8
- ## EMACS
9
- *~
10
- \#*
11
- .\#*
12
-
13
- ## VIM
14
- *.swp
15
-
16
- ## RUBYMINE
17
- .idea
18
-
19
- ## PROJECT::GENERAL
20
- coverage
21
- rdoc
22
- pkg
23
- .ruby-version
24
- gemfiles/*.gemfile.lock
25
- Gemfile.lock
26
- /tmp
27
- /.bundle
28
- /gemfiles/.bundle
29
-
30
- ## PROJECT::RVM
31
- .rvmrc
32
-
33
- # PROJECT::RBENV
34
- .ruby-gemset
35
- *.gem
data/Appraisals DELETED
@@ -1,66 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- if RUBY_VERSION < '3'
4
- appraise 'rails-5.2' do
5
- gem 'activerecord-jdbcsqlite3-adapter', '~> 52.0', platform: :jruby
6
- gem 'rails', '~> 5.2.0'
7
- gem 'sqlite3', platform: :mri
8
- end
9
-
10
- appraise 'rails-6.0' do
11
- gem 'activerecord-jdbcsqlite3-adapter', '~> 60.0', platform: :jruby
12
- gem 'rails', '~> 6.0.0'
13
- gem 'sqlite3', platform: :mri
14
- end
15
-
16
- appraise 'mongoid-4.0' do
17
- # https://github.com/rails/rails/issues/34822#issuecomment-570670516
18
- gem 'bigdecimal', '~> 1.4', platforms: :mri
19
- gem 'mongoid', '~> 4.0.0'
20
- end
21
-
22
- appraise 'mongoid-5.0' do
23
- # https://github.com/rails/rails/issues/34822#issuecomment-570670516
24
- gem 'bigdecimal', '~> 1.4', platforms: :mri
25
- gem 'mongoid', '~> 5.0.0'
26
- end
27
-
28
- appraise 'mongoid-6.0' do
29
- gem 'mongoid', '~> 6.0.0'
30
- end
31
-
32
- appraise 'mongo_mapper' do
33
- gem 'activemodel', '~> 4.2.0'
34
- gem 'activesupport', '~> 4.2.0'
35
- gem 'bigdecimal', '~> 1.4', platforms: :mri
36
- gem 'mongo_mapper', '~> 0.14'
37
- end
38
- end
39
-
40
- if RUBY_VERSION >= '2.7'
41
- appraise 'rails-7.0' do
42
- gem 'activerecord-jdbcsqlite3-adapter', '~> 70.0', platform: :jruby
43
- gem 'rails', '~> 7.0.0'
44
- gem 'sqlite3', platform: :mri
45
- end
46
-
47
- appraise 'mongoid-7.0' do
48
- gem 'mongoid', '~> 7.0.0'
49
- end
50
-
51
- appraise 'mongoid-8.0' do
52
- gem 'mongoid', '~> 8.0.0'
53
- end
54
- end
55
-
56
- appraise 'rails-6.1' do
57
- gem 'activerecord-jdbcsqlite3-adapter', '~> 61.0', platform: :jruby
58
- gem 'rails', '~> 6.1.0'
59
- gem 'sqlite3', platform: :mri
60
- end
61
-
62
- appraise 'sequel-5.0' do
63
- gem 'jdbc-sqlite3', platform: :jruby
64
- gem 'sequel', '~> 5.0'
65
- gem 'sqlite3', platform: :mri
66
- end
data/Gemfile DELETED
@@ -1,18 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- source 'https://rubygems.org'
4
-
5
- # Specify your gem's dependencies in amazing_print.gemspec
6
- gemspec
7
-
8
- # Development dependencies
9
- # Update this once https://github.com/thoughtbot/appraisal/pull/202 is released
10
- gem 'appraisal', git: 'https://github.com/thoughtbot/appraisal.git', branch: :main
11
-
12
- gem 'bigdecimal'
13
- gem 'fakefs', '~> 1.2'
14
- gem 'nokogiri', '~> 1.10'
15
- gem 'pry'
16
- gem 'rspec', '~> 3.9'
17
- gem 'rubocop', '~> 1.20'
18
- gem 'rubocop-rspec', '~> 2.4'
data/Gemfile.lock DELETED
@@ -1,94 +0,0 @@
1
- GIT
2
- remote: https://github.com/thoughtbot/appraisal.git
3
- revision: feb78bcc6177038399bff098cb6c2bd4bca4972a
4
- branch: main
5
- specs:
6
- appraisal (2.5.0)
7
- bundler
8
- rake
9
- thor (>= 0.14.0)
10
-
11
- PATH
12
- remote: .
13
- specs:
14
- amazing_print (1.5.0)
15
-
16
- GEM
17
- remote: https://rubygems.org/
18
- specs:
19
- ast (2.4.2)
20
- bigdecimal (3.1.6)
21
- coderay (1.1.3)
22
- diff-lcs (1.5.0)
23
- fakefs (1.9.0)
24
- json (2.7.1)
25
- language_server-protocol (3.17.0.3)
26
- method_source (1.0.0)
27
- nokogiri (1.16.0-x86_64-linux)
28
- racc (~> 1.4)
29
- parallel (1.24.0)
30
- parser (3.3.0.2)
31
- ast (~> 2.4.1)
32
- racc
33
- pry (0.14.2)
34
- coderay (~> 1.1)
35
- method_source (~> 1.0)
36
- racc (1.7.3)
37
- rainbow (3.1.1)
38
- rake (13.1.0)
39
- regexp_parser (2.9.0)
40
- rexml (3.2.6)
41
- rspec (3.12.0)
42
- rspec-core (~> 3.12.0)
43
- rspec-expectations (~> 3.12.0)
44
- rspec-mocks (~> 3.12.0)
45
- rspec-core (3.12.2)
46
- rspec-support (~> 3.12.0)
47
- rspec-expectations (3.12.3)
48
- diff-lcs (>= 1.2.0, < 2.0)
49
- rspec-support (~> 3.12.0)
50
- rspec-mocks (3.12.6)
51
- diff-lcs (>= 1.2.0, < 2.0)
52
- rspec-support (~> 3.12.0)
53
- rspec-support (3.12.1)
54
- rubocop (1.59.0)
55
- json (~> 2.3)
56
- language_server-protocol (>= 3.17.0)
57
- parallel (~> 1.10)
58
- parser (>= 3.2.2.4)
59
- rainbow (>= 2.2.2, < 4.0)
60
- regexp_parser (>= 1.8, < 3.0)
61
- rexml (>= 3.2.5, < 4.0)
62
- rubocop-ast (>= 1.30.0, < 2.0)
63
- ruby-progressbar (~> 1.7)
64
- unicode-display_width (>= 2.4.0, < 3.0)
65
- rubocop-ast (1.30.0)
66
- parser (>= 3.2.1.0)
67
- rubocop-capybara (2.20.0)
68
- rubocop (~> 1.41)
69
- rubocop-factory_bot (2.25.1)
70
- rubocop (~> 1.41)
71
- rubocop-rspec (2.26.1)
72
- rubocop (~> 1.40)
73
- rubocop-capybara (~> 2.17)
74
- rubocop-factory_bot (~> 2.22)
75
- ruby-progressbar (1.13.0)
76
- thor (1.3.0)
77
- unicode-display_width (2.5.0)
78
-
79
- PLATFORMS
80
- x86_64-linux
81
-
82
- DEPENDENCIES
83
- amazing_print!
84
- appraisal!
85
- bigdecimal
86
- fakefs (~> 1.2)
87
- nokogiri (~> 1.10)
88
- pry
89
- rspec (~> 3.9)
90
- rubocop (~> 1.20)
91
- rubocop-rspec (~> 2.4)
92
-
93
- BUNDLED WITH
94
- 2.5.4