prettier 1.6.0 → 2.0.0.pre.rc3

Sign up to get free protection for your applications and to get access to all the features.
Files changed (149) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +342 -288
  3. data/CONTRIBUTING.md +6 -9
  4. data/LICENSE +1 -1
  5. data/README.md +11 -12
  6. data/dist/haml/embed.js +53 -0
  7. data/dist/haml/parser.js +31 -0
  8. data/{src → dist}/haml/parser.rb +0 -0
  9. data/dist/haml/printer.js +336 -0
  10. data/dist/parser/getInfo.js +17 -0
  11. data/{src → dist}/parser/netcat.js +1 -0
  12. data/dist/parser/parseSync.js +142 -0
  13. data/dist/parser/server.rb +141 -0
  14. data/dist/plugin.js +143 -0
  15. data/dist/prettier.js +15 -0
  16. data/dist/rbs/parser.js +34 -0
  17. data/{src → dist}/rbs/parser.rb +0 -0
  18. data/dist/rbs/printer.js +517 -0
  19. data/dist/ruby/embed.js +110 -0
  20. data/dist/ruby/nodes/alias.js +59 -0
  21. data/{src → dist}/ruby/nodes/aref.js +26 -35
  22. data/dist/ruby/nodes/args.js +165 -0
  23. data/dist/ruby/nodes/arrays.js +126 -0
  24. data/dist/ruby/nodes/assign.js +41 -0
  25. data/dist/ruby/nodes/blocks.js +87 -0
  26. data/dist/ruby/nodes/calls.js +260 -0
  27. data/dist/ruby/nodes/case.js +50 -0
  28. data/dist/ruby/nodes/class.js +54 -0
  29. data/dist/ruby/nodes/commands.js +124 -0
  30. data/dist/ruby/nodes/conditionals.js +242 -0
  31. data/dist/ruby/nodes/constants.js +38 -0
  32. data/dist/ruby/nodes/flow.js +66 -0
  33. data/dist/ruby/nodes/hashes.js +130 -0
  34. data/dist/ruby/nodes/heredocs.js +30 -0
  35. data/dist/ruby/nodes/hooks.js +35 -0
  36. data/dist/ruby/nodes/ints.js +27 -0
  37. data/dist/ruby/nodes/lambdas.js +69 -0
  38. data/dist/ruby/nodes/loops.js +73 -0
  39. data/dist/ruby/nodes/massign.js +73 -0
  40. data/dist/ruby/nodes/methods.js +70 -0
  41. data/dist/ruby/nodes/operators.js +70 -0
  42. data/dist/ruby/nodes/params.js +89 -0
  43. data/dist/ruby/nodes/patterns.js +109 -0
  44. data/dist/ruby/nodes/regexp.js +45 -0
  45. data/dist/ruby/nodes/rescue.js +82 -0
  46. data/dist/ruby/nodes/return.js +75 -0
  47. data/dist/ruby/nodes/statements.js +111 -0
  48. data/dist/ruby/nodes/strings.js +218 -0
  49. data/dist/ruby/nodes/super.js +30 -0
  50. data/dist/ruby/nodes/undef.js +26 -0
  51. data/dist/ruby/nodes.js +151 -0
  52. data/dist/ruby/parser.js +34 -0
  53. data/{src → dist}/ruby/parser.rb +1195 -254
  54. data/dist/ruby/printer.js +129 -0
  55. data/dist/ruby/toProc.js +93 -0
  56. data/dist/types/haml.js +4 -0
  57. data/dist/types/plugin.js +3 -0
  58. data/dist/types/rbs.js +4 -0
  59. data/dist/types/ruby.js +4 -0
  60. data/dist/types/utils.js +2 -0
  61. data/dist/types.js +30 -0
  62. data/dist/utils/containsAssignment.js +15 -0
  63. data/dist/utils/getTrailingComma.js +6 -0
  64. data/dist/utils/hasAncestor.js +15 -0
  65. data/{src → dist}/utils/inlineEnsureParens.js +16 -17
  66. data/dist/utils/isEmptyBodyStmt.js +10 -0
  67. data/dist/utils/isEmptyStmts.js +10 -0
  68. data/dist/utils/literal.js +8 -0
  69. data/dist/utils/literallineWithoutBreakParent.js +8 -0
  70. data/dist/utils/makeCall.js +13 -0
  71. data/dist/utils/noIndent.js +11 -0
  72. data/dist/utils/printEmptyCollection.js +44 -0
  73. data/dist/utils/skipAssignIndent.js +15 -0
  74. data/dist/utils.js +30 -0
  75. data/node_modules/prettier/bin-prettier.js +2573 -2264
  76. data/node_modules/prettier/doc.js +4829 -0
  77. data/node_modules/prettier/index.js +5979 -6846
  78. data/node_modules/prettier/package.json +23 -0
  79. data/node_modules/prettier/parser-angular.js +13 -14
  80. data/node_modules/prettier/parser-babel.js +7 -7
  81. data/node_modules/prettier/parser-espree.js +7 -7
  82. data/node_modules/prettier/parser-flow.js +7 -7
  83. data/node_modules/prettier/parser-glimmer.js +1 -1
  84. data/node_modules/prettier/parser-graphql.js +1 -1
  85. data/node_modules/prettier/parser-html.js +17 -17
  86. data/node_modules/prettier/parser-markdown.js +9 -9
  87. data/node_modules/prettier/parser-meriyah.js +7 -7
  88. data/node_modules/prettier/parser-postcss.js +2 -2
  89. data/node_modules/prettier/parser-typescript.js +7 -7
  90. data/node_modules/prettier/parser-yaml.js +2 -2
  91. data/node_modules/prettier/third-party.js +794 -131
  92. data/package.json +26 -18
  93. metadata +76 -67
  94. data/src/haml/embed.js +0 -87
  95. data/src/haml/parser.js +0 -23
  96. data/src/haml/printer.js +0 -438
  97. data/src/parser/parseSync.js +0 -172
  98. data/src/parser/server.rb +0 -66
  99. data/src/plugin.js +0 -148
  100. data/src/prettier.js +0 -16
  101. data/src/rbs/parser.js +0 -37
  102. data/src/rbs/printer.js +0 -643
  103. data/src/ruby/embed.js +0 -142
  104. data/src/ruby/nodes/alias.js +0 -73
  105. data/src/ruby/nodes/args.js +0 -222
  106. data/src/ruby/nodes/arrays.js +0 -162
  107. data/src/ruby/nodes/assign.js +0 -47
  108. data/src/ruby/nodes/blocks.js +0 -90
  109. data/src/ruby/nodes/calls.js +0 -206
  110. data/src/ruby/nodes/case.js +0 -65
  111. data/src/ruby/nodes/class.js +0 -64
  112. data/src/ruby/nodes/commands.js +0 -131
  113. data/src/ruby/nodes/conditionals.js +0 -282
  114. data/src/ruby/nodes/constants.js +0 -43
  115. data/src/ruby/nodes/flow.js +0 -74
  116. data/src/ruby/nodes/hashes.js +0 -155
  117. data/src/ruby/nodes/heredocs.js +0 -36
  118. data/src/ruby/nodes/hooks.js +0 -34
  119. data/src/ruby/nodes/ints.js +0 -31
  120. data/src/ruby/nodes/lambdas.js +0 -76
  121. data/src/ruby/nodes/loops.js +0 -98
  122. data/src/ruby/nodes/massign.js +0 -98
  123. data/src/ruby/nodes/methods.js +0 -74
  124. data/src/ruby/nodes/operators.js +0 -83
  125. data/src/ruby/nodes/params.js +0 -106
  126. data/src/ruby/nodes/patterns.js +0 -157
  127. data/src/ruby/nodes/regexp.js +0 -56
  128. data/src/ruby/nodes/rescue.js +0 -101
  129. data/src/ruby/nodes/return.js +0 -94
  130. data/src/ruby/nodes/statements.js +0 -142
  131. data/src/ruby/nodes/strings.js +0 -270
  132. data/src/ruby/nodes/super.js +0 -35
  133. data/src/ruby/nodes/undef.js +0 -42
  134. data/src/ruby/nodes.js +0 -34
  135. data/src/ruby/parser.js +0 -37
  136. data/src/ruby/printer.js +0 -147
  137. data/src/ruby/toProc.js +0 -105
  138. data/src/utils/containsAssignment.js +0 -11
  139. data/src/utils/getTrailingComma.js +0 -5
  140. data/src/utils/hasAncestor.js +0 -17
  141. data/src/utils/isEmptyBodyStmt.js +0 -7
  142. data/src/utils/isEmptyStmts.js +0 -11
  143. data/src/utils/literal.js +0 -7
  144. data/src/utils/literallineWithoutBreakParent.js +0 -7
  145. data/src/utils/makeCall.js +0 -14
  146. data/src/utils/noIndent.js +0 -11
  147. data/src/utils/printEmptyCollection.js +0 -49
  148. data/src/utils/skipAssignIndent.js +0 -17
  149. data/src/utils.js +0 -13
data/CHANGELOG.md CHANGED
@@ -6,104 +6,154 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/) a
6
6
 
7
7
  ## [Unreleased]
8
8
 
9
+ ## [2.0.0-rc3]
10
+
11
+ ### Changed
12
+
13
+ - [#987](https://github.com/prettier/plugin-ruby/pull/9870) - valscion - Ignore stderr when checking for node <-> ruby connection clients, restoring the behavior of v1.x
14
+ - [#989](https://github.com/prettier/plugin-ruby/issues/989) - hubertjakubiak, kddnewton - Make sure comments after the keyword/lbrace are not moved inside the body of the statements of do and brace blocks.
15
+
16
+ ## [2.0.0-rc2]
17
+
18
+ ### Added
19
+
20
+ - [#979](https://github.com/prettier/plugin-ruby/issues/979) - ronocod, kddnewton - Alignment of `to_not` is explicitly allowed to not indent to better support rspec.
21
+ - [#894](https://github.com/prettier/plugin-ruby/issues/894) - mister-what, kddnewton - Add a warning that this plugin will not function with the plug'n'play filesystem provided by yarn berry.
22
+
23
+ ### Changed
24
+
25
+ - [#943](https://github.com/prettier/plugin-ruby/issues/943) - valscion, kddnewton - Trailing call operators that are followed by comments should stay on the first line.
26
+
27
+ ## [2.0.0-rc1]
28
+
29
+ ### Added
30
+
31
+ - [#949](https://github.com/prettier/plugin-ruby/pull/949) - kddnewton - Converted over to using TypeScript for development.
32
+
33
+ ### Changed
34
+
35
+ - [#958](https://github.com/prettier/plugin-ruby/issues/958) - mharris-figma, kddnewton - Handle optional `do` keyword in `for` loop expressions.
36
+ - [#926](https://github.com/prettier/plugin-ruby/issues/926) - jscheid, kddnewton - Better error handling in case certain expected keywords or operators are missing.
37
+ - [#819](https://github.com/prettier/plugin-ruby/issues/819) - coisnepe, kddnewton - Ensure that comments placed immediately after the left parenthesis of a method definition are not moved into the body of the methods.
38
+ - [#957](https://github.com/prettier/plugin-ruby/issues/957) - azz, kddnewton - Make it so that the format pragma does not have to be on the first line of the file.
39
+ - [#895](https://github.com/prettier/plugin-ruby/issues/895) - rsslldnphy, kddnewton - Ensure quotes are properly escaped in the content of a hash value for HAML attributes.
40
+ - [#900](https://github.com/prettier/plugin-ruby/issues/900) - rsslldnphy, kddnewton - Ensure that in a HAML line where you have interpolation inside of a tag content that you print it properly.
41
+ - [#929](https://github.com/prettier/plugin-ruby/issues/929) - ryanb, kddnewton - Deeply nested blocks should not break their call chains.
42
+ - [#935](https://github.com/prettier/plugin-ruby/pull/935) - nbudin, mlauter - Ensure embedded formatting heredocs are properly indented.
43
+ - [#975](https://github.com/prettier/plugin-ruby/pull/975) - kddnewton - Refactor the way we determine how to connect to the parser server.
44
+
45
+ ### Removed
46
+
47
+ - [#976](https://github.com/prettier/plugin-ruby/pull/976) - kddnewton - Remove the `rubyNetcatCommand` option, as it should no longer be necessary.
48
+
49
+ ## [1.6.1] - 2021-06-30
50
+
51
+ ### Changed
52
+
53
+ - [#862](https://github.com/prettier/plugin-ruby/issues/862) - azz, kddnewton - Group together `.where.not` calls in method chains.
54
+ - [#863](https://github.com/prettier/plugin-ruby/issues/863) - azz, kddnewton - Fix up Sorbet `sig` block formatting when chaining method calls.
55
+ - [#908](https://github.com/prettier/plugin-ruby/issues/908) - Hansenq, kddnewton - Method chains with blocks should be properly indented.
56
+ - [#916](https://github.com/prettier/plugin-ruby/issues/916) - pbrisbin, kddnewton - Ensure all of the necessary files are present in the gem.
57
+ - [#917](https://github.com/prettier/plugin-ruby/issues/917) - jscheid, kddnewton - Ensure hash keys with dynamic symbols don't strip their quotes.
58
+
9
59
  ## [1.6.0] - 2021-06-23
10
60
 
11
61
  ### Added
12
62
 
13
- - [#859](https://github.com/prettier/plugin-ruby/issues/859) - azz, kddeisz - Support the `--insert-pragma` option for the incremental adoption workflow.
14
- - [#904](https://github.com/prettier/plugin-ruby/issues/904) - Hansenq, kddeisz - Support the `%s` symbol literal syntax.
15
- - [#833](https://github.com/prettier/plugin-ruby/issues/883) - kddeisz - Support for prettier >= v2.3.0.
63
+ - [#859](https://github.com/prettier/plugin-ruby/issues/859) - azz, kddnewton - Support the `--insert-pragma` option for the incremental adoption workflow.
64
+ - [#904](https://github.com/prettier/plugin-ruby/issues/904) - Hansenq, kddnewton - Support the `%s` symbol literal syntax.
65
+ - [#833](https://github.com/prettier/plugin-ruby/issues/883) - kddnewton - Support for prettier >= v2.3.0.
16
66
 
17
67
  ### Changed
18
68
 
19
- - [#854](https://github.com/prettier/plugin-ruby/issues/854) - jflinter, kddeisz - Parentheses should not be stripped from optional RBS union types.
20
- - [#888](https://github.com/prettier/plugin-ruby/issues/888) - MaxNotarangelo, kddeisz - Ensure parentheses wrap conditionals that get transformed into the modifier form when they're used within a binary node.
21
- - [#874](https://github.com/prettier/plugin-ruby/issues/874) - yratanov, kddeisz - Ensure that method calls chained onto the ends of blocks still print their arguments.
69
+ - [#854](https://github.com/prettier/plugin-ruby/issues/854) - jflinter, kddnewton - Parentheses should not be stripped from optional RBS union types.
70
+ - [#888](https://github.com/prettier/plugin-ruby/issues/888) - MaxNotarangelo, kddnewton - Ensure parentheses wrap conditionals that get transformed into the modifier form when they're used within a binary node.
71
+ - [#874](https://github.com/prettier/plugin-ruby/issues/874) - yratanov, kddnewton - Ensure that method calls chained onto the ends of blocks still print their arguments.
22
72
  - [#897](https://github.com/prettier/plugin-ruby/pull/897) - Hansenq - Reenable the `Layout/LineLength` rubocop rule in our shipped config so that line lengths for other cops are calculated correctly.
23
73
 
24
74
  ## [1.5.5] - 2021-03-25
25
75
 
26
76
  ### Changed
27
77
 
28
- - [#841](https://github.com/prettier/plugin-ruby/issues/841) - LoganBarnett, kddeisz - Better error messaging for when unix sockets are not supported by netcat.
29
- - [#844](https://github.com/prettier/plugin-ruby/issues/844) - andyw8, kddeisz - Ensure we ship all of the parsers with the prettier gem so that `rbprettier` can parse other languages as well.
30
- - [#847](https://github.com/prettier/plugin-ruby/issues/847) - jflinter, kddeisz - Ensure parentheses are present on union return types in RBS.
31
- - [#850](https://github.com/prettier/plugin-ruby/issues/850) - maethub, kddeisz - Ensure double quotes are used even when single quotes are requested for HAML attribute values.
32
- - [#849](https://github.com/prettier/plugin-ruby/issues/849) - indirect, kddeisz - Support HAML version <= 5.1 multi-line attributes.
33
- - [#810](https://github.com/prettier/plugin-ruby/issues/810) - valscion, kddeisz - Make it so that brace blocks containing heredocs have the correct end line so that they format subsequent statements correctly.
78
+ - [#841](https://github.com/prettier/plugin-ruby/issues/841) - LoganBarnett, kddnewton - Better error messaging for when unix sockets are not supported by netcat.
79
+ - [#844](https://github.com/prettier/plugin-ruby/issues/844) - andyw8, kddnewton - Ensure we ship all of the parsers with the prettier gem so that `rbprettier` can parse other languages as well.
80
+ - [#847](https://github.com/prettier/plugin-ruby/issues/847) - jflinter, kddnewton - Ensure parentheses are present on union return types in RBS.
81
+ - [#850](https://github.com/prettier/plugin-ruby/issues/850) - maethub, kddnewton - Ensure double quotes are used even when single quotes are requested for HAML attribute values.
82
+ - [#849](https://github.com/prettier/plugin-ruby/issues/849) - indirect, kddnewton - Support HAML version <= 5.1 multi-line attributes.
83
+ - [#810](https://github.com/prettier/plugin-ruby/issues/810) - valscion, kddnewton - Make it so that brace blocks containing heredocs have the correct end line so that they format subsequent statements correctly.
34
84
 
35
85
  ## [1.5.4] - 2021-03-17
36
86
 
37
87
  ### Changed
38
88
 
39
- - [#835](https://github.com/prettier/plugin-ruby/issues/835) - valscion, kddeisz - Array splat operator should not get moved by leading comments.
40
- - [#836](https://github.com/prettier/plugin-ruby/issues/836) - valscion, kddeisz - Array splat operator should not get moved by trailing comments.
41
- - [#821](https://github.com/prettier/plugin-ruby/issues/821) - jscheid, kddeisz - Better error handling when using GNU netcat.
89
+ - [#835](https://github.com/prettier/plugin-ruby/issues/835) - valscion, kddnewton - Array splat operator should not get moved by leading comments.
90
+ - [#836](https://github.com/prettier/plugin-ruby/issues/836) - valscion, kddnewton - Array splat operator should not get moved by trailing comments.
91
+ - [#821](https://github.com/prettier/plugin-ruby/issues/821) - jscheid, kddnewton - Better error handling when using GNU netcat.
42
92
 
43
93
  ## [1.5.3] - 2021-02-28
44
94
 
45
95
  ### Changed
46
96
 
47
- - [#812](https://github.com/prettier/plugin-ruby/issues/812) - valscion, kddeisz - Splats and blocks within args that have comments attached should place their respective operators in the right place.
97
+ - [#812](https://github.com/prettier/plugin-ruby/issues/812) - valscion, kddnewton - Splats and blocks within args that have comments attached should place their respective operators in the right place.
48
98
  - [#816](https://github.com/prettier/plugin-ruby/pull/816) - valscion - Document RuboCop's Style/Lambda should be disabled
49
- - [#814](https://github.com/prettier/plugin-ruby/issues/814) - jscheid, kddeisz - Provide better errors when the source location of the error is known.
99
+ - [#814](https://github.com/prettier/plugin-ruby/issues/814) - jscheid, kddnewton - Provide better errors when the source location of the error is known.
50
100
 
51
101
  ## [1.5.2] - 2021-02-03
52
102
 
53
103
  ### Changed
54
104
 
55
- - kddeisz - Fix up `binary` node comparison operators so that it will handle either Symbol literals or the `@op` nodes which are incorrectly coming from JRuby (https://github.com/jruby/jruby/issues/6548).
105
+ - kddnewton - Fix up `binary` node comparison operators so that it will handle either Symbol literals or the `@op` nodes which are incorrectly coming from JRuby (https://github.com/jruby/jruby/issues/6548).
56
106
 
57
107
  ## [1.5.1] - 2021-01-27
58
108
 
59
109
  ### Changed
60
110
 
61
- - [#799](https://github.com/prettier/plugin-ruby/issues/799) - jscheid, kddeisz - Multi-byte characters shouldn't give invalid source string bounds.
62
- - [#801](https://github.com/prettier/plugin-ruby/issues/801) - jscheid, kddeisz - When converting a conditional to the modifier form, make sure to add parentheses if there is a chained method call.
63
- - [#803](https://github.com/prettier/plugin-ruby/issues/803) - jscheid, kddeisz - Fix `formatWithCursor` support to match new parser format.
111
+ - [#799](https://github.com/prettier/plugin-ruby/issues/799) - jscheid, kddnewton - Multi-byte characters shouldn't give invalid source string bounds.
112
+ - [#801](https://github.com/prettier/plugin-ruby/issues/801) - jscheid, kddnewton - When converting a conditional to the modifier form, make sure to add parentheses if there is a chained method call.
113
+ - [#803](https://github.com/prettier/plugin-ruby/issues/803) - jscheid, kddnewton - Fix `formatWithCursor` support to match new parser format.
64
114
 
65
115
  ## [1.5.0] - 2021-01-21
66
116
 
67
117
  ### Added
68
118
 
69
- - kddeisz - Add `.rbi` as a file type that we support.
119
+ - kddnewton - Add `.rbi` as a file type that we support.
70
120
 
71
121
  ### Changed
72
122
 
73
- - [#795](https://github.com/prettier/plugin-ruby/issues/795) djrodgerspryor, kddeisz - Trailing comments attached to empty arrays should not multiply.
74
- - [#794](https://github.com/prettier/plugin-ruby/issues/794) djrodgerspryor, kddeisz - Fix embedded parser parsing by stripping common leading whitespace before passing on the content.
75
- - [#793](https://github.com/prettier/plugin-ruby/issues/793) djrodgerspryor, kddeisz - Do not include trailing commas on arguments within `arg_paren` nodes if they could not be parsed with them (`command` and `command_call`).
76
- - [#788](https://github.com/prettier/plugin-ruby/issues/788) clarkdave, kddeisz - Break child hashes within a multi-line hash regardless of whether or not they can fit on one line.
77
- - kddeisz - Stop using `;` to separate empty class definitions, module definitions, and loops.
123
+ - [#795](https://github.com/prettier/plugin-ruby/issues/795) djrodgerspryor, kddnewton - Trailing comments attached to empty arrays should not multiply.
124
+ - [#794](https://github.com/prettier/plugin-ruby/issues/794) djrodgerspryor, kddnewton - Fix embedded parser parsing by stripping common leading whitespace before passing on the content.
125
+ - [#793](https://github.com/prettier/plugin-ruby/issues/793) djrodgerspryor, kddnewton - Do not include trailing commas on arguments within `arg_paren` nodes if they could not be parsed with them (`command` and `command_call`).
126
+ - [#788](https://github.com/prettier/plugin-ruby/issues/788) clarkdave, kddnewton - Break child hashes within a multi-line hash regardless of whether or not they can fit on one line.
127
+ - kddnewton - Stop using `;` to separate empty class definitions, module definitions, and loops.
78
128
 
79
129
  ## [1.4.0] - 2021-01-15
80
130
 
81
131
  ### Added
82
132
 
83
- - ianks, kddeisz - Use `netcat` to communicate to a parser server for better performance when formatting multiple files.
133
+ - ianks, kddnewton - Use `netcat` to communicate to a parser server for better performance when formatting multiple files.
84
134
 
85
135
  ### Changed
86
136
 
87
- - jeffcarbs, kddeisz - Long strings with interpolated expressions should only break if the contents in the original source is broken.
88
- - johannesluedke, kddeisz - Fix for rescues with inline comments.
89
- - johncsnyder, kddeisz - Comments should not attach to nodes beyond a double newline.
90
- - blampe, kddeisz - Comments inside of a broken method chain get dropped.
91
- - clarkdave, kddeisz - Don't ignore Sorbet `sig` transformations.
137
+ - jeffcarbs, kddnewton - Long strings with interpolated expressions should only break if the contents in the original source is broken.
138
+ - johannesluedke, kddnewton - Fix for rescues with inline comments.
139
+ - johncsnyder, kddnewton - Comments should not attach to nodes beyond a double newline.
140
+ - blampe, kddnewton - Comments inside of a broken method chain get dropped.
141
+ - clarkdave, kddnewton - Don't ignore Sorbet `sig` transformations.
92
142
 
93
143
  ## [1.3.0] - 2021-01-05
94
144
 
95
145
  ### Added
96
146
 
97
- - kddeisz - Handling of the RBS language.
98
- - kddeisz - Incorporate the HAML plugin.
147
+ - kddnewton - Handling of the RBS language.
148
+ - kddnewton - Incorporate the HAML plugin.
99
149
 
100
150
  ## [1.2.5] - 2021-01-04
101
151
 
102
152
  ### Changed
103
153
 
104
- - nruth, kddeisz - Ensure unary operators on method calls that are sending operators get the correct scanner events.
105
- - cvoege, kddeisz - Do not add parentheses when they're not needed to non-breaking command_calls with ternary arguments.
106
- - valscion, kddeisz - Print method chains more nicely off array and hash literals.
154
+ - nruth, kddnewton - Ensure unary operators on method calls that are sending operators get the correct scanner events.
155
+ - cvoege, kddnewton - Do not add parentheses when they're not needed to non-breaking command_calls with ternary arguments.
156
+ - valscion, kddnewton - Print method chains more nicely off array and hash literals.
107
157
 
108
158
  ## [1.2.4] - 2021-01-03
109
159
 
@@ -113,102 +163,102 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/) a
113
163
 
114
164
  ### Changed
115
165
 
116
- - kddeisz - Reduce JSON size passing from Ruby process to node process by changing `char_start` -> `sc`, `char_end` -> `ec`, `start` -> `sl`, `end` -> `el`.
117
- - kddeisz - Up the max buffer size between the Ruby and node processes to 15K.
166
+ - kddnewton - Reduce JSON size passing from Ruby process to node process by changing `char_start` -> `sc`, `char_end` -> `ec`, `start` -> `sl`, `end` -> `el`.
167
+ - kddnewton - Up the max buffer size between the Ruby and node processes to 15K.
118
168
 
119
169
  ## [1.2.3] - 2021-01-02
120
170
 
121
171
  ### Changed
122
172
 
123
- - lukyth, kddeisz - Ensure if a ternary breaks into an `if..else..end` within a `command_call` node that parentheses are added.
124
- - AlanFoster, kddeisz - Ensure you consume the optional `do` keyword on `while` and `until` loops so that it doesn't confuse the parser.
125
- - AlanFoster, kddeisz - Ensure key-value pairs split on line when the key has a comment attached within a hash.
126
- - AlanFoster, kddeisz - Fix for `for` loops that have multiple index variables.
127
- - AlanFoster, kddeisz - Fix parsing very large files by reducing the size of the JSON output from the parser.
128
- - AlanFoster, kddeisz - Ensure you don't skip parentheses if you're returning a value with the `not` unary operator.
173
+ - lukyth, kddnewton - Ensure if a ternary breaks into an `if..else..end` within a `command_call` node that parentheses are added.
174
+ - AlanFoster, kddnewton - Ensure you consume the optional `do` keyword on `while` and `until` loops so that it doesn't confuse the parser.
175
+ - AlanFoster, kddnewton - Ensure key-value pairs split on line when the key has a comment attached within a hash.
176
+ - AlanFoster, kddnewton - Fix for `for` loops that have multiple index variables.
177
+ - AlanFoster, kddnewton - Fix parsing very large files by reducing the size of the JSON output from the parser.
178
+ - AlanFoster, kddnewton - Ensure you don't skip parentheses if you're returning a value with the `not` unary operator.
129
179
 
130
180
  ## [1.2.2] - 2021-01-01
131
181
 
132
182
  ### Changed
133
183
 
134
184
  - nathan-beam - Gem does not work with CMD/Powershell.
135
- - blampe, kddeisz - Comments inside keyword parameters in method declarations are not printed.
136
- - blampe, kddeisz - `command_call` nodes with unary operators incorrectly parse their operator.
137
- - blampe, kddeisz - Returning multiple values where the first has parentheses was incorrectly removing the remaining values.
138
- - johncsnyder, kddeisz - Call chains whose left-most receiver is a no-indent expression should not indent their entire chain.
185
+ - blampe, kddnewton - Comments inside keyword parameters in method declarations are not printed.
186
+ - blampe, kddnewton - `command_call` nodes with unary operators incorrectly parse their operator.
187
+ - blampe, kddnewton - Returning multiple values where the first has parentheses was incorrectly removing the remaining values.
188
+ - johncsnyder, kddnewton - Call chains whose left-most receiver is a no-indent expression should not indent their entire chain.
139
189
 
140
190
  ## [1.2.1] - 2020-12-27
141
191
 
142
192
  ### Changed
143
193
 
144
- - kddeisz - Handle single-line method definitions with parameters.
145
- - kddeisz - Handle hash and array patterns nested within find patterns.
146
- - kddeisz - Handle rightward assignment.
147
- - kddeisz - Handle find patterns with named boundaries.
148
- - kddeisz - Handle rightward assignment in conditionals.
194
+ - kddnewton - Handle single-line method definitions with parameters.
195
+ - kddnewton - Handle hash and array patterns nested within find patterns.
196
+ - kddnewton - Handle rightward assignment.
197
+ - kddnewton - Handle find patterns with named boundaries.
198
+ - kddnewton - Handle rightward assignment in conditionals.
149
199
 
150
200
  ## [1.2.0] - 2020-12-26
151
201
 
152
202
  ### Added
153
203
 
154
- - kddeisz - Support for the `fndptn` node for Ruby 3.0 pattern matching.
155
- - kddeisz - Support for Ruby 3.0+ single-line method definitions.
204
+ - kddnewton - Support for the `fndptn` node for Ruby 3.0 pattern matching.
205
+ - kddnewton - Support for Ruby 3.0+ single-line method definitions.
156
206
 
157
207
  ## [1.1.0] - 2020-12-20
158
208
 
159
209
  ### Added
160
210
 
161
- - kddeisz - Now that the comments are all fixed up, we can support `# prettier-ignore` comments.
211
+ - kddnewton - Now that the comments are all fixed up, we can support `# prettier-ignore` comments.
162
212
 
163
213
  ### Changed
164
214
 
165
- - rindek, kddeisz - Do not remove parentheses when receiver looks like a constant.
166
- - rindek, kddeisz - Do not remove parentheses when using the special `call` syntax with no arguments.
215
+ - rindek, kddnewton - Do not remove parentheses when receiver looks like a constant.
216
+ - rindek, kddnewton - Do not remove parentheses when using the special `call` syntax with no arguments.
167
217
  - ykpythemind - Do not change regexp bounds if the body has certain content.
168
- - karanmandal, kddeisz - Correctly print for loops.
169
- - rafbm, kddeisz - If there are method chains with arguments only at the end, we should group the method chain and the method args.
218
+ - karanmandal, kddnewton - Correctly print for loops.
219
+ - rafbm, kddnewton - If there are method chains with arguments only at the end, we should group the method chain and the method args.
170
220
 
171
221
  ## [1.0.1] - 2020-12-12
172
222
 
173
223
  ### Changed
174
224
 
175
- - steobrien, kddeisz - Ensure leading comments in empty array and hash literals do not duplicate.
225
+ - steobrien, kddnewton - Ensure leading comments in empty array and hash literals do not duplicate.
176
226
 
177
227
  ## [1.0.0] - 2020-12-11
178
228
 
179
229
  ### Changed
180
230
 
181
- - kddeisz - Do not unescape double quotes in a single quote string.
182
- - kddeisz - Only force braces on regexp for spaces and equals if it's inside a command or command_call.
183
- - kddeisz - Leave Sorbet type annotations in place.
184
- - kddeisz - Don't group hash contents, just allow them to break with their parent node.
185
- - kddeisz - Honor the UTF-8 lang passed in through ENV vars.
231
+ - kddnewton - Do not unescape double quotes in a single quote string.
232
+ - kddnewton - Only force braces on regexp for spaces and equals if it's inside a command or command_call.
233
+ - kddnewton - Leave Sorbet type annotations in place.
234
+ - kddnewton - Don't group hash contents, just allow them to break with their parent node.
235
+ - kddnewton - Honor the UTF-8 lang passed in through ENV vars.
186
236
 
187
237
  ## [1.0.0-rc2] - 2020-12-10
188
238
 
189
239
  ### Changed
190
240
 
191
- - kddeisz - Print hashes with consistent keys (e.g., if one key cannot be a hash label, use all hash rockets).
192
- - kddeisz - Respect using `o` or not using `o` for octal numbers.
193
- - kddeisz - Ensure `when` clauses with multiple predicates that can be split into multiple lines are split correctly.
194
- - kddeisz - Ensure hash literal is split correctly when only its contents would fit on one line.
195
- - kddeisz - Simplify `toProc` checks by not calling if the option is disabled.
196
- - johncsnyder, kddeisz - Add `method_add_block` to the potential like of method calls that can be chained.
197
- - kddeisz - Add the `rubyArrayLiteral` option for disabling automatically turning into array literals.
241
+ - kddnewton - Print hashes with consistent keys (e.g., if one key cannot be a hash label, use all hash rockets).
242
+ - kddnewton - Respect using `o` or not using `o` for octal numbers.
243
+ - kddnewton - Ensure `when` clauses with multiple predicates that can be split into multiple lines are split correctly.
244
+ - kddnewton - Ensure hash literal is split correctly when only its contents would fit on one line.
245
+ - kddnewton - Simplify `toProc` checks by not calling if the option is disabled.
246
+ - johncsnyder, kddnewton - Add `method_add_block` to the potential like of method calls that can be chained.
247
+ - kddnewton - Add the `rubyArrayLiteral` option for disabling automatically turning into array literals.
198
248
 
199
249
  ## [1.0.0-rc1] - 2020-12-09
200
250
 
201
251
  ### Changed
202
252
 
203
- - kddeisz - Rename options to prep for v1.0 release.
253
+ - kddnewton - Rename options to prep for v1.0 release.
204
254
  - `addTrailingCommas` -> `trailingComma`, `"es5"` means `true`
205
255
  - `inlineConditionals` and `inlineLoops` -> `rubyModifier`
206
256
  - `preferHashLabels` -> `rubyHashLabel`
207
257
  - `preferSingleQuotes` -> `rubySingleQuote`
208
258
  - `toProcTransform` -> `rubyToProc`
209
- - andyw8, kddeisz - Fix for Ruby `2.5.1` dyna_symbols. Turns out they were previously incorrectly reported as `xstring` nodes.
210
- - andyw8, kddeisz - Fix for plain `rescue` nodes with only comments in the body.
211
- - andyw8, kddeisz - Move declaration-type comments up to the line in the original source, as in:
259
+ - andyw8, kddnewton - Fix for Ruby `2.5.1` dyna_symbols. Turns out they were previously incorrectly reported as `xstring` nodes.
260
+ - andyw8, kddnewton - Fix for plain `rescue` nodes with only comments in the body.
261
+ - andyw8, kddnewton - Move declaration-type comments up to the line in the original source, as in:
212
262
 
213
263
  ```ruby
214
264
  def foo # :nodoc:
@@ -219,11 +269,11 @@ end
219
269
  The comment in the above example should stay in place.
220
270
 
221
271
  - janklimo - Respect special call syntax, e.g., `a.(1, 2, 3)` should remain the same.
222
- - kddeisz - Fix up a bug with `ensure` being used in a `bodystmt` and not a `begin`.
223
- - kddeisz - Fix up a bug with negative ranges, e.g., `-4..-3`.
224
- - kddeisz - Fix up a bug with operator aliases, e.g., `alias << push`.
225
- - kddeisz - Fix up a bug with calls and unary nodes, e.g., `!!foo&.bar`.
226
- - kddeisz - Fix up a bug with multiple rescue clauses and comments, e.g.,
272
+ - kddnewton - Fix up a bug with `ensure` being used in a `bodystmt` and not a `begin`.
273
+ - kddnewton - Fix up a bug with negative ranges, e.g., `-4..-3`.
274
+ - kddnewton - Fix up a bug with operator aliases, e.g., `alias << push`.
275
+ - kddnewton - Fix up a bug with calls and unary nodes, e.g., `!!foo&.bar`.
276
+ - kddnewton - Fix up a bug with multiple rescue clauses and comments, e.g.,
227
277
 
228
278
  ```ruby
229
279
  begin
@@ -233,64 +283,64 @@ rescue Foo, Bar
233
283
  end
234
284
  ```
235
285
 
236
- - kddeisz - Handle string literals that start with `%Q`.
237
- - kddeisz - Handle question method methods in the predicate of an if with a comment in the body.
238
- - kddeisz - Fix bare `break` with comments immediately after.
239
- - kddeisz - Fix for heredocs with comments immediately after the declaration.
240
- - kddeisz - Fix for comments when you're defining a method whose name overlaps with a keyword.
241
- - kddeisz - Don't automatically indent inside interpolated expressions from within a heredoc.
242
- - kddeisz - Don't convert into string literal arrays if the elements have brackets.
243
- - kddeisz - Ensure you break the parent when there is an assignment in the predicate of a loop.
244
- - kddeisz - Fix up a bug with keyword aliases, e.g., `alias in within`.
245
- - kddeisz - Force using braces for regex if a regex starts with a blank space.
246
- - kddeisz - Force using braces for regex if a regex starts with an equals sign.
247
- - kddeisz - Fix up a bug with constant aliases, e.g., `alias in IN`.
248
- - andyw8, kddeisz - Ensure `rescue` comments stay on the same line as their declaration.
286
+ - kddnewton - Handle string literals that start with `%Q`.
287
+ - kddnewton - Handle question method methods in the predicate of an if with a comment in the body.
288
+ - kddnewton - Fix bare `break` with comments immediately after.
289
+ - kddnewton - Fix for heredocs with comments immediately after the declaration.
290
+ - kddnewton - Fix for comments when you're defining a method whose name overlaps with a keyword.
291
+ - kddnewton - Don't automatically indent inside interpolated expressions from within a heredoc.
292
+ - kddnewton - Don't convert into string literal arrays if the elements have brackets.
293
+ - kddnewton - Ensure you break the parent when there is an assignment in the predicate of a loop.
294
+ - kddnewton - Fix up a bug with keyword aliases, e.g., `alias in within`.
295
+ - kddnewton - Force using braces for regex if a regex starts with a blank space.
296
+ - kddnewton - Force using braces for regex if a regex starts with an equals sign.
297
+ - kddnewton - Fix up a bug with constant aliases, e.g., `alias in IN`.
298
+ - andyw8, kddnewton - Ensure `rescue` comments stay on the same line as their declaration.
249
299
 
250
300
  ## [0.22.0] - 2020-12-08
251
301
 
252
302
  ### Changed
253
303
 
254
304
  - flyerhzm - Print method chains by one indentation.
255
- - mmcnl, kddeisz - Handle heredocs and blocks being passed to the same method.
256
- - johncsnyder, kddeisz - Ensure correct formatting when breaking up conditionals with `inlineConditionals: false`.
305
+ - mmcnl, kddnewton - Handle heredocs and blocks being passed to the same method.
306
+ - johncsnyder, kddnewton - Ensure correct formatting when breaking up conditionals with `inlineConditionals: false`.
257
307
  - Rsullivan00 - Ensure that when ternaries as command arguments get broken into multiple lines we add the necessary parentheses.
258
308
  - jbielick - Maintain parse order during if/unless modifier expressions
259
309
  - flyerhzm - Slight prettifying of wrapped args if doc length is under a certain value.
260
- - github0013, kddeisz - Ensure `not` keeps parentheses if they are being used.
310
+ - github0013, kddnewton - Ensure `not` keeps parentheses if they are being used.
261
311
  - jbielick - Print heredocs consistently.
262
- - kddeisz - Completely revamp the way we handle comments.
263
- - kddeisz - Support `hshptn` and the remaining missing pattern matching syntax.
312
+ - kddnewton - Completely revamp the way we handle comments.
313
+ - kddnewton - Support `hshptn` and the remaining missing pattern matching syntax.
264
314
 
265
315
  ## [0.21.0] - 2020-12-02
266
316
 
267
317
  ### Changed
268
318
 
269
- - kddeisz, ryan-hunter-pc - Explicitly handle `break` and `next` keyword parentheses.
270
- - jbielick, kddeisz - Don't convert between `lambda {}` and `-> {}`. Technically it's breaking the semantics of the program. Also because lambda method call arguments can't handle everything that stabby lambda can.
271
- - kddeisz - Turn off the `Symbol#to_proc` transform by default.
272
- - janklimo, kddeisz - Properly handle trailing commas on hash arguments.
273
- - coiti, kddeisz - Properly handle parentheses when necessary on if/unless statements and while/until loops.
319
+ - kddnewton, ryan-hunter-pc - Explicitly handle `break` and `next` keyword parentheses.
320
+ - jbielick, kddnewton - Don't convert between `lambda {}` and `-> {}`. Technically it's breaking the semantics of the program. Also because lambda method call arguments can't handle everything that stabby lambda can.
321
+ - kddnewton - Turn off the `Symbol#to_proc` transform by default.
322
+ - janklimo, kddnewton - Properly handle trailing commas on hash arguments.
323
+ - coiti, kddnewton - Properly handle parentheses when necessary on if/unless statements and while/until loops.
274
324
  - Rsullivan00 - Prevent `command` and `command_call` nodes from being turned into ternaries.
275
- - kddeisz - Better handling of the `alias` node with and without comments.
276
- - kddeisz - Better handling of the `BEGIN` and `END` nodes with and without comments.
277
- - kddeisz - Much better handling of heredocs where now there is a consistent `heredoc` node instead of multiple.
325
+ - kddnewton - Better handling of the `alias` node with and without comments.
326
+ - kddnewton - Better handling of the `BEGIN` and `END` nodes with and without comments.
327
+ - kddnewton - Much better handling of heredocs where now there is a consistent `heredoc` node instead of multiple.
278
328
 
279
329
  ## [0.20.1] - 2020-09-04
280
330
 
281
331
  ### Changed
282
332
 
283
- - ftes, kddeisz - Properly escape HAML plain text statements that start with special HAML characters.
333
+ - ftes, kddnewton - Properly escape HAML plain text statements that start with special HAML characters.
284
334
 
285
335
  ### Removed
286
336
 
287
- - kddeisz - I'm stripping out the HAML plugin and putting it into its own package (`@prettier/plugin-haml`). It's become too difficult to maintain within this repo, and it's confusing for contributors because there are some things that work with Ruby and some things that don't. This is going to simplify maintenance. This should probably be a major version bump but since we're still pre `1.0` I'm going to leave it as a patch.
337
+ - kddnewton - I'm stripping out the HAML plugin and putting it into its own package (`@prettier/plugin-haml`). It's become too difficult to maintain within this repo, and it's confusing for contributors because there are some things that work with Ruby and some things that don't. This is going to simplify maintenance. This should probably be a major version bump but since we're still pre `1.0` I'm going to leave it as a patch.
288
338
 
289
339
  ## [0.20.0] - 2020-08-28
290
340
 
291
341
  ### Added
292
342
 
293
- - kddeisz - Allow embedded formatting on heredocs by the name placed at the start. For example,
343
+ - kddnewton - Allow embedded formatting on heredocs by the name placed at the start. For example,
294
344
 
295
345
  <!-- prettier-ignore -->
296
346
  ```ruby
@@ -310,30 +360,30 @@ JAVASCRIPT
310
360
  ### Changed
311
361
 
312
362
  - Rsullivan00 - Do not tranform word-literal arrays when there is an escape sequence.
313
- - steobrien, kddeisz - Do not indent heredocs with calls more than they should be.
363
+ - steobrien, kddnewton - Do not indent heredocs with calls more than they should be.
314
364
  - jpickwell - Include .simplecov in filenames
315
- - github0013, kddeisz - Ensure we're parsing ruby files using UTF-8 regardless of the system encoding.
365
+ - github0013, kddnewton - Ensure we're parsing ruby files using UTF-8 regardless of the system encoding.
316
366
 
317
367
  ## [0.19.0] - 2020-07-03
318
368
 
319
369
  ### Added
320
370
 
321
371
  - ryan-hunter-pc - Add the option to disable the `Symbol#to_proc` transform.
322
- - ryan-hunter-pc], [@SViccari, kddeisz - Disable `Symbol#to_proc` transform when used as a key inside of a hash where the key is either `:if` or `:unless`.
372
+ - ryan-hunter-pc], [@SViccari, kddnewton - Disable `Symbol#to_proc` transform when used as a key inside of a hash where the key is either `:if` or `:unless`.
323
373
 
324
374
  ## [0.18.2] - 2020-05-01
325
375
 
326
376
  ### Changed
327
377
 
328
378
  - alse - Support `vscodeLanguageIds` for HAML.
329
- - ShayDavidson, kddeisz - Don't allow replacing if/else with ternary if there's an assignment in the predicate.
379
+ - ShayDavidson, kddnewton - Don't allow replacing if/else with ternary if there's an assignment in the predicate.
330
380
  - janklimo - Do not add an empty line after `rescue` when the block is empty.
331
381
 
332
382
  ## [0.18.1] - 2020-04-05
333
383
 
334
384
  ### Changed
335
385
 
336
- - petevk, kddeisz - Use braces for block format iff it was originally a brace block, otherwise you could be changing precedence. For example:
386
+ - petevk, kddnewton - Use braces for block format iff it was originally a brace block, otherwise you could be changing precedence. For example:
337
387
 
338
388
  <!-- prettier-ignore -->
339
389
  ```ruby
@@ -357,10 +407,10 @@ should maintain its `do...end` and not switch to inline braces otherwise the bra
357
407
  [1]
358
408
  ```
359
409
 
360
- - ftes, kddeisz - When old-form dynamic attributes are added to a `div` tag in HAML, it was previously skipping printing the `%div`, which led to it being incorrectly displayed.
361
- - ftes, kddeisz - Previously if you had a long tag declaration with attributes that made it hit the line limit, then the content of the tag would be pushed to the next line but indented one character too many.
362
- - ftes, kddeisz - Don't explicitly require JSON if it has already been loaded, as this can lead to rubygems activation errors.
363
- - mmainz, kddeisz - Handle heredocs as the receivers of call nodes, as in:
410
+ - ftes, kddnewton - When old-form dynamic attributes are added to a `div` tag in HAML, it was previously skipping printing the `%div`, which led to it being incorrectly displayed.
411
+ - ftes, kddnewton - Previously if you had a long tag declaration with attributes that made it hit the line limit, then the content of the tag would be pushed to the next line but indented one character too many.
412
+ - ftes, kddnewton - Don't explicitly require JSON if it has already been loaded, as this can lead to rubygems activation errors.
413
+ - mmainz, kddnewton - Handle heredocs as the receivers of call nodes, as in:
364
414
 
365
415
  <!-- prettier-ignore -->
366
416
  ```ruby
@@ -369,7 +419,7 @@ foo = <<~TEXT.strip
369
419
  TEXT
370
420
  ```
371
421
 
372
- - github0013, kddeisz - Leave parentheses in place if the value of a return node contains a binary with low operator precedence, as in:
422
+ - github0013, kddnewton - Leave parentheses in place if the value of a return node contains a binary with low operator precedence, as in:
373
423
 
374
424
  <!-- prettier-ignore -->
375
425
  ```ruby
@@ -380,13 +430,13 @@ return (a or b) if c?
380
430
 
381
431
  ### Added
382
432
 
383
- - kddeisz - Support for the `nokw_param` node for specifying when methods should no accept keywords, as in:
433
+ - kddnewton - Support for the `nokw_param` node for specifying when methods should no accept keywords, as in:
384
434
 
385
435
  ```ruby
386
436
  def foo(**nil); end
387
437
  ```
388
438
 
389
- - kddeisz - Support for the `args_forward` node for forwarding all types of arguments, as in:
439
+ - kddnewton - Support for the `args_forward` node for forwarding all types of arguments, as in:
390
440
 
391
441
  ```ruby
392
442
  def foo(...)
@@ -396,13 +446,13 @@ end
396
446
 
397
447
  ### Changed
398
448
 
399
- - ftes, kddeisz - Handled 3 or more classes on a node in HAML, as in:
449
+ - ftes, kddnewton - Handled 3 or more classes on a node in HAML, as in:
400
450
 
401
451
  ```haml
402
452
  %table.table.is-striped.is-hoverable
403
453
  ```
404
454
 
405
- - ftes, kddeisz - Better handling of indentation of `if/elsif/else`, `unless/elsif/else`, and `case/when` branches, as in:
455
+ - ftes, kddnewton - Better handling of indentation of `if/elsif/else`, `unless/elsif/else`, and `case/when` branches, as in:
406
456
 
407
457
  ```haml
408
458
  .column.is-12
@@ -435,7 +485,7 @@ Config::Download.new(
435
485
  ).perform
436
486
  ```
437
487
 
438
- - pje, kddeisz - Method definition bodies (on `defs` nodes) should dedent if a helper method is called. As in:
488
+ - pje, kddnewton - Method definition bodies (on `defs` nodes) should dedent if a helper method is called. As in:
439
489
 
440
490
  <!-- prettier-ignore -->
441
491
  ```ruby
@@ -453,7 +503,7 @@ private def self.foo
453
503
  end
454
504
  ```
455
505
 
456
- - masqita, kddeisz - Inline variable assignment within a predicate should force the conditional to break, as in:
506
+ - masqita, kddnewton - Inline variable assignment within a predicate should force the conditional to break, as in:
457
507
 
458
508
  ```ruby
459
509
  array.each do |element|
@@ -463,16 +513,16 @@ array.each do |element|
463
513
  end
464
514
  ```
465
515
 
466
- - hafley66, kddeisz - Handle empty `while` and `until` blocks.
467
- - Fruetel, kddeisz - Simplify string escape pattern by locking on any escape sequence.
468
- - flyerhzm, kddeisz - Properly handle string quotes on symbols in hash keys.
516
+ - hafley66, kddnewton - Handle empty `while` and `until` blocks.
517
+ - Fruetel, kddnewton - Simplify string escape pattern by locking on any escape sequence.
518
+ - flyerhzm, kddnewton - Properly handle string quotes on symbols in hash keys.
469
519
 
470
520
  ## [0.17.0] - 2019-12-12
471
521
 
472
522
  ### Added
473
523
 
474
524
  - matt-wratt - Better support for explicit `return` nodes with empty arrays or arrays with a single element.
475
- - jrdioko, kddeisz - Alignment of `not_to` is explicitly allowed to not indent to better support rspec.
525
+ - jrdioko, kddnewton - Alignment of `not_to` is explicitly allowed to not indent to better support rspec.
476
526
 
477
527
  ### Changed
478
528
 
@@ -482,7 +532,7 @@ end
482
532
 
483
533
  ### Added
484
534
 
485
- - mmainz, kddeisz - Support for extra commas in multiple assignment, as it changes the meaning. For example,
535
+ - mmainz, kddnewton - Support for extra commas in multiple assignment, as it changes the meaning. For example,
486
536
 
487
537
  <!-- prettier-ignore -->
488
538
  ```ruby
@@ -491,12 +541,12 @@ a, = [1, 2, 3]
491
541
 
492
542
  would previously get printed as `a = [1, 2, 3]`, which changes the value of `a` from `1` to the value of the entire array.
493
543
 
494
- - kddeisz - Experimental support for the HAMtemplate language.
544
+ - kddnewton - Experimental support for the HAMtemplate language.
495
545
 
496
546
  ### Changed
497
547
 
498
- - github0013, kddeisz - Support proper string escaping when the original string in the source is wrapped in `%q|...|`. For example, `%q|\'|` should get printed as `"\'"`, where previously it was dropping the backslash.
499
- - jamescostian, kddeisz - Force ternary breaking when using the lower-precendence operators `and` and `or`. For example,
548
+ - github0013, kddnewton - Support proper string escaping when the original string in the source is wrapped in `%q|...|`. For example, `%q|\'|` should get printed as `"\'"`, where previously it was dropping the backslash.
549
+ - jamescostian, kddnewton - Force ternary breaking when using the lower-precendence operators `and` and `or`. For example,
500
550
 
501
551
  <!-- prettier-ignore -->
502
552
  ```ruby
@@ -509,7 +559,7 @@ end
509
559
 
510
560
  the previous expression was being transformed into a ternary which was invalid ruby. Instead it now stays broken out into an if/else block.
511
561
 
512
- - localhostdotdev], [@joeyjoejoejr], [@eins78, kddeisz - Better support for embedded expressions inside heredocs. For example,
562
+ - localhostdotdev], [@joeyjoejoejr], [@eins78, kddnewton - Better support for embedded expressions inside heredocs. For example,
513
563
 
514
564
  <!-- prettier-ignore -->
515
565
  ```ruby
@@ -522,14 +572,14 @@ HERE
522
572
 
523
573
  should remain formatted as it is. Whereas previously due to the way the lines were split, you would sometimes end up with it breaking after `#{`.
524
574
 
525
- - jamescostian, kddeisz - Fix up `return` node printing. When returning multiple values, you need to return an array literal as opposed to using parentheses.
575
+ - jamescostian, kddnewton - Fix up `return` node printing. When returning multiple values, you need to return an array literal as opposed to using parentheses.
526
576
 
527
577
  ## [0.15.1] - 2019-11-05
528
578
 
529
579
  ### Changed
530
580
 
531
581
  - AlanFoster - Add `bin/lex` for viewing the tokenized result of Ripper on Ruby code.
532
- - jakeprime, kddeisz - When predicates from within an `if`, `unless`, `while`, or `until` loop break the line, they should be aligned together. For example,
582
+ - jakeprime, kddnewton - When predicates from within an `if`, `unless`, `while`, or `until` loop break the line, they should be aligned together. For example,
533
583
 
534
584
  <!-- prettier-ignore -->
535
585
  ```ruby
@@ -556,7 +606,7 @@ if foo?
556
606
  end
557
607
  ```
558
608
 
559
- - mmainz, kddeisz - Hash keys are not converted to keyword syntax if they would make invalid symbols. For example,
609
+ - mmainz, kddnewton - Hash keys are not converted to keyword syntax if they would make invalid symbols. For example,
560
610
 
561
611
  <!-- prettier-ignore -->
562
612
  ```ruby
@@ -565,9 +615,9 @@ end
565
615
 
566
616
  cannot be translated into `[]:` as that is an invalid symbol. Instead, it stays with the hash rocket syntax.
567
617
 
568
- - cldevs, kddeisz - Do not attempt to format the insides of xstring literals (string that get sent to the command line surrounded by backticks or `%x`).
569
- - cldevs, kddeisz - When predicates for `if`, `unless`, `while`, or `until` nodes contain an assignment, we can't know for sure that it doesn't modify the body. In this case we need to always break and form a multi-line block.
570
- - MarcManiez, kddeisz - When the return value of `if`, `unless`, `while`, or `until` nodes are assigned to anything other than a local variable, we need to wrap them in parentheses if we're changing to the modifier form. This is because the following expressions have different semantic meaning:
618
+ - cldevs, kddnewton - Do not attempt to format the insides of xstring literals (string that get sent to the command line surrounded by backticks or `%x`).
619
+ - cldevs, kddnewton - When predicates for `if`, `unless`, `while`, or `until` nodes contain an assignment, we can't know for sure that it doesn't modify the body. In this case we need to always break and form a multi-line block.
620
+ - MarcManiez, kddnewton - When the return value of `if`, `unless`, `while`, or `until` nodes are assigned to anything other than a local variable, we need to wrap them in parentheses if we're changing to the modifier form. This is because the following expressions have different semantic meaning:
571
621
 
572
622
  <!-- prettier-ignore -->
573
623
  ```ruby
@@ -590,8 +640,8 @@ That will guarantee that the expressions are equivalent.
590
640
 
591
641
  ### Changed
592
642
 
593
- - dudeofawesome, kddeisz - If xstring literals (command line calls surrounded by backticks) break, then we indent and place the command on a new line. Previously, this was resulting in new lines getting added each time the code was formatted. Now this happens correctly.
594
- - krachtstefan, kddeisz - When a `while` or `until` loop modifies a `begin...end` statement, it must remain in the modifier form or else it changes sematic meaning. For example,
643
+ - dudeofawesome, kddnewton - If xstring literals (command line calls surrounded by backticks) break, then we indent and place the command on a new line. Previously, this was resulting in new lines getting added each time the code was formatted. Now this happens correctly.
644
+ - krachtstefan, kddnewton - When a `while` or `until` loop modifies a `begin...end` statement, it must remain in the modifier form or else it changes sematic meaning. For example,
595
645
 
596
646
  <!-- prettier-ignore -->
597
647
  ```ruby
@@ -611,8 +661,8 @@ end
611
661
 
612
662
  because that would never execute `foo` if `bar` is falsy, whereas in the initial example it would have.
613
663
 
614
- - jviney], kddeisz - When transforming a block into the `Symbol#to_proc` syntax from within a list of arguments inside of an `aref` node (i.e., `foo[:bar.each`), we can't put the block syntax inside the brackets.
615
- - jakeprime, kddeisz - Values for the `return` keyword that broke the line were previously just printed as they were, which breaks if you have a block expression like an `if` or `while`. For example,
664
+ - jviney], kddnewton - When transforming a block into the `Symbol#to_proc` syntax from within a list of arguments inside of an `aref` node (i.e., `foo[:bar.each`), we can't put the block syntax inside the brackets.
665
+ - jakeprime, kddnewton - Values for the `return` keyword that broke the line were previously just printed as they were, which breaks if you have a block expression like an `if` or `while`. For example,
616
666
 
617
667
  <!-- prettier-ignore -->
618
668
  ```ruby
@@ -643,7 +693,7 @@ return(
643
693
  )
644
694
  ```
645
695
 
646
- - jakeprime, kddeisz - When switching from a double-quoted string to a single-quoted string that contained escaped double quotes, the backslashes would stay in the string. As in:
696
+ - jakeprime, kddnewton - When switching from a double-quoted string to a single-quoted string that contained escaped double quotes, the backslashes would stay in the string. As in:
647
697
 
648
698
  <!-- prettier-ignore -->
649
699
  ```ruby
@@ -668,11 +718,11 @@ but now gets formatted as:
668
718
 
669
719
  ### Added
670
720
 
671
- - kddeisz - Support for pattern matching for variables and array patterns. Currently waiting on Ripper support for hash patterns. For examples, check out the [test/js/patterns.test.js](test/js/patterns.test.js) file.
721
+ - kddnewton - Support for pattern matching for variables and array patterns. Currently waiting on Ripper support for hash patterns. For examples, check out the [test/js/patterns.test.js](test/js/patterns.test.js) file.
672
722
 
673
723
  ### Changed
674
724
 
675
- - jviney, kddeisz - if/else blocks that had method calls on the end of them that were also transformed into ternaries need to have parens added to them. For example,
725
+ - jviney, kddnewton - if/else blocks that had method calls on the end of them that were also transformed into ternaries need to have parens added to them. For example,
676
726
 
677
727
  <!-- prettier-ignore -->
678
728
  ```ruby
@@ -690,8 +740,8 @@ now correctly gets transformed into:
690
740
  (foo ? 1 : 2).to_s
691
741
  ```
692
742
 
693
- - acrewdson, kddeisz - Fixed a bug where multiple newlines at the end of the file would cause a crash.
694
- - jviney, kddeisz - If a variable is assigned inside of the predicate of a conditional, then we can't change it into the single-line version as this breaks. For example,
743
+ - acrewdson, kddnewton - Fixed a bug where multiple newlines at the end of the file would cause a crash.
744
+ - jviney, kddnewton - If a variable is assigned inside of the predicate of a conditional, then we can't change it into the single-line version as this breaks. For example,
695
745
 
696
746
  <!-- prettier-ignore -->
697
747
  ```ruby
@@ -706,11 +756,11 @@ must stay the same.
706
756
 
707
757
  ### Added
708
758
 
709
- - kddeisz - Added `locStart` and `locEnd` functions to support `--cursor-offset`.
759
+ - kddnewton - Added `locStart` and `locEnd` functions to support `--cursor-offset`.
710
760
 
711
761
  ### Changed
712
762
 
713
- - xipgroc, kddeisz - Comments inside of `do...end` blocks that preceeded `call` nodes were associating the comment with the `var_ref` instead of the `call` itself. For example,
763
+ - xipgroc, kddnewton - Comments inside of `do...end` blocks that preceeded `call` nodes were associating the comment with the `var_ref` instead of the `call` itself. For example,
714
764
 
715
765
  <!-- prettier-ignore -->
716
766
  ```ruby
@@ -735,7 +785,7 @@ end
735
785
 
736
786
  but now gets printed correctly.
737
787
 
738
- - petevk, kddeisz - Double splats inside a hash were previously failing to print. For example,
788
+ - petevk, kddnewton - Double splats inside a hash were previously failing to print. For example,
739
789
 
740
790
  <!-- prettier-ignore -->
741
791
  ```ruby
@@ -748,12 +798,12 @@ would fail to print, but now works.
748
798
 
749
799
  ### Changed
750
800
 
751
- - kddeisz - Move arg, assign, constant, flow, massign, operator, scope, and statement nodes into their own files.
752
- - kddeisz - Move `@int`, `access_ctrl`, `assocsplat`, `block_var`, `else`, `number_arg`, `super`, `undef`, `var_ref`, and `var_ref` as well as various call and symbol nodes into appropriate files.
753
- - kddeisz - Better support for excessed commas in block args. Previously `proc { |x,| }` would add an extra space, but now it does not.
754
- - kddeisz - Add a lot more documentation to the parser.
755
- - glejeune, kddeisz - Previously, the unary `not` operator inside a ternary (e.g., `a ? not(b) : c`) would break because it wouldn't add parentheses, but now it adds them.
756
- - kddeisz - `if` and `unless` nodes used to not be able to handle if a comment was the only statement in the body. For example,
801
+ - kddnewton - Move arg, assign, constant, flow, massign, operator, scope, and statement nodes into their own files.
802
+ - kddnewton - Move `@int`, `access_ctrl`, `assocsplat`, `block_var`, `else`, `number_arg`, `super`, `undef`, `var_ref`, and `var_ref` as well as various call and symbol nodes into appropriate files.
803
+ - kddnewton - Better support for excessed commas in block args. Previously `proc { |x,| }` would add an extra space, but now it does not.
804
+ - kddnewton - Add a lot more documentation to the parser.
805
+ - glejeune, kddnewton - Previously, the unary `not` operator inside a ternary (e.g., `a ? not(b) : c`) would break because it wouldn't add parentheses, but now it adds them.
806
+ - kddnewton - `if` and `unless` nodes used to not be able to handle if a comment was the only statement in the body. For example,
757
807
 
758
808
  <!-- prettier-ignore -->
759
809
  ```ruby
@@ -771,7 +821,7 @@ would get printed as
771
821
 
772
822
  Now the `if` and `unless` printers check for the presence of single comments.
773
823
 
774
- - JoshuaKGoldberg, kddeisz - Fixes an error where `command` nodes within `def` nodes would fail to format if it was only a single block argument. For example,
824
+ - JoshuaKGoldberg, kddnewton - Fixes an error where `command` nodes within `def` nodes would fail to format if it was only a single block argument. For example,
775
825
 
776
826
  <!-- prettier-ignore -->
777
827
  ```ruby
@@ -782,7 +832,7 @@ end
782
832
 
783
833
  would fail, but now works.
784
834
 
785
- - xipgroc, kddeisz - Comments on lines with array references were previously deleting the array references entirely. For example,
835
+ - xipgroc, kddnewton - Comments on lines with array references were previously deleting the array references entirely. For example,
786
836
 
787
837
  <!-- prettier-ignore -->
788
838
  ```ruby
@@ -795,323 +845,323 @@ would previously result in `array[]`, but now prints properly.
795
845
 
796
846
  ### Changed
797
847
 
798
- - kddeisz - When symbol literal hash keys end with `=`, they cannot be transformed into hash labels.
799
- - xipgroc, kddeisz - Fixed when blocks on methods with no arguments are transformed into `to_proc` syntax.
848
+ - kddnewton - When symbol literal hash keys end with `=`, they cannot be transformed into hash labels.
849
+ - xipgroc, kddnewton - Fixed when blocks on methods with no arguments are transformed into `to_proc` syntax.
800
850
 
801
851
  ## [0.12.1] - 2019-04-22
802
852
 
803
853
  ### Changed
804
854
 
805
- - kddeisz - If a lambda literal is nested under a `command` or `command_call` node anywhere in the heirarchy, then it needs to use the higher-precedence `{ ... }` braces as opposed to the `do ... end` delimiters.
806
- - jpickwell, kddeisz - Calling `super` with a block and no args was causing the parser to fail when attempting to inspect lambda nodes.
807
- - kddeisz - Support better breaking within interpolation by grouping the interpolated content.
855
+ - kddnewton - If a lambda literal is nested under a `command` or `command_call` node anywhere in the heirarchy, then it needs to use the higher-precedence `{ ... }` braces as opposed to the `do ... end` delimiters.
856
+ - jpickwell, kddnewton - Calling `super` with a block and no args was causing the parser to fail when attempting to inspect lambda nodes.
857
+ - kddnewton - Support better breaking within interpolation by grouping the interpolated content.
808
858
 
809
859
  ## [0.12.0] - 2019-04-18
810
860
 
811
861
  ### Added
812
862
 
813
- - kddeisz - Automatically convert `lambda { ... }` method calls into `-> { ... }` literals.
863
+ - kddnewton - Automatically convert `lambda { ... }` method calls into `-> { ... }` literals.
814
864
 
815
865
  ## [0.11.0] - 2019-04-18
816
866
 
817
867
  ### Added
818
868
 
819
- - kddeisz - Support for parsing things with a ruby shebang (e.g., `#!/usr/bin/env ruby` or `#!/usr/bin/ruby`).
820
- - kddeisz - Big tests refactor.
821
- - kddeisz - Make multiple `when` predicates break at 80 chars and then wrap to be inline with the other predicates.
822
- - kddeisz - Automatically add underscores in large numbers that aren't already formatted.
869
+ - kddnewton - Support for parsing things with a ruby shebang (e.g., `#!/usr/bin/env ruby` or `#!/usr/bin/ruby`).
870
+ - kddnewton - Big tests refactor.
871
+ - kddnewton - Make multiple `when` predicates break at 80 chars and then wrap to be inline with the other predicates.
872
+ - kddnewton - Automatically add underscores in large numbers that aren't already formatted.
823
873
  - AlanFoster - Better support for inline access control modifiers.
824
- - jpickwell, kddeisz - Better support for heredocs in hash literals.
825
- - kddeisz - Better support for heredocs in array literals.
826
- - kddeisz - Support automatically transforming `def/begin/rescue/end/end` into `def/rescue/end`.
874
+ - jpickwell, kddnewton - Better support for heredocs in hash literals.
875
+ - kddnewton - Better support for heredocs in array literals.
876
+ - kddnewton - Support automatically transforming `def/begin/rescue/end/end` into `def/rescue/end`.
827
877
 
828
878
  ### Changed
829
879
 
830
880
  - deecewan - Fixed support for dynamic string hash keys.
831
- - kddeisz - Moved `case/when` into its own file and added better documentation.
832
- - kddeisz - Moved `begin/rescue` into its own file.
881
+ - kddnewton - Moved `case/when` into its own file and added better documentation.
882
+ - kddnewton - Moved `begin/rescue` into its own file.
833
883
  - AlanFoster - Automatically add newlines around access modifiers.
834
- - kddeisz - Alignment of command calls with arguments is fixed.
835
- - aaronjensen, kddeisz - Alignment of `to` is explicitly allowed to not indent to better support rspec.
836
- - kddeisz - Fix up the `to_proc` transform so that it works with other argument handling appropriately.
837
- - kddeisz - Fixed regression on regexp comments.
838
- - CodingItWrong, kddeisz - Fix up block delimiters when nested inside a `command` or `command_call` node.
839
- - kddeisz - Moved hashes into its own file.
884
+ - kddnewton - Alignment of command calls with arguments is fixed.
885
+ - aaronjensen, kddnewton - Alignment of `to` is explicitly allowed to not indent to better support rspec.
886
+ - kddnewton - Fix up the `to_proc` transform so that it works with other argument handling appropriately.
887
+ - kddnewton - Fixed regression on regexp comments.
888
+ - CodingItWrong, kddnewton - Fix up block delimiters when nested inside a `command` or `command_call` node.
889
+ - kddnewton - Moved hashes into its own file.
840
890
 
841
891
  ## [0.10.0] - 2019-03-25
842
892
 
843
893
  ### Added
844
894
 
845
- - kddeisz - Support for block-local variables.
846
- - kddeisz - Support for dyna-symbols that are using single quotes.
895
+ - kddnewton - Support for block-local variables.
896
+ - kddnewton - Support for dyna-symbols that are using single quotes.
847
897
 
848
898
  ### Changed
849
899
 
850
- - kddeisz - Force method calls after arrays, blocks, hashes, and xstrings to hang onto the end of the previous nodes.
851
- - kddeisz - Check before anything else for an invalid ruby version.
900
+ - kddnewton - Force method calls after arrays, blocks, hashes, and xstrings to hang onto the end of the previous nodes.
901
+ - kddnewton - Check before anything else for an invalid ruby version.
852
902
 
853
903
  ## [0.9.1] - 2019-03-24
854
904
 
855
905
  ### Changed
856
906
 
857
- - kddeisz - Better support string quotes by favoring what the user chose if the string contains escape patterns.
858
- - kddeisz - Better support heredocs within method calls.
907
+ - kddnewton - Better support string quotes by favoring what the user chose if the string contains escape patterns.
908
+ - kddnewton - Better support heredocs within method calls.
859
909
 
860
910
  ## [0.9.0] - 2019-03-18
861
911
 
862
912
  ### Added
863
913
 
864
- - kddeisz - Support the `hasPragma` function.
865
- - kddeisz - Support the new `number_arg` node type in Ruby 2.7.
914
+ - kddnewton - Support the `hasPragma` function.
915
+ - kddnewton - Support the new `number_arg` node type in Ruby 2.7.
866
916
 
867
917
  ### Changed
868
918
 
869
- - kddeisz - Limit the number of nodes that are allowed to turn into ternary expressions.
919
+ - kddnewton - Limit the number of nodes that are allowed to turn into ternary expressions.
870
920
 
871
921
  ## [0.8.0] - 2019-03-08
872
922
 
873
923
  ### Added
874
924
 
875
- - kddeisz - Add `eslint` and fix up existing violations.
925
+ - kddnewton - Add `eslint` and fix up existing violations.
876
926
  - AlanFoster - Add the infra for the `prettier` ruby gem.
877
- - kddeisz - Add a `rake` task for easier process integration for the ruby gem.
878
- - kddeisz - Handle direct interpolation of strings with %w array literals (i.e., `["#{foo}"]` should not be transformed into a %w array).
927
+ - kddnewton - Add a `rake` task for easier process integration for the ruby gem.
928
+ - kddnewton - Handle direct interpolation of strings with %w array literals (i.e., `["#{foo}"]` should not be transformed into a %w array).
879
929
 
880
930
  ### Changed
881
931
 
882
- - kddeisz - Fix string escaping for hex digit bit patterns when there's only one character after the "x".
932
+ - kddnewton - Fix string escaping for hex digit bit patterns when there's only one character after the "x".
883
933
  - AlanFoster - Don't allow line breaks between brace block params.
884
934
  - johnschoeman - Switch over the array.rb test case to minitest.
885
935
  - AlanFoster - Test improvements to allow running in parallel.
886
936
  - johnschoeman - Switch over assign.rb test case to minitest.
887
937
  - AlanFoster - Add a contributing guide.
888
938
  - AlanFoster - Handle longer command nodes.
889
- - kddeisz - Changed the ruby executable within the `prettier` gem to `rbprettier` for easier autocomplete.
939
+ - kddnewton - Changed the ruby executable within the `prettier` gem to `rbprettier` for easier autocomplete.
890
940
 
891
941
  ### Removed
892
942
 
893
- - kddeisz - All instances of the spread (`...`) operator so that we can support older versions of node.
943
+ - kddnewton - All instances of the spread (`...`) operator so that we can support older versions of node.
894
944
 
895
945
  ## [0.7.0] - 2019-02-24
896
946
 
897
947
  ### Changed
898
948
 
899
- - kddeisz - Support checking for escaping within strings to force double quotes (e.g., "\n").
900
- - RossKinsella, kddeisz - Handle cases with empty class and module declarations that need to break.
949
+ - kddnewton - Support checking for escaping within strings to force double quotes (e.g., "\n").
950
+ - RossKinsella, kddnewton - Handle cases with empty class and module declarations that need to break.
901
951
  - AlanFoster - Align the `bin/print` and `bin/sexp` APto support `bin/print` taking a filepath.
902
- - AndrewRayCode, kddeisz - Support lambdas that don't break and are inline.
952
+ - AndrewRayCode, kddnewton - Support lambdas that don't break and are inline.
903
953
  - AlanFoster - Switch over the numbers.rb test to minitest.
904
954
  - AlanFoster - Switch over the kwargs.rb test to minitest.
905
955
  - AlanFoster - Bail out early if the Ruby input is invalid.
906
- - kddeisz - Support `__END__` content.
956
+ - kddnewton - Support `__END__` content.
907
957
  - AlanFoster - Fix up issue with whitespace being added within regexp that are multiline.
908
958
  - AlanFoster - Better support for destructuring within multi assignment.
909
- - kddeisz - Switch `next` test over to minitest.
910
- - kddeisz - Handle multiple arguments to `next` with a space between.
911
- - AndrewRayCode, kddeisz - Handle multi-line conditional predicate (should align with keyword).
912
- - aaronjensen, kddeisz - Properly support adding trailing commas with and without blocks.
913
- - AlanFoster, kddeisz - Fix regression of handling comments within arrays on array literals.
959
+ - kddnewton - Switch `next` test over to minitest.
960
+ - kddnewton - Handle multiple arguments to `next` with a space between.
961
+ - AndrewRayCode, kddnewton - Handle multi-line conditional predicate (should align with keyword).
962
+ - aaronjensen, kddnewton - Properly support adding trailing commas with and without blocks.
963
+ - AlanFoster, kddnewton - Fix regression of handling comments within arrays on array literals.
914
964
  - AlanFoster - Support multiple arguments to `undef`.
915
965
 
916
966
  ## [0.6.3] - 2019-02-18
917
967
 
918
968
  ### Changed
919
969
 
920
- - kddeisz - Switch over `binary` fixture to minitest.
921
- - kddeisz - Reconfigure parser into multiple layer modules so that it's easier to understand and manage.
922
- - kddeisz - Handle comments from within `begin`, `rescue`, `ensure`, `while`, and `until` nodes.
923
- - kddeisz - Properly indent heredocs without taking into account current indentation level.
970
+ - kddnewton - Switch over `binary` fixture to minitest.
971
+ - kddnewton - Reconfigure parser into multiple layer modules so that it's easier to understand and manage.
972
+ - kddnewton - Handle comments from within `begin`, `rescue`, `ensure`, `while`, and `until` nodes.
973
+ - kddnewton - Properly indent heredocs without taking into account current indentation level.
924
974
 
925
975
  ## [0.6.2] - 2019-02-17
926
976
 
927
977
  ### Changed
928
978
 
929
979
  - AlanFoster - Handle regexp suffixes.
930
- - kddeisz - Add support for testing the test fixtures with minitest.
931
- - kddeisz - Switch over `alias` and `regexp` tests to minitest.
932
- - aaronjensen, kddeisz - Break up method args to split into multiple lines.
933
- - christoomey, kddeisz - Handle blocks args when trailing commas are on.
980
+ - kddnewton - Add support for testing the test fixtures with minitest.
981
+ - kddnewton - Switch over `alias` and `regexp` tests to minitest.
982
+ - aaronjensen, kddnewton - Break up method args to split into multiple lines.
983
+ - christoomey, kddnewton - Handle blocks args when trailing commas are on.
934
984
 
935
985
  ## [0.6.1] - 2019-02-15
936
986
 
937
987
  ### Changed
938
988
 
939
- - meleyal, kddeisz - Fix Ruby 2.5 inline comments on `args_add_block` nodes.
940
- - meleyal, kddeisz - Support passing `super()` explicitly with no arguments.
989
+ - meleyal, kddnewton - Fix Ruby 2.5 inline comments on `args_add_block` nodes.
990
+ - meleyal, kddnewton - Support passing `super()` explicitly with no arguments.
941
991
 
942
992
  ## [0.6.0] - 2019-02-14
943
993
 
944
994
  ### Added
945
995
 
946
- - kddeisz - Handle non UTF-8 comments.
947
- - kddeisz - Handle non UTF-8 identifiers.
948
- - kddeisz - Handle non UTF-8 strings.
949
- - kddeisz - Handle empty parens.
950
- - kddeisz - Handle rescue with splats preceeding the exception names.
996
+ - kddnewton - Handle non UTF-8 comments.
997
+ - kddnewton - Handle non UTF-8 identifiers.
998
+ - kddnewton - Handle non UTF-8 strings.
999
+ - kddnewton - Handle empty parens.
1000
+ - kddnewton - Handle rescue with splats preceeding the exception names.
951
1001
 
952
1002
  ### Changed
953
1003
 
954
- - kddeisz - Use `JSON::fast_generate` to get the s-expressions back from the parser.
955
- - NoahTheDuke, kddeisz - Handle broken lambdas from within `command` and `command_call` nodes.
1004
+ - kddnewton - Use `JSON::fast_generate` to get the s-expressions back from the parser.
1005
+ - NoahTheDuke, kddnewton - Handle broken lambdas from within `command` and `command_call` nodes.
956
1006
 
957
1007
  ## [0.5.2] - 2019-02-13
958
1008
 
959
1009
  ### Changed
960
1010
 
961
- - kddeisz - Support embedded expressions within strings that contain only keywords, as in `"#{super}"`.
1011
+ - kddnewton - Support embedded expressions within strings that contain only keywords, as in `"#{super}"`.
962
1012
 
963
1013
  ## [0.5.1] - 2019-02-13
964
1014
 
965
1015
  ### Changed
966
1016
 
967
- - yuki24, kddeisz - Force `do` blocks that we know have to be `do` blocks to break.
968
- - kmcq, kddeisz - Handle `command` and `command_call` nodes `do` blocks by forcing them to break.
969
- - ashfurrow, kddeisz - Attach comments to full hash association nodes, not just the value.
1017
+ - yuki24, kddnewton - Force `do` blocks that we know have to be `do` blocks to break.
1018
+ - kmcq, kddnewton - Handle `command` and `command_call` nodes `do` blocks by forcing them to break.
1019
+ - ashfurrow, kddnewton - Attach comments to full hash association nodes, not just the value.
970
1020
 
971
1021
  ## [0.5.0] - 2019-02-13
972
1022
 
973
1023
  ### Added
974
1024
 
975
- - kddeisz - Automatically convert arrays of all string literals to %w arrays.
976
- - kddeisz - Automatically convert arrays of all symbol literals to %i arrays.
1025
+ - kddnewton - Automatically convert arrays of all string literals to %w arrays.
1026
+ - kddnewton - Automatically convert arrays of all symbol literals to %i arrays.
977
1027
 
978
1028
  ### Changed
979
1029
 
980
- - kddeisz - Move the `args_add` and `args_new` handling into the parser.
981
- - uri, kddeisz - Change `command_call` nodes to properly indent when broken and to not add a trailing comma.
982
- - kddeisz - Rename the `trailingComma` option to `addTrailingCommas` to not conflict with the JS option.
1030
+ - kddnewton - Move the `args_add` and `args_new` handling into the parser.
1031
+ - uri, kddnewton - Change `command_call` nodes to properly indent when broken and to not add a trailing comma.
1032
+ - kddnewton - Rename the `trailingComma` option to `addTrailingCommas` to not conflict with the JS option.
983
1033
 
984
1034
  ## [0.4.1] - 2019-02-12
985
1035
 
986
1036
  ### Changed
987
1037
 
988
- - kddeisz - Provide the `makeList` utility for the nodes that are lists from within ripper.
989
- - awinograd, kddeisz - Again, this time for real, properly escape strings.
990
- - kddeisz - Fix up trailing commas on command calls.
1038
+ - kddnewton - Provide the `makeList` utility for the nodes that are lists from within ripper.
1039
+ - awinograd, kddnewton - Again, this time for real, properly escape strings.
1040
+ - kddnewton - Fix up trailing commas on command calls.
991
1041
 
992
1042
  ## [0.4.0] - 2019-02-12
993
1043
 
994
1044
  ### Added
995
1045
 
996
- - Overload119, kddeisz - Support the `trailingComma` configuration option (defaults to `false`).
1046
+ - Overload119, kddnewton - Support the `trailingComma` configuration option (defaults to `false`).
997
1047
 
998
1048
  ### Changed
999
1049
 
1000
- - NoahTheDuke, kddeisz - Pass the code to be formatted over `stdin`.
1050
+ - NoahTheDuke, kddnewton - Pass the code to be formatted over `stdin`.
1001
1051
 
1002
1052
  ## [0.3.7] - 2019-02-11
1003
1053
 
1004
1054
  ### Changed
1005
1055
 
1006
- - kddeisz - Split up statements even if they started on the same line with `;`s unless they are within an embedded expression.
1007
- - kddeisz - Properly handle escaped quotes within strings.
1056
+ - kddnewton - Split up statements even if they started on the same line with `;`s unless they are within an embedded expression.
1057
+ - kddnewton - Properly handle escaped quotes within strings.
1008
1058
 
1009
1059
  ## [0.3.6] - 2019-02-10
1010
1060
 
1011
1061
  ### Changed
1012
1062
 
1013
- - AlanFoster, kddeisz - Support the `not` operator properly.
1014
- - AlanFoster, kddeisz - Handle comments properly inside `if`, `unless`, and `when` nodes.
1063
+ - AlanFoster, kddnewton - Support the `not` operator properly.
1064
+ - AlanFoster, kddnewton - Handle comments properly inside `if`, `unless`, and `when` nodes.
1015
1065
 
1016
1066
  ## [0.3.5] - 2019-02-09
1017
1067
 
1018
1068
  ### Changed
1019
1069
 
1020
- - kddeisz - Handle lonely operators in Ruby `2.5`.
1070
+ - kddnewton - Handle lonely operators in Ruby `2.5`.
1021
1071
 
1022
1072
  ## [0.3.4] - 2019-02-09
1023
1073
 
1024
1074
  ### Changed
1025
1075
 
1026
- - kddeisz - Comments are now properly attached inside `defs` nodes.
1027
- - kddeisz - Support multiple inline comments on nodes.
1028
- - kddeisz - Support inline comments from within the `EXPR_END|EXPR_LABEL` lexer state.
1076
+ - kddnewton - Comments are now properly attached inside `defs` nodes.
1077
+ - kddnewton - Support multiple inline comments on nodes.
1078
+ - kddnewton - Support inline comments from within the `EXPR_END|EXPR_LABEL` lexer state.
1029
1079
  - cbothner - Stop transforming multistatement blocks with `to_proc`.
1030
- - kddeisz - `do` blocks necessarily need to break their parent nodes.
1031
- - eins78, kddeisz - Handle `next` node edge case with `args_add` as the body.
1080
+ - kddnewton - `do` blocks necessarily need to break their parent nodes.
1081
+ - eins78, kddnewton - Handle `next` node edge case with `args_add` as the body.
1032
1082
 
1033
1083
  ## [0.3.3] - 2019-02-09
1034
1084
 
1035
1085
  ### Changed
1036
1086
 
1037
- - bugthing, kddeisz - Command nodes within conditionals now break parents to disallow them from being turned into ternary expressions.
1038
- - awinograd, kddeisz - Properly escape double quotes when using `preferSingleQuotes: false`.
1087
+ - bugthing, kddnewton - Command nodes within conditionals now break parents to disallow them from being turned into ternary expressions.
1088
+ - awinograd, kddnewton - Properly escape double quotes when using `preferSingleQuotes: false`.
1039
1089
 
1040
1090
  ## [0.3.2] - 2019-02-09
1041
1091
 
1042
1092
  ### Changed
1043
1093
 
1044
- - kddeisz - Don't define duplicated methods in the parser.
1045
- - kddeisz - Let prettier know about `.rb` and `.rake` files so you don't have to specify the parser when running.
1046
- - kddeisz - Renamed the package to @prettier/plugin-ruby.
1094
+ - kddnewton - Don't define duplicated methods in the parser.
1095
+ - kddnewton - Let prettier know about `.rb` and `.rake` files so you don't have to specify the parser when running.
1096
+ - kddnewton - Renamed the package to @prettier/plugin-ruby.
1047
1097
 
1048
1098
  ## [0.3.1] - 2019-02-07
1049
1099
 
1050
1100
  ### Changed
1051
1101
 
1052
- - kddeisz - Automatically add parens to method declarations.
1053
- - kddeisz - Handle comments on bare hash assocs.
1054
- - kddeisz - Handle `method_add_block` nodes where the statements may be nested one more level.
1055
- - kddeisz - Handle heredocs nested no matter how many levels deep.
1102
+ - kddnewton - Automatically add parens to method declarations.
1103
+ - kddnewton - Handle comments on bare hash assocs.
1104
+ - kddnewton - Handle `method_add_block` nodes where the statements may be nested one more level.
1105
+ - kddnewton - Handle heredocs nested no matter how many levels deep.
1056
1106
 
1057
1107
  ## [0.3.0] - 2019-02-07
1058
1108
 
1059
1109
  ### Added
1060
1110
 
1061
- - kddeisz - Support squiggly heredocs.
1062
- - kddeisz - Support straight heredocs.
1111
+ - kddnewton - Support squiggly heredocs.
1112
+ - kddnewton - Support straight heredocs.
1063
1113
 
1064
1114
  ### Changed
1065
1115
 
1066
- - kddeisz - Ignore current indentation when creating embdocs so that `=begin` is always at the beginning of the line.
1067
- - kddeisz - Move `regexp_add` and `regexp_new` handling into the parser.
1068
- - kddeisz - Move `xstring_add` and `xstring_new` handling into the parser.
1069
- - kddeisz - Move `string_add` and `string_content` handling into the parser.
1070
- - kddeisz - Move `mrhs_add` and `mrhs_new` handling into the parser.
1071
- - kddeisz - Move `mlhs_add` and `mlhs_new` handling into the parser.
1116
+ - kddnewton - Ignore current indentation when creating embdocs so that `=begin` is always at the beginning of the line.
1117
+ - kddnewton - Move `regexp_add` and `regexp_new` handling into the parser.
1118
+ - kddnewton - Move `xstring_add` and `xstring_new` handling into the parser.
1119
+ - kddnewton - Move `string_add` and `string_content` handling into the parser.
1120
+ - kddnewton - Move `mrhs_add` and `mrhs_new` handling into the parser.
1121
+ - kddnewton - Move `mlhs_add` and `mlhs_new` handling into the parser.
1072
1122
 
1073
1123
  ## [0.2.1] - 2019-02-06
1074
1124
 
1075
1125
  ### Changed
1076
1126
 
1077
- - kddeisz - Handle brace blocks on commands properly.
1078
- - kddeisz - Break parent and return `do` blocks when called from a `command` node.
1079
- - kddeisz - Handle edge cases with `if` statements where there is no body of the if (so it can't be converted to a ternary).
1127
+ - kddnewton - Handle brace blocks on commands properly.
1128
+ - kddnewton - Break parent and return `do` blocks when called from a `command` node.
1129
+ - kddnewton - Handle edge cases with `if` statements where there is no body of the if (so it can't be converted to a ternary).
1080
1130
 
1081
1131
  ## [0.2.0] - 2019-02-06
1082
1132
 
1083
1133
  ### Added
1084
1134
 
1085
- - kddeisz - Handle `methref` nodes from Ruby `2.7`.
1086
- - kddeisz - Allow `module` nodes to shorten using `;` when the block is empty.
1135
+ - kddnewton - Handle `methref` nodes from Ruby `2.7`.
1136
+ - kddnewton - Allow `module` nodes to shorten using `;` when the block is empty.
1087
1137
 
1088
1138
  ### Changed
1089
1139
 
1090
- - kddeisz - Handle splat within an array, as in `[1, 2, *foo]`.
1091
- - kddeisz - Disallow comments from being attached to intermediary regex nodes.
1092
- - kddeisz - Fix `to_proc` transforms to reference the method called as opposed to the parameter name.
1093
- - kddeisz - Change statement lists to be generated within the parser instead of the printer, thereby allowing finer control over comments.
1094
- - kddeisz - Completely revamp comment parsing by switching off the internal lexer state from `ripper`. This should drastically increase accuracy of comment parsing in general, and set us up for success in the future.
1095
- - kddeisz - Allow comments to be attached to `CHAR` nodes.
1096
- - kddeisz - Disallow comments from being attached to `args_new` nodes.
1097
- - kddeisz - Track start and end lines so we can better insert block comments.
1098
- - kddeisz - Handle intermediary array nodes in the parse for better comment handling.
1140
+ - kddnewton - Handle splat within an array, as in `[1, 2, *foo]`.
1141
+ - kddnewton - Disallow comments from being attached to intermediary regex nodes.
1142
+ - kddnewton - Fix `to_proc` transforms to reference the method called as opposed to the parameter name.
1143
+ - kddnewton - Change statement lists to be generated within the parser instead of the printer, thereby allowing finer control over comments.
1144
+ - kddnewton - Completely revamp comment parsing by switching off the internal lexer state from `ripper`. This should drastically increase accuracy of comment parsing in general, and set us up for success in the future.
1145
+ - kddnewton - Allow comments to be attached to `CHAR` nodes.
1146
+ - kddnewton - Disallow comments from being attached to `args_new` nodes.
1147
+ - kddnewton - Track start and end lines so we can better insert block comments.
1148
+ - kddnewton - Handle intermediary array nodes in the parse for better comment handling.
1099
1149
 
1100
1150
  ## [0.1.2] - 2019-02-05
1101
1151
 
1102
1152
  ### Changed
1103
1153
 
1104
- - kddeisz - Handle guard clauses that return with no parens.
1154
+ - kddnewton - Handle guard clauses that return with no parens.
1105
1155
 
1106
1156
  ## [0.1.1] - 2019-02-05
1107
1157
 
1108
1158
  ### Changed
1109
1159
 
1110
- - kddeisz - Handle class method calls with the `::` operator.
1111
- - kddeisz - Handle strings with apostrophes when using `preferSingleQuote`.
1112
- - kddeisz - Have travis run multiple ruby versions.
1113
- - kddeisz - Explicitly fail if ruby version is < `2.5`.
1114
- - kddeisz - Disallow comments from being attached to intermediary string nodes.
1160
+ - kddnewton - Handle class method calls with the `::` operator.
1161
+ - kddnewton - Handle strings with apostrophes when using `preferSingleQuote`.
1162
+ - kddnewton - Have travis run multiple ruby versions.
1163
+ - kddnewton - Explicitly fail if ruby version is < `2.5`.
1164
+ - kddnewton - Disallow comments from being attached to intermediary string nodes.
1115
1165
 
1116
1166
  ## [0.1.0] - 2019-02-04
1117
1167
 
@@ -1119,7 +1169,11 @@ would previously result in `array[]`, but now prints properly.
1119
1169
 
1120
1170
  - Initial release 🎉
1121
1171
 
1122
- [unreleased]: https://github.com/prettier/plugin-ruby/compare/v1.6.0...HEAD
1172
+ [unreleased]: https://github.com/prettier/plugin-ruby/compare/v2.0.0-rc3...HEAD
1173
+ [2.0.0-rc3]: https://github.com/prettier/plugin-ruby/compare/v2.0.0-rc2...v2.0.0-rc3
1174
+ [2.0.0-rc2]: https://github.com/prettier/plugin-ruby/compare/v2.0.0-rc1...v2.0.0-rc2
1175
+ [2.0.0-rc1]: https://github.com/prettier/plugin-ruby/compare/v1.6.1...v2.0.0-rc1
1176
+ [1.6.1]: https://github.com/prettier/plugin-ruby/compare/v1.6.0...v1.6.1
1123
1177
  [1.6.0]: https://github.com/prettier/plugin-ruby/compare/v1.5.5...v1.6.0
1124
1178
  [1.5.5]: https://github.com/prettier/plugin-ruby/compare/v1.5.4...v1.5.5
1125
1179
  [1.5.4]: https://github.com/prettier/plugin-ruby/compare/v1.5.3...v1.5.4