brakeman 4.4.0 → 5.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (732) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGES.md +271 -107
  3. data/README.md +19 -12
  4. data/bundle/load.rb +14 -14
  5. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/erubis-2.7.0/CHANGES.txt +0 -0
  6. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/erubis-2.7.0/MIT-LICENSE +0 -0
  7. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/erubis-2.7.0/README.txt +0 -0
  8. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/erubis-2.7.0/contrib/erubis +0 -0
  9. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/erubis-2.7.0/contrib/erubis-run.rb +0 -0
  10. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/erubis-2.7.0/contrib/inline-require +0 -0
  11. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/erubis-2.7.0/lib/erubis.rb +0 -0
  12. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/erubis-2.7.0/lib/erubis/context.rb +0 -0
  13. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/erubis-2.7.0/lib/erubis/converter.rb +0 -0
  14. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/erubis-2.7.0/lib/erubis/engine.rb +0 -0
  15. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/erubis-2.7.0/lib/erubis/engine/ec.rb +0 -0
  16. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/erubis-2.7.0/lib/erubis/engine/ecpp.rb +0 -0
  17. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/erubis-2.7.0/lib/erubis/engine/ejava.rb +0 -0
  18. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/erubis-2.7.0/lib/erubis/engine/ejavascript.rb +0 -0
  19. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/erubis-2.7.0/lib/erubis/engine/enhanced.rb +0 -0
  20. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/erubis-2.7.0/lib/erubis/engine/eperl.rb +0 -0
  21. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/erubis-2.7.0/lib/erubis/engine/ephp.rb +0 -0
  22. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/erubis-2.7.0/lib/erubis/engine/eruby.rb +0 -0
  23. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/erubis-2.7.0/lib/erubis/engine/escheme.rb +0 -0
  24. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/erubis-2.7.0/lib/erubis/engine/optimized.rb +0 -0
  25. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/erubis-2.7.0/lib/erubis/enhancer.rb +0 -0
  26. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/erubis-2.7.0/lib/erubis/error.rb +0 -0
  27. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/erubis-2.7.0/lib/erubis/evaluator.rb +0 -0
  28. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/erubis-2.7.0/lib/erubis/generator.rb +0 -0
  29. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/erubis-2.7.0/lib/erubis/helper.rb +0 -0
  30. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/erubis-2.7.0/lib/erubis/helpers/rails_form_helper.rb +0 -0
  31. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/erubis-2.7.0/lib/erubis/helpers/rails_helper.rb +0 -0
  32. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/erubis-2.7.0/lib/erubis/local-setting.rb +0 -0
  33. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/erubis-2.7.0/lib/erubis/main.rb +0 -0
  34. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/erubis-2.7.0/lib/erubis/preprocessing.rb +0 -0
  35. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/erubis-2.7.0/lib/erubis/tiny.rb +0 -0
  36. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/erubis-2.7.0/lib/erubis/util.rb +0 -0
  37. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/erubis-2.7.0/setup.rb +0 -0
  38. data/bundle/ruby/{2.5.0/gems/haml-4.0.7 → 2.7.0/gems/haml-5.2.1}/CHANGELOG.md +138 -4
  39. data/bundle/ruby/{2.5.0/gems/haml-4.0.7 → 2.7.0/gems/haml-5.2.1}/FAQ.md +4 -14
  40. data/bundle/ruby/2.7.0/gems/haml-5.2.1/Gemfile +16 -0
  41. data/bundle/ruby/{2.5.0/gems/sass-3.4.25/vendor/listen/LICENSE → 2.7.0/gems/haml-5.2.1/MIT-LICENSE} +1 -1
  42. data/bundle/ruby/{2.5.0/gems/haml-4.0.7 → 2.7.0/gems/haml-5.2.1}/README.md +79 -42
  43. data/bundle/ruby/{2.5.0/gems/haml-4.0.7 → 2.7.0/gems/haml-5.2.1}/REFERENCE.md +150 -71
  44. data/bundle/ruby/2.7.0/gems/haml-5.2.1/TODO +24 -0
  45. data/bundle/ruby/2.7.0/gems/haml-5.2.1/haml.gemspec +45 -0
  46. data/bundle/ruby/{2.5.0/gems/haml-4.0.7 → 2.7.0/gems/haml-5.2.1}/lib/haml.rb +2 -0
  47. data/bundle/ruby/2.7.0/gems/haml-5.2.1/lib/haml/attribute_builder.rb +164 -0
  48. data/bundle/ruby/2.7.0/gems/haml-5.2.1/lib/haml/attribute_compiler.rb +235 -0
  49. data/bundle/ruby/2.7.0/gems/haml-5.2.1/lib/haml/attribute_parser.rb +150 -0
  50. data/bundle/ruby/{2.5.0/gems/haml-4.0.7 → 2.7.0/gems/haml-5.2.1}/lib/haml/buffer.rb +25 -132
  51. data/bundle/ruby/2.7.0/gems/haml-5.2.1/lib/haml/compiler.rb +330 -0
  52. data/bundle/ruby/{2.5.0/gems/haml-4.0.7 → 2.7.0/gems/haml-5.2.1}/lib/haml/engine.rb +34 -41
  53. data/bundle/ruby/2.7.0/gems/haml-5.2.1/lib/haml/error.rb +65 -0
  54. data/bundle/ruby/2.7.0/gems/haml-5.2.1/lib/haml/escapable.rb +77 -0
  55. data/bundle/ruby/{2.5.0/gems/haml-4.0.7 → 2.7.0/gems/haml-5.2.1}/lib/haml/exec.rb +38 -20
  56. data/bundle/ruby/{2.5.0/gems/haml-4.0.7 → 2.7.0/gems/haml-5.2.1}/lib/haml/filters.rb +22 -27
  57. data/bundle/ruby/2.7.0/gems/haml-5.2.1/lib/haml/generator.rb +42 -0
  58. data/bundle/ruby/{2.5.0/gems/haml-4.0.7 → 2.7.0/gems/haml-5.2.1}/lib/haml/helpers.rb +134 -89
  59. data/bundle/ruby/{2.5.0/gems/haml-4.0.7 → 2.7.0/gems/haml-5.2.1}/lib/haml/helpers/action_view_extensions.rb +4 -2
  60. data/bundle/ruby/{2.5.0/gems/haml-4.0.7 → 2.7.0/gems/haml-5.2.1}/lib/haml/helpers/action_view_mods.rb +45 -60
  61. data/bundle/ruby/{2.5.0/gems/haml-4.0.7 → 2.7.0/gems/haml-5.2.1}/lib/haml/helpers/action_view_xss_mods.rb +2 -0
  62. data/bundle/ruby/2.7.0/gems/haml-5.2.1/lib/haml/helpers/safe_erubi_template.rb +20 -0
  63. data/bundle/ruby/{2.5.0/gems/haml-4.0.7 → 2.7.0/gems/haml-5.2.1}/lib/haml/helpers/safe_erubis_template.rb +5 -1
  64. data/bundle/ruby/{2.5.0/gems/haml-4.0.7 → 2.7.0/gems/haml-5.2.1}/lib/haml/helpers/xss_mods.rb +23 -13
  65. data/bundle/ruby/{2.5.0/gems/haml-4.0.7 → 2.7.0/gems/haml-5.2.1}/lib/haml/options.rb +63 -69
  66. data/bundle/ruby/{2.5.0/gems/haml-4.0.7 → 2.7.0/gems/haml-5.2.1}/lib/haml/parser.rb +319 -227
  67. data/bundle/ruby/2.7.0/gems/haml-5.2.1/lib/haml/plugin.rb +37 -0
  68. data/bundle/ruby/2.7.0/gems/haml-5.2.1/lib/haml/railtie.rb +48 -0
  69. data/bundle/ruby/{2.5.0/gems/haml-4.0.7 → 2.7.0/gems/haml-5.2.1}/lib/haml/sass_rails_filter.rb +18 -4
  70. data/bundle/ruby/{2.5.0/gems/haml-4.0.7 → 2.7.0/gems/haml-5.2.1}/lib/haml/template.rb +13 -6
  71. data/bundle/ruby/{2.5.0/gems/haml-4.0.7 → 2.7.0/gems/haml-5.2.1}/lib/haml/template/options.rb +13 -2
  72. data/bundle/ruby/2.7.0/gems/haml-5.2.1/lib/haml/temple_engine.rb +123 -0
  73. data/bundle/ruby/2.7.0/gems/haml-5.2.1/lib/haml/temple_line_counter.rb +30 -0
  74. data/bundle/ruby/2.7.0/gems/haml-5.2.1/lib/haml/util.rb +258 -0
  75. data/bundle/ruby/2.7.0/gems/haml-5.2.1/lib/haml/version.rb +5 -0
  76. data/bundle/ruby/2.7.0/gems/haml-5.2.1/yard/default/fulldoc/html/css/common.sass +15 -0
  77. data/bundle/ruby/2.7.0/gems/haml-5.2.1/yard/default/layout/html/footer.erb +12 -0
  78. data/bundle/ruby/{2.5.0/gems/highline-1.7.10 → 2.7.0/gems/highline-2.0.3}/AUTHORS +0 -0
  79. data/bundle/ruby/{2.5.0/gems/highline-1.7.10 → 2.7.0/gems/highline-2.0.3}/COPYING +0 -0
  80. data/bundle/ruby/{2.5.0/gems/highline-1.7.10 → 2.7.0/gems/highline-2.0.3}/Changelog.md +214 -15
  81. data/bundle/ruby/2.7.0/gems/highline-2.0.3/Gemfile +22 -0
  82. data/bundle/ruby/{2.5.0/gems/highline-1.7.10 → 2.7.0/gems/highline-2.0.3}/LICENSE +0 -0
  83. data/bundle/ruby/2.7.0/gems/highline-2.0.3/README.md +202 -0
  84. data/bundle/ruby/{2.5.0/gems/highline-1.7.10 → 2.7.0/gems/highline-2.0.3}/TODO +0 -0
  85. data/bundle/ruby/2.7.0/gems/highline-2.0.3/appveyor.yml +37 -0
  86. data/bundle/ruby/2.7.0/gems/highline-2.0.3/highline.gemspec +35 -0
  87. data/bundle/ruby/2.7.0/gems/highline-2.0.3/lib/highline.rb +650 -0
  88. data/bundle/ruby/2.7.0/gems/highline-2.0.3/lib/highline/builtin_styles.rb +129 -0
  89. data/bundle/ruby/{2.5.0/gems/highline-1.7.10 → 2.7.0/gems/highline-2.0.3}/lib/highline/color_scheme.rb +49 -32
  90. data/bundle/ruby/2.7.0/gems/highline-2.0.3/lib/highline/compatibility.rb +23 -0
  91. data/bundle/ruby/2.7.0/gems/highline-2.0.3/lib/highline/custom_errors.rb +57 -0
  92. data/bundle/ruby/2.7.0/gems/highline-2.0.3/lib/highline/import.rb +48 -0
  93. data/bundle/ruby/2.7.0/gems/highline-2.0.3/lib/highline/io_console_compatible.rb +37 -0
  94. data/bundle/ruby/2.7.0/gems/highline-2.0.3/lib/highline/list.rb +177 -0
  95. data/bundle/ruby/2.7.0/gems/highline-2.0.3/lib/highline/list_renderer.rb +261 -0
  96. data/bundle/ruby/2.7.0/gems/highline-2.0.3/lib/highline/menu.rb +576 -0
  97. data/bundle/ruby/2.7.0/gems/highline-2.0.3/lib/highline/menu/item.rb +32 -0
  98. data/bundle/ruby/2.7.0/gems/highline-2.0.3/lib/highline/paginator.rb +52 -0
  99. data/bundle/ruby/{2.5.0/gems/highline-1.7.10 → 2.7.0/gems/highline-2.0.3}/lib/highline/question.rb +281 -131
  100. data/bundle/ruby/2.7.0/gems/highline-2.0.3/lib/highline/question/answer_converter.rb +103 -0
  101. data/bundle/ruby/2.7.0/gems/highline-2.0.3/lib/highline/question_asker.rb +150 -0
  102. data/bundle/ruby/2.7.0/gems/highline-2.0.3/lib/highline/simulate.rb +59 -0
  103. data/bundle/ruby/2.7.0/gems/highline-2.0.3/lib/highline/statement.rb +88 -0
  104. data/bundle/ruby/2.7.0/gems/highline-2.0.3/lib/highline/string.rb +36 -0
  105. data/bundle/ruby/2.7.0/gems/highline-2.0.3/lib/highline/string_extensions.rb +130 -0
  106. data/bundle/ruby/2.7.0/gems/highline-2.0.3/lib/highline/style.rb +325 -0
  107. data/bundle/ruby/2.7.0/gems/highline-2.0.3/lib/highline/template_renderer.rb +62 -0
  108. data/bundle/ruby/2.7.0/gems/highline-2.0.3/lib/highline/terminal.rb +190 -0
  109. data/bundle/ruby/2.7.0/gems/highline-2.0.3/lib/highline/terminal/io_console.rb +36 -0
  110. data/bundle/ruby/2.7.0/gems/highline-2.0.3/lib/highline/terminal/ncurses.rb +38 -0
  111. data/bundle/ruby/2.7.0/gems/highline-2.0.3/lib/highline/terminal/unix_stty.rb +51 -0
  112. data/bundle/ruby/{2.5.0/gems/highline-1.7.10 → 2.7.0/gems/highline-2.0.3}/lib/highline/version.rb +3 -1
  113. data/bundle/ruby/2.7.0/gems/highline-2.0.3/lib/highline/wrapper.rb +53 -0
  114. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/Gemfile +6 -0
  115. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/LICENSE.txt +22 -0
  116. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/NEWS.md +141 -0
  117. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/README.md +60 -0
  118. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/attlistdecl.rb +63 -0
  119. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/attribute.rb +205 -0
  120. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/cdata.rb +68 -0
  121. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/child.rb +97 -0
  122. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/comment.rb +80 -0
  123. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/doctype.rb +287 -0
  124. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/document.rb +291 -0
  125. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/dtd/attlistdecl.rb +11 -0
  126. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/dtd/dtd.rb +47 -0
  127. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/dtd/elementdecl.rb +18 -0
  128. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/dtd/entitydecl.rb +57 -0
  129. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/dtd/notationdecl.rb +40 -0
  130. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/element.rb +1269 -0
  131. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/encoding.rb +51 -0
  132. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/entity.rb +171 -0
  133. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/formatters/default.rb +116 -0
  134. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/formatters/pretty.rb +142 -0
  135. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/formatters/transitive.rb +58 -0
  136. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/functions.rb +447 -0
  137. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/instruction.rb +79 -0
  138. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/light/node.rb +196 -0
  139. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/namespace.rb +59 -0
  140. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/node.rb +76 -0
  141. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/output.rb +30 -0
  142. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/parent.rb +166 -0
  143. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/parseexception.rb +52 -0
  144. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/parsers/baseparser.rb +594 -0
  145. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/parsers/lightparser.rb +59 -0
  146. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/parsers/pullparser.rb +197 -0
  147. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/parsers/sax2parser.rb +273 -0
  148. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/parsers/streamparser.rb +61 -0
  149. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/parsers/treeparser.rb +101 -0
  150. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/parsers/ultralightparser.rb +57 -0
  151. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/parsers/xpathparser.rb +675 -0
  152. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/quickpath.rb +266 -0
  153. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/rexml.rb +32 -0
  154. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/sax2listener.rb +98 -0
  155. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/security.rb +28 -0
  156. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/source.rb +298 -0
  157. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/streamlistener.rb +93 -0
  158. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/text.rb +424 -0
  159. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/undefinednamespaceexception.rb +9 -0
  160. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/validation/relaxng.rb +539 -0
  161. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/validation/validation.rb +144 -0
  162. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/validation/validationexception.rb +10 -0
  163. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/xmldecl.rb +130 -0
  164. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/xmltokens.rb +85 -0
  165. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/xpath.rb +81 -0
  166. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/lib/rexml/xpath_parser.rb +968 -0
  167. data/bundle/ruby/2.7.0/gems/rexml-3.2.4/rexml.gemspec +84 -0
  168. data/bundle/ruby/{2.5.0/gems/ruby2ruby-2.4.1 → 2.7.0/gems/ruby2ruby-2.4.4}/History.rdoc +22 -0
  169. data/bundle/ruby/{2.5.0/gems/ruby2ruby-2.4.1 → 2.7.0/gems/ruby2ruby-2.4.4}/Manifest.txt +0 -0
  170. data/bundle/ruby/{2.5.0/gems/ruby2ruby-2.4.1 → 2.7.0/gems/ruby2ruby-2.4.4}/README.rdoc +0 -0
  171. data/bundle/ruby/{2.5.0/gems/ruby2ruby-2.4.1 → 2.7.0/gems/ruby2ruby-2.4.4}/lib/ruby2ruby.rb +118 -110
  172. data/bundle/ruby/{2.5.0/gems/ruby_parser-3.12.0 → 2.7.0/gems/ruby_parser-3.15.1}/History.rdoc +176 -0
  173. data/bundle/ruby/{2.5.0/gems/ruby_parser-3.12.0 → 2.7.0/gems/ruby_parser-3.15.1}/Manifest.txt +7 -4
  174. data/bundle/ruby/{2.5.0/gems/ruby_parser-3.12.0 → 2.7.0/gems/ruby_parser-3.15.1}/README.rdoc +3 -3
  175. data/bundle/ruby/{2.5.0/gems/ruby_parser-3.12.0 → 2.7.0/gems/ruby_parser-3.15.1}/compare/normalize.rb +69 -2
  176. data/bundle/ruby/2.7.0/gems/ruby_parser-3.15.1/debugging.md +57 -0
  177. data/bundle/ruby/{2.5.0/gems/ruby_parser-3.12.0 → 2.7.0/gems/ruby_parser-3.15.1}/lib/rp_extensions.rb +1 -8
  178. data/bundle/ruby/{2.5.0/gems/ruby_parser-3.12.0 → 2.7.0/gems/ruby_parser-3.15.1}/lib/rp_stringscanner.rb +0 -0
  179. data/bundle/ruby/2.7.0/gems/ruby_parser-3.15.1/lib/ruby20_parser.rb +7062 -0
  180. data/bundle/ruby/{2.5.0/gems/ruby_parser-3.12.0/lib/ruby_parser.yy → 2.7.0/gems/ruby_parser-3.15.1/lib/ruby20_parser.y} +728 -604
  181. data/bundle/ruby/2.7.0/gems/ruby_parser-3.15.1/lib/ruby21_parser.rb +7140 -0
  182. data/bundle/ruby/{2.5.0/gems/ruby_parser-3.12.0 → 2.7.0/gems/ruby_parser-3.15.1}/lib/ruby21_parser.y +734 -472
  183. data/bundle/ruby/2.7.0/gems/ruby_parser-3.15.1/lib/ruby22_parser.rb +7160 -0
  184. data/bundle/ruby/{2.5.0/gems/ruby_parser-3.12.0 → 2.7.0/gems/ruby_parser-3.15.1}/lib/ruby22_parser.y +735 -478
  185. data/bundle/ruby/2.7.0/gems/ruby_parser-3.15.1/lib/ruby23_parser.rb +7175 -0
  186. data/bundle/ruby/{2.5.0/gems/ruby_parser-3.12.0 → 2.7.0/gems/ruby_parser-3.15.1}/lib/ruby23_parser.y +736 -479
  187. data/bundle/ruby/2.7.0/gems/ruby_parser-3.15.1/lib/ruby24_parser.rb +7204 -0
  188. data/bundle/ruby/{2.5.0/gems/ruby_parser-3.12.0 → 2.7.0/gems/ruby_parser-3.15.1}/lib/ruby24_parser.y +742 -477
  189. data/bundle/ruby/2.7.0/gems/ruby_parser-3.15.1/lib/ruby25_parser.rb +7204 -0
  190. data/bundle/ruby/{2.5.0/gems/ruby_parser-3.12.0 → 2.7.0/gems/ruby_parser-3.15.1}/lib/ruby25_parser.y +742 -477
  191. data/bundle/ruby/2.7.0/gems/ruby_parser-3.15.1/lib/ruby26_parser.rb +7224 -0
  192. data/bundle/ruby/2.7.0/gems/ruby_parser-3.15.1/lib/ruby26_parser.y +2657 -0
  193. data/bundle/ruby/2.7.0/gems/ruby_parser-3.15.1/lib/ruby27_parser.rb +7224 -0
  194. data/bundle/ruby/2.7.0/gems/ruby_parser-3.15.1/lib/ruby27_parser.y +2657 -0
  195. data/bundle/ruby/2.7.0/gems/ruby_parser-3.15.1/lib/ruby_lexer.rb +1473 -0
  196. data/bundle/ruby/2.7.0/gems/ruby_parser-3.15.1/lib/ruby_lexer.rex +178 -0
  197. data/bundle/ruby/2.7.0/gems/ruby_parser-3.15.1/lib/ruby_lexer.rex.rb +363 -0
  198. data/bundle/ruby/{2.5.0/gems/ruby_parser-3.12.0 → 2.7.0/gems/ruby_parser-3.15.1}/lib/ruby_parser.rb +36 -34
  199. data/bundle/ruby/2.7.0/gems/ruby_parser-3.15.1/lib/ruby_parser.yy +2764 -0
  200. data/bundle/ruby/2.7.0/gems/ruby_parser-3.15.1/lib/ruby_parser_extras.rb +1631 -0
  201. data/bundle/ruby/2.7.0/gems/ruby_parser-3.15.1/tools/munge.rb +222 -0
  202. data/bundle/ruby/2.7.0/gems/ruby_parser-3.15.1/tools/ripper.rb +39 -0
  203. data/bundle/ruby/2.7.0/gems/ruby_parser-legacy-1.0.0/History.rdoc +6 -0
  204. data/bundle/ruby/2.7.0/gems/ruby_parser-legacy-1.0.0/Manifest.txt +19 -0
  205. data/bundle/ruby/2.7.0/gems/ruby_parser-legacy-1.0.0/README.rdoc +54 -0
  206. data/bundle/ruby/2.7.0/gems/ruby_parser-legacy-1.0.0/lib/ruby_parser/legacy.rb +5 -0
  207. data/bundle/ruby/{2.5.0/gems/ruby_parser-3.12.0/lib → 2.7.0/gems/ruby_parser-legacy-1.0.0/lib/ruby_parser/legacy}/ruby18_parser.rb +7 -6
  208. data/bundle/ruby/{2.5.0/gems/ruby_parser-3.12.0/lib → 2.7.0/gems/ruby_parser-legacy-1.0.0/lib/ruby_parser/legacy}/ruby18_parser.y +5 -4
  209. data/bundle/ruby/{2.5.0/gems/ruby_parser-3.12.0/lib → 2.7.0/gems/ruby_parser-legacy-1.0.0/lib/ruby_parser/legacy}/ruby19_parser.rb +7 -6
  210. data/bundle/ruby/{2.5.0/gems/ruby_parser-3.12.0/lib → 2.7.0/gems/ruby_parser-legacy-1.0.0/lib/ruby_parser/legacy}/ruby19_parser.y +5 -4
  211. data/bundle/ruby/{2.5.0/gems/ruby_parser-3.12.0/lib → 2.7.0/gems/ruby_parser-legacy-1.0.0/lib/ruby_parser/legacy}/ruby_lexer.rb +117 -64
  212. data/bundle/ruby/{2.5.0/gems/ruby_parser-3.12.0/lib → 2.7.0/gems/ruby_parser-legacy-1.0.0/lib/ruby_parser/legacy}/ruby_lexer.rex +11 -9
  213. data/bundle/ruby/{2.5.0/gems/ruby_parser-3.12.0/lib → 2.7.0/gems/ruby_parser-legacy-1.0.0/lib/ruby_parser/legacy}/ruby_lexer.rex.rb +10 -10
  214. data/bundle/ruby/2.7.0/gems/ruby_parser-legacy-1.0.0/lib/ruby_parser/legacy/ruby_parser.rb +30 -0
  215. data/bundle/ruby/{2.5.0/gems/ruby_parser-3.12.0/lib → 2.7.0/gems/ruby_parser-legacy-1.0.0/lib/ruby_parser/legacy}/ruby_parser_extras.rb +43 -33
  216. data/bundle/ruby/{2.5.0/gems/safe_yaml-1.0.4 → 2.7.0/gems/safe_yaml-1.0.5}/CHANGES.md +5 -0
  217. data/bundle/ruby/{2.5.0/gems/safe_yaml-1.0.4 → 2.7.0/gems/safe_yaml-1.0.5}/Gemfile +0 -0
  218. data/bundle/ruby/{2.5.0/gems/safe_yaml-1.0.4 → 2.7.0/gems/safe_yaml-1.0.5}/LICENSE.txt +0 -0
  219. data/bundle/ruby/{2.5.0/gems/safe_yaml-1.0.4 → 2.7.0/gems/safe_yaml-1.0.5}/README.md +0 -0
  220. data/bundle/ruby/{2.5.0/gems/safe_yaml-1.0.4 → 2.7.0/gems/safe_yaml-1.0.5}/bundle_install_all_ruby_versions.sh +0 -0
  221. data/bundle/ruby/{2.5.0/gems/safe_yaml-1.0.4 → 2.7.0/gems/safe_yaml-1.0.5}/lib/safe_yaml.rb +0 -0
  222. data/bundle/ruby/{2.5.0/gems/safe_yaml-1.0.4 → 2.7.0/gems/safe_yaml-1.0.5}/lib/safe_yaml/deep.rb +0 -0
  223. data/bundle/ruby/{2.5.0/gems/safe_yaml-1.0.4 → 2.7.0/gems/safe_yaml-1.0.5}/lib/safe_yaml/libyaml_checker.rb +0 -0
  224. data/bundle/ruby/{2.5.0/gems/safe_yaml-1.0.4 → 2.7.0/gems/safe_yaml-1.0.5}/lib/safe_yaml/load.rb +0 -0
  225. data/bundle/ruby/{2.5.0/gems/safe_yaml-1.0.4 → 2.7.0/gems/safe_yaml-1.0.5}/lib/safe_yaml/parse/date.rb +2 -0
  226. data/bundle/ruby/{2.5.0/gems/safe_yaml-1.0.4 → 2.7.0/gems/safe_yaml-1.0.5}/lib/safe_yaml/parse/hexadecimal.rb +0 -0
  227. data/bundle/ruby/{2.5.0/gems/safe_yaml-1.0.4 → 2.7.0/gems/safe_yaml-1.0.5}/lib/safe_yaml/parse/sexagesimal.rb +0 -0
  228. data/bundle/ruby/{2.5.0/gems/safe_yaml-1.0.4 → 2.7.0/gems/safe_yaml-1.0.5}/lib/safe_yaml/psych_handler.rb +0 -0
  229. data/bundle/ruby/{2.5.0/gems/safe_yaml-1.0.4 → 2.7.0/gems/safe_yaml-1.0.5}/lib/safe_yaml/psych_resolver.rb +0 -0
  230. data/bundle/ruby/{2.5.0/gems/safe_yaml-1.0.4 → 2.7.0/gems/safe_yaml-1.0.5}/lib/safe_yaml/resolver.rb +0 -0
  231. data/bundle/ruby/{2.5.0/gems/safe_yaml-1.0.4 → 2.7.0/gems/safe_yaml-1.0.5}/lib/safe_yaml/safe_to_ruby_visitor.rb +0 -0
  232. data/bundle/ruby/2.7.0/gems/safe_yaml-1.0.5/lib/safe_yaml/store.rb +39 -0
  233. data/bundle/ruby/{2.5.0/gems/safe_yaml-1.0.4 → 2.7.0/gems/safe_yaml-1.0.5}/lib/safe_yaml/syck_hack.rb +0 -0
  234. data/bundle/ruby/{2.5.0/gems/safe_yaml-1.0.4 → 2.7.0/gems/safe_yaml-1.0.5}/lib/safe_yaml/syck_node_monkeypatch.rb +0 -0
  235. data/bundle/ruby/{2.5.0/gems/safe_yaml-1.0.4 → 2.7.0/gems/safe_yaml-1.0.5}/lib/safe_yaml/syck_resolver.rb +0 -0
  236. data/bundle/ruby/{2.5.0/gems/safe_yaml-1.0.4 → 2.7.0/gems/safe_yaml-1.0.5}/lib/safe_yaml/transform.rb +0 -0
  237. data/bundle/ruby/{2.5.0/gems/safe_yaml-1.0.4 → 2.7.0/gems/safe_yaml-1.0.5}/lib/safe_yaml/transform/to_boolean.rb +0 -0
  238. data/bundle/ruby/{2.5.0/gems/safe_yaml-1.0.4 → 2.7.0/gems/safe_yaml-1.0.5}/lib/safe_yaml/transform/to_date.rb +0 -0
  239. data/bundle/ruby/{2.5.0/gems/safe_yaml-1.0.4 → 2.7.0/gems/safe_yaml-1.0.5}/lib/safe_yaml/transform/to_float.rb +0 -0
  240. data/bundle/ruby/{2.5.0/gems/safe_yaml-1.0.4 → 2.7.0/gems/safe_yaml-1.0.5}/lib/safe_yaml/transform/to_integer.rb +0 -0
  241. data/bundle/ruby/{2.5.0/gems/safe_yaml-1.0.4 → 2.7.0/gems/safe_yaml-1.0.5}/lib/safe_yaml/transform/to_nil.rb +0 -0
  242. data/bundle/ruby/{2.5.0/gems/safe_yaml-1.0.4 → 2.7.0/gems/safe_yaml-1.0.5}/lib/safe_yaml/transform/to_symbol.rb +0 -0
  243. data/bundle/ruby/{2.5.0/gems/safe_yaml-1.0.4 → 2.7.0/gems/safe_yaml-1.0.5}/lib/safe_yaml/transform/transformation_map.rb +0 -0
  244. data/bundle/ruby/{2.5.0/gems/safe_yaml-1.0.4 → 2.7.0/gems/safe_yaml-1.0.5}/lib/safe_yaml/version.rb +1 -1
  245. data/bundle/ruby/{2.5.0/gems/safe_yaml-1.0.4 → 2.7.0/gems/safe_yaml-1.0.5}/run_specs_all_ruby_versions.sh +0 -0
  246. data/bundle/ruby/{2.5.0/gems/safe_yaml-1.0.4 → 2.7.0/gems/safe_yaml-1.0.5}/safe_yaml.gemspec +0 -0
  247. data/bundle/ruby/{2.5.0/gems/sexp_processor-4.11.0 → 2.7.0/gems/sexp_processor-4.15.2}/History.rdoc +67 -0
  248. data/bundle/ruby/{2.5.0/gems/sexp_processor-4.11.0 → 2.7.0/gems/sexp_processor-4.15.2}/Manifest.txt +1 -0
  249. data/bundle/ruby/{2.5.0/gems/sexp_processor-4.11.0 → 2.7.0/gems/sexp_processor-4.15.2}/README.rdoc +0 -0
  250. data/bundle/ruby/{2.5.0/gems/sexp_processor-4.11.0 → 2.7.0/gems/sexp_processor-4.15.2}/lib/composite_sexp_processor.rb +0 -0
  251. data/bundle/ruby/{2.5.0/gems/sexp_processor-4.11.0 → 2.7.0/gems/sexp_processor-4.15.2}/lib/pt_testcase.rb +15 -17
  252. data/bundle/ruby/2.7.0/gems/sexp_processor-4.15.2/lib/sexp.rb +381 -0
  253. data/bundle/ruby/{2.5.0/gems/sexp_processor-4.11.0/lib/sexp.rb → 2.7.0/gems/sexp_processor-4.15.2/lib/sexp_matcher.rb} +67 -387
  254. data/bundle/ruby/{2.5.0/gems/sexp_processor-4.11.0 → 2.7.0/gems/sexp_processor-4.15.2}/lib/sexp_processor.rb +2 -2
  255. data/bundle/ruby/{2.5.0/gems/sexp_processor-4.11.0 → 2.7.0/gems/sexp_processor-4.15.2}/lib/strict_sexp.rb +3 -3
  256. data/bundle/ruby/{2.5.0/gems/sexp_processor-4.11.0 → 2.7.0/gems/sexp_processor-4.15.2}/lib/unique.rb +0 -0
  257. data/bundle/ruby/{2.5.0/gems/slim-4.0.1 → 2.7.0/gems/slim-4.1.0}/CHANGES +4 -0
  258. data/bundle/ruby/{2.5.0/gems/slim-4.0.1 → 2.7.0/gems/slim-4.1.0}/Gemfile +12 -13
  259. data/bundle/ruby/{2.5.0/gems/slim-4.0.1 → 2.7.0/gems/slim-4.1.0}/LICENSE +0 -0
  260. data/bundle/ruby/{2.5.0/gems/slim-4.0.1 → 2.7.0/gems/slim-4.1.0}/README.jp.md +0 -0
  261. data/bundle/ruby/{2.5.0/gems/slim-4.0.1 → 2.7.0/gems/slim-4.1.0}/README.md +0 -0
  262. data/bundle/ruby/{2.5.0/gems/slim-4.0.1 → 2.7.0/gems/slim-4.1.0}/lib/slim.rb +0 -0
  263. data/bundle/ruby/{2.5.0/gems/slim-4.0.1 → 2.7.0/gems/slim-4.1.0}/lib/slim/code_attributes.rb +0 -0
  264. data/bundle/ruby/{2.5.0/gems/slim-4.0.1 → 2.7.0/gems/slim-4.1.0}/lib/slim/command.rb +13 -13
  265. data/bundle/ruby/{2.5.0/gems/slim-4.0.1 → 2.7.0/gems/slim-4.1.0}/lib/slim/controls.rb +0 -0
  266. data/bundle/ruby/{2.5.0/gems/slim-4.0.1 → 2.7.0/gems/slim-4.1.0}/lib/slim/do_inserter.rb +0 -0
  267. data/bundle/ruby/{2.5.0/gems/slim-4.0.1 → 2.7.0/gems/slim-4.1.0}/lib/slim/embedded.rb +0 -0
  268. data/bundle/ruby/{2.5.0/gems/slim-4.0.1 → 2.7.0/gems/slim-4.1.0}/lib/slim/end_inserter.rb +0 -0
  269. data/bundle/ruby/{2.5.0/gems/slim-4.0.1 → 2.7.0/gems/slim-4.1.0}/lib/slim/engine.rb +0 -0
  270. data/bundle/ruby/{2.5.0/gems/slim-4.0.1 → 2.7.0/gems/slim-4.1.0}/lib/slim/erb_converter.rb +0 -0
  271. data/bundle/ruby/{2.5.0/gems/slim-4.0.1 → 2.7.0/gems/slim-4.1.0}/lib/slim/filter.rb +0 -0
  272. data/bundle/ruby/{2.5.0/gems/slim-4.0.1 → 2.7.0/gems/slim-4.1.0}/lib/slim/grammar.rb +0 -0
  273. data/bundle/ruby/{2.5.0/gems/slim-4.0.1 → 2.7.0/gems/slim-4.1.0}/lib/slim/include.rb +0 -0
  274. data/bundle/ruby/{2.5.0/gems/slim-4.0.1 → 2.7.0/gems/slim-4.1.0}/lib/slim/interpolation.rb +0 -0
  275. data/bundle/ruby/{2.5.0/gems/slim-4.0.1 → 2.7.0/gems/slim-4.1.0}/lib/slim/logic_less.rb +0 -0
  276. data/bundle/ruby/{2.5.0/gems/slim-4.0.1 → 2.7.0/gems/slim-4.1.0}/lib/slim/logic_less/context.rb +0 -0
  277. data/bundle/ruby/{2.5.0/gems/slim-4.0.1 → 2.7.0/gems/slim-4.1.0}/lib/slim/logic_less/filter.rb +0 -0
  278. data/bundle/ruby/{2.5.0/gems/slim-4.0.1 → 2.7.0/gems/slim-4.1.0}/lib/slim/parser.rb +1 -1
  279. data/bundle/ruby/{2.5.0/gems/slim-4.0.1 → 2.7.0/gems/slim-4.1.0}/lib/slim/smart.rb +0 -0
  280. data/bundle/ruby/{2.5.0/gems/slim-4.0.1 → 2.7.0/gems/slim-4.1.0}/lib/slim/smart/escaper.rb +0 -0
  281. data/bundle/ruby/{2.5.0/gems/slim-4.0.1 → 2.7.0/gems/slim-4.1.0}/lib/slim/smart/filter.rb +0 -0
  282. data/bundle/ruby/{2.5.0/gems/slim-4.0.1 → 2.7.0/gems/slim-4.1.0}/lib/slim/smart/parser.rb +0 -0
  283. data/bundle/ruby/{2.5.0/gems/slim-4.0.1 → 2.7.0/gems/slim-4.1.0}/lib/slim/splat/builder.rb +0 -0
  284. data/bundle/ruby/{2.5.0/gems/slim-4.0.1 → 2.7.0/gems/slim-4.1.0}/lib/slim/splat/filter.rb +0 -0
  285. data/bundle/ruby/{2.5.0/gems/slim-4.0.1 → 2.7.0/gems/slim-4.1.0}/lib/slim/template.rb +0 -0
  286. data/bundle/ruby/{2.5.0/gems/slim-4.0.1 → 2.7.0/gems/slim-4.1.0}/lib/slim/translator.rb +0 -0
  287. data/bundle/ruby/{2.5.0/gems/slim-4.0.1 → 2.7.0/gems/slim-4.1.0}/lib/slim/version.rb +1 -1
  288. data/bundle/ruby/{2.5.0/gems/slim-4.0.1 → 2.7.0/gems/slim-4.1.0}/slim.gemspec +0 -0
  289. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/CHANGES +11 -0
  290. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/EXPRESSIONS.md +1 -1
  291. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/Gemfile +0 -0
  292. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/LICENSE +0 -0
  293. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/README.md +1 -1
  294. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple.rb +0 -0
  295. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple/engine.rb +0 -0
  296. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple/erb/engine.rb +0 -0
  297. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple/erb/parser.rb +0 -0
  298. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple/erb/template.rb +0 -0
  299. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple/erb/trimming.rb +0 -0
  300. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple/exceptions.rb +0 -0
  301. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple/filter.rb +0 -0
  302. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple/filters/code_merger.rb +0 -0
  303. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple/filters/control_flow.rb +0 -0
  304. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple/filters/dynamic_inliner.rb +0 -0
  305. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple/filters/encoding.rb +0 -0
  306. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple/filters/eraser.rb +0 -0
  307. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple/filters/escapable.rb +0 -0
  308. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple/filters/multi_flattener.rb +0 -0
  309. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple/filters/remove_bom.rb +0 -0
  310. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple/filters/static_analyzer.rb +0 -0
  311. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple/filters/static_merger.rb +0 -0
  312. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple/filters/string_splitter.rb +1 -1
  313. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple/filters/validator.rb +0 -0
  314. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple/generator.rb +0 -0
  315. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple/generators/array.rb +0 -0
  316. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple/generators/array_buffer.rb +0 -0
  317. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple/generators/erb.rb +0 -0
  318. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple/generators/rails_output_buffer.rb +0 -0
  319. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple/generators/string_buffer.rb +0 -0
  320. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple/grammar.rb +0 -0
  321. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple/html/attribute_merger.rb +0 -0
  322. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple/html/attribute_remover.rb +0 -0
  323. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple/html/attribute_sorter.rb +0 -0
  324. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple/html/dispatcher.rb +0 -0
  325. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple/html/fast.rb +0 -0
  326. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple/html/filter.rb +0 -0
  327. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple/html/pretty.rb +0 -0
  328. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple/html/safe.rb +0 -0
  329. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple/map.rb +0 -0
  330. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple/mixins/dispatcher.rb +2 -1
  331. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple/mixins/engine_dsl.rb +0 -0
  332. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple/mixins/grammar_dsl.rb +0 -0
  333. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple/mixins/options.rb +0 -0
  334. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple/mixins/template.rb +0 -0
  335. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple/parser.rb +0 -0
  336. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple/static_analyzer.rb +1 -1
  337. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple/templates.rb +0 -0
  338. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple/templates/rails.rb +2 -2
  339. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple/templates/tilt.rb +0 -0
  340. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/lib/temple/utils.rb +0 -0
  341. data/bundle/ruby/2.7.0/gems/temple-0.8.2/lib/temple/version.rb +3 -0
  342. data/bundle/ruby/{2.5.0/gems/temple-0.8.0 → 2.7.0/gems/temple-0.8.2}/temple.gemspec +0 -0
  343. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/terminal-table-1.8.0/Gemfile +0 -0
  344. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/terminal-table-1.8.0/History.rdoc +0 -0
  345. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/terminal-table-1.8.0/LICENSE.txt +0 -0
  346. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/terminal-table-1.8.0/Manifest +0 -0
  347. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/terminal-table-1.8.0/README.rdoc +0 -0
  348. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/terminal-table-1.8.0/Todo.rdoc +0 -0
  349. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/terminal-table-1.8.0/lib/terminal-table.rb +0 -0
  350. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/terminal-table-1.8.0/lib/terminal-table/cell.rb +0 -0
  351. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/terminal-table-1.8.0/lib/terminal-table/import.rb +0 -0
  352. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/terminal-table-1.8.0/lib/terminal-table/row.rb +0 -0
  353. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/terminal-table-1.8.0/lib/terminal-table/separator.rb +0 -0
  354. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/terminal-table-1.8.0/lib/terminal-table/style.rb +0 -0
  355. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/terminal-table-1.8.0/lib/terminal-table/table.rb +0 -0
  356. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/terminal-table-1.8.0/lib/terminal-table/table_helper.rb +0 -0
  357. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/terminal-table-1.8.0/lib/terminal-table/version.rb +0 -0
  358. data/bundle/ruby/{2.5.0 → 2.7.0}/gems/terminal-table-1.8.0/terminal-table.gemspec +0 -0
  359. data/bundle/ruby/{2.5.0/gems/tilt-2.0.9 → 2.7.0/gems/tilt-2.0.10}/COPYING +0 -0
  360. data/bundle/ruby/{2.5.0/gems/tilt-2.0.9 → 2.7.0/gems/tilt-2.0.10}/lib/tilt.rb +1 -1
  361. data/bundle/ruby/{2.5.0/gems/tilt-2.0.9 → 2.7.0/gems/tilt-2.0.10}/lib/tilt/asciidoc.rb +0 -0
  362. data/bundle/ruby/{2.5.0/gems/tilt-2.0.9 → 2.7.0/gems/tilt-2.0.10}/lib/tilt/babel.rb +0 -0
  363. data/bundle/ruby/{2.5.0/gems/tilt-2.0.9 → 2.7.0/gems/tilt-2.0.10}/lib/tilt/bluecloth.rb +0 -0
  364. data/bundle/ruby/{2.5.0/gems/tilt-2.0.9 → 2.7.0/gems/tilt-2.0.10}/lib/tilt/builder.rb +0 -0
  365. data/bundle/ruby/{2.5.0/gems/tilt-2.0.9 → 2.7.0/gems/tilt-2.0.10}/lib/tilt/coffee.rb +0 -0
  366. data/bundle/ruby/{2.5.0/gems/tilt-2.0.9 → 2.7.0/gems/tilt-2.0.10}/lib/tilt/commonmarker.rb +0 -0
  367. data/bundle/ruby/{2.5.0/gems/tilt-2.0.9 → 2.7.0/gems/tilt-2.0.10}/lib/tilt/creole.rb +0 -0
  368. data/bundle/ruby/{2.5.0/gems/tilt-2.0.9 → 2.7.0/gems/tilt-2.0.10}/lib/tilt/csv.rb +0 -0
  369. data/bundle/ruby/{2.5.0/gems/tilt-2.0.9 → 2.7.0/gems/tilt-2.0.10}/lib/tilt/dummy.rb +0 -0
  370. data/bundle/ruby/{2.5.0/gems/tilt-2.0.9 → 2.7.0/gems/tilt-2.0.10}/lib/tilt/erb.rb +0 -0
  371. data/bundle/ruby/{2.5.0/gems/tilt-2.0.9 → 2.7.0/gems/tilt-2.0.10}/lib/tilt/erubi.rb +0 -0
  372. data/bundle/ruby/{2.5.0/gems/tilt-2.0.9 → 2.7.0/gems/tilt-2.0.10}/lib/tilt/erubis.rb +0 -0
  373. data/bundle/ruby/{2.5.0/gems/tilt-2.0.9 → 2.7.0/gems/tilt-2.0.10}/lib/tilt/etanni.rb +0 -0
  374. data/bundle/ruby/{2.5.0/gems/tilt-2.0.9 → 2.7.0/gems/tilt-2.0.10}/lib/tilt/haml.rb +0 -0
  375. data/bundle/ruby/{2.5.0/gems/tilt-2.0.9 → 2.7.0/gems/tilt-2.0.10}/lib/tilt/kramdown.rb +0 -0
  376. data/bundle/ruby/{2.5.0/gems/tilt-2.0.9 → 2.7.0/gems/tilt-2.0.10}/lib/tilt/less.rb +0 -0
  377. data/bundle/ruby/{2.5.0/gems/tilt-2.0.9 → 2.7.0/gems/tilt-2.0.10}/lib/tilt/liquid.rb +0 -0
  378. data/bundle/ruby/{2.5.0/gems/tilt-2.0.9 → 2.7.0/gems/tilt-2.0.10}/lib/tilt/livescript.rb +0 -0
  379. data/bundle/ruby/{2.5.0/gems/tilt-2.0.9 → 2.7.0/gems/tilt-2.0.10}/lib/tilt/mapping.rb +0 -0
  380. data/bundle/ruby/{2.5.0/gems/tilt-2.0.9 → 2.7.0/gems/tilt-2.0.10}/lib/tilt/markaby.rb +0 -0
  381. data/bundle/ruby/{2.5.0/gems/tilt-2.0.9 → 2.7.0/gems/tilt-2.0.10}/lib/tilt/maruku.rb +0 -0
  382. data/bundle/ruby/{2.5.0/gems/tilt-2.0.9 → 2.7.0/gems/tilt-2.0.10}/lib/tilt/nokogiri.rb +0 -0
  383. data/bundle/ruby/{2.5.0/gems/tilt-2.0.9 → 2.7.0/gems/tilt-2.0.10}/lib/tilt/pandoc.rb +0 -0
  384. data/bundle/ruby/{2.5.0/gems/tilt-2.0.9 → 2.7.0/gems/tilt-2.0.10}/lib/tilt/plain.rb +0 -0
  385. data/bundle/ruby/{2.5.0/gems/tilt-2.0.9 → 2.7.0/gems/tilt-2.0.10}/lib/tilt/prawn.rb +0 -0
  386. data/bundle/ruby/{2.5.0/gems/tilt-2.0.9 → 2.7.0/gems/tilt-2.0.10}/lib/tilt/radius.rb +0 -0
  387. data/bundle/ruby/{2.5.0/gems/tilt-2.0.9 → 2.7.0/gems/tilt-2.0.10}/lib/tilt/rdiscount.rb +0 -0
  388. data/bundle/ruby/{2.5.0/gems/tilt-2.0.9 → 2.7.0/gems/tilt-2.0.10}/lib/tilt/rdoc.rb +0 -0
  389. data/bundle/ruby/{2.5.0/gems/tilt-2.0.9 → 2.7.0/gems/tilt-2.0.10}/lib/tilt/redcarpet.rb +0 -0
  390. data/bundle/ruby/{2.5.0/gems/tilt-2.0.9 → 2.7.0/gems/tilt-2.0.10}/lib/tilt/redcloth.rb +0 -0
  391. data/bundle/ruby/{2.5.0/gems/tilt-2.0.9 → 2.7.0/gems/tilt-2.0.10}/lib/tilt/rst-pandoc.rb +0 -0
  392. data/bundle/ruby/{2.5.0/gems/tilt-2.0.9 → 2.7.0/gems/tilt-2.0.10}/lib/tilt/sass.rb +0 -0
  393. data/bundle/ruby/{2.5.0/gems/tilt-2.0.9 → 2.7.0/gems/tilt-2.0.10}/lib/tilt/sigil.rb +0 -0
  394. data/bundle/ruby/{2.5.0/gems/tilt-2.0.9 → 2.7.0/gems/tilt-2.0.10}/lib/tilt/string.rb +0 -0
  395. data/bundle/ruby/{2.5.0/gems/tilt-2.0.9 → 2.7.0/gems/tilt-2.0.10}/lib/tilt/template.rb +7 -12
  396. data/bundle/ruby/{2.5.0/gems/tilt-2.0.9 → 2.7.0/gems/tilt-2.0.10}/lib/tilt/typescript.rb +0 -0
  397. data/bundle/ruby/{2.5.0/gems/tilt-2.0.9 → 2.7.0/gems/tilt-2.0.10}/lib/tilt/wikicloth.rb +0 -0
  398. data/bundle/ruby/{2.5.0/gems/tilt-2.0.9 → 2.7.0/gems/tilt-2.0.10}/lib/tilt/yajl.rb +0 -0
  399. data/bundle/ruby/{2.5.0/gems/unicode-display_width-1.4.1 → 2.7.0/gems/unicode-display_width-1.7.0}/CHANGELOG.md +16 -0
  400. data/bundle/ruby/{2.5.0/gems/unicode-display_width-1.4.1 → 2.7.0/gems/unicode-display_width-1.7.0}/MIT-LICENSE.txt +1 -1
  401. data/bundle/ruby/{2.5.0/gems/unicode-display_width-1.4.1 → 2.7.0/gems/unicode-display_width-1.7.0}/README.md +10 -10
  402. data/bundle/ruby/2.7.0/gems/unicode-display_width-1.7.0/data/display_width.marshal.gz +0 -0
  403. data/bundle/ruby/{2.5.0/gems/unicode-display_width-1.4.1 → 2.7.0/gems/unicode-display_width-1.7.0}/lib/unicode/display_width.rb +1 -1
  404. data/bundle/ruby/{2.5.0/gems/unicode-display_width-1.4.1 → 2.7.0/gems/unicode-display_width-1.7.0}/lib/unicode/display_width/constants.rb +2 -2
  405. data/bundle/ruby/{2.5.0/gems/unicode-display_width-1.4.1 → 2.7.0/gems/unicode-display_width-1.7.0}/lib/unicode/display_width/index.rb +0 -0
  406. data/bundle/ruby/{2.5.0/gems/unicode-display_width-1.4.1 → 2.7.0/gems/unicode-display_width-1.7.0}/lib/unicode/display_width/no_string_ext.rb +0 -0
  407. data/bundle/ruby/{2.5.0/gems/unicode-display_width-1.4.1 → 2.7.0/gems/unicode-display_width-1.7.0}/lib/unicode/display_width/string_ext.rb +0 -0
  408. data/lib/brakeman.rb +37 -0
  409. data/lib/brakeman/app_tree.rb +67 -22
  410. data/lib/brakeman/call_index.rb +54 -15
  411. data/lib/brakeman/checks.rb +7 -7
  412. data/lib/brakeman/checks/base_check.rb +94 -66
  413. data/lib/brakeman/checks/check_basic_auth.rb +2 -0
  414. data/lib/brakeman/checks/check_content_tag.rb +12 -1
  415. data/lib/brakeman/checks/check_cookie_serialization.rb +22 -0
  416. data/lib/brakeman/checks/check_cross_site_scripting.rb +15 -10
  417. data/lib/brakeman/checks/check_csrf_token_forgery_cve.rb +28 -0
  418. data/lib/brakeman/checks/check_default_routes.rb +5 -0
  419. data/lib/brakeman/checks/check_deserialize.rb +70 -1
  420. data/lib/brakeman/checks/check_dynamic_finders.rb +1 -1
  421. data/lib/brakeman/checks/check_evaluation.rb +0 -1
  422. data/lib/brakeman/checks/check_execute.rb +84 -5
  423. data/lib/brakeman/checks/check_file_access.rb +7 -1
  424. data/lib/brakeman/checks/check_force_ssl.rb +27 -0
  425. data/lib/brakeman/checks/check_header_dos.rb +2 -2
  426. data/lib/brakeman/checks/check_i18n_xss.rb +2 -2
  427. data/lib/brakeman/checks/check_jruby_xml.rb +2 -2
  428. data/lib/brakeman/checks/check_json_entity_escape.rb +38 -0
  429. data/lib/brakeman/checks/check_json_parsing.rb +7 -2
  430. data/lib/brakeman/checks/check_link_to.rb +1 -1
  431. data/lib/brakeman/checks/check_link_to_href.rb +7 -4
  432. data/lib/brakeman/checks/check_mail_to.rb +1 -1
  433. data/lib/brakeman/checks/check_mass_assignment.rb +34 -4
  434. data/lib/brakeman/checks/check_mime_type_dos.rb +2 -2
  435. data/lib/brakeman/checks/check_model_attr_accessible.rb +2 -2
  436. data/lib/brakeman/checks/check_model_attributes.rb +13 -51
  437. data/lib/brakeman/checks/check_model_serialize.rb +1 -1
  438. data/lib/brakeman/checks/check_nested_attributes_bypass.rb +4 -4
  439. data/lib/brakeman/checks/check_page_caching_cve.rb +37 -0
  440. data/lib/brakeman/checks/check_permit_attributes.rb +1 -1
  441. data/lib/brakeman/checks/check_regex_dos.rb +1 -1
  442. data/lib/brakeman/checks/check_reverse_tabnabbing.rb +58 -0
  443. data/lib/brakeman/checks/check_sanitize_methods.rb +2 -2
  444. data/lib/brakeman/checks/check_secrets.rb +1 -1
  445. data/lib/brakeman/checks/check_send.rb +0 -1
  446. data/lib/brakeman/checks/check_session_manipulation.rb +0 -1
  447. data/lib/brakeman/checks/check_session_settings.rb +15 -12
  448. data/lib/brakeman/checks/check_simple_format.rb +5 -0
  449. data/lib/brakeman/checks/check_skip_before_filter.rb +5 -5
  450. data/lib/brakeman/checks/check_sql.rb +46 -48
  451. data/lib/brakeman/checks/check_template_injection.rb +32 -0
  452. data/lib/brakeman/checks/check_unsafe_reflection_methods.rb +68 -0
  453. data/lib/brakeman/checks/check_validation_regex.rb +1 -1
  454. data/lib/brakeman/checks/check_verb_confusion.rb +75 -0
  455. data/lib/brakeman/checks/check_xml_dos.rb +2 -2
  456. data/lib/brakeman/checks/check_yaml_parsing.rb +10 -18
  457. data/lib/brakeman/commandline.rb +25 -1
  458. data/lib/brakeman/differ.rb +16 -33
  459. data/lib/brakeman/file_parser.rb +25 -21
  460. data/lib/brakeman/file_path.rb +85 -0
  461. data/lib/brakeman/options.rb +32 -1
  462. data/lib/brakeman/parsers/haml_embedded.rb +44 -0
  463. data/lib/brakeman/parsers/slim_embedded.rb +44 -0
  464. data/lib/brakeman/parsers/template_parser.rb +9 -10
  465. data/lib/brakeman/processor.rb +5 -6
  466. data/lib/brakeman/processors/alias_processor.rb +71 -14
  467. data/lib/brakeman/processors/base_processor.rb +10 -7
  468. data/lib/brakeman/processors/controller_alias_processor.rb +10 -7
  469. data/lib/brakeman/processors/controller_processor.rb +10 -14
  470. data/lib/brakeman/processors/gem_processor.rb +10 -2
  471. data/lib/brakeman/processors/haml_template_processor.rb +99 -123
  472. data/lib/brakeman/processors/lib/call_conversion_helper.rb +10 -5
  473. data/lib/brakeman/processors/lib/file_type_detector.rb +64 -0
  474. data/lib/brakeman/processors/lib/find_all_calls.rb +57 -18
  475. data/lib/brakeman/processors/lib/find_call.rb +3 -64
  476. data/lib/brakeman/processors/lib/module_helper.rb +8 -8
  477. data/lib/brakeman/processors/lib/processor_helper.rb +3 -3
  478. data/lib/brakeman/processors/lib/rails2_config_processor.rb +4 -4
  479. data/lib/brakeman/processors/lib/rails2_route_processor.rb +2 -2
  480. data/lib/brakeman/processors/lib/rails3_config_processor.rb +19 -19
  481. data/lib/brakeman/processors/lib/rails3_route_processor.rb +2 -2
  482. data/lib/brakeman/processors/lib/render_helper.rb +5 -3
  483. data/lib/brakeman/processors/lib/render_path.rb +18 -1
  484. data/lib/brakeman/processors/library_processor.rb +5 -5
  485. data/lib/brakeman/processors/model_processor.rb +4 -5
  486. data/lib/brakeman/processors/output_processor.rb +6 -1
  487. data/lib/brakeman/processors/slim_template_processor.rb +16 -0
  488. data/lib/brakeman/processors/template_alias_processor.rb +36 -4
  489. data/lib/brakeman/processors/template_processor.rb +14 -10
  490. data/lib/brakeman/report.rb +22 -4
  491. data/lib/brakeman/report/ignore/config.rb +12 -5
  492. data/lib/brakeman/report/ignore/interactive.rb +2 -2
  493. data/lib/brakeman/report/pager.rb +1 -0
  494. data/lib/brakeman/report/report_base.rb +51 -8
  495. data/lib/brakeman/report/report_codeclimate.rb +3 -3
  496. data/lib/brakeman/report/report_csv.rb +37 -60
  497. data/lib/brakeman/report/report_hash.rb +1 -1
  498. data/lib/brakeman/report/report_html.rb +2 -2
  499. data/lib/brakeman/report/report_json.rb +1 -24
  500. data/lib/brakeman/report/report_junit.rb +104 -0
  501. data/lib/brakeman/report/report_markdown.rb +0 -1
  502. data/lib/brakeman/report/report_sarif.rb +114 -0
  503. data/lib/brakeman/report/report_sonar.rb +38 -0
  504. data/lib/brakeman/report/report_table.rb +20 -4
  505. data/lib/brakeman/report/report_tabs.rb +1 -1
  506. data/lib/brakeman/report/report_text.rb +43 -23
  507. data/lib/brakeman/rescanner.rb +18 -15
  508. data/lib/brakeman/scanner.rb +70 -35
  509. data/lib/brakeman/tracker.rb +44 -8
  510. data/lib/brakeman/tracker/collection.rb +4 -3
  511. data/lib/brakeman/tracker/config.rb +119 -47
  512. data/lib/brakeman/tracker/constants.rb +10 -8
  513. data/lib/brakeman/tracker/controller.rb +1 -1
  514. data/lib/brakeman/util.rb +45 -151
  515. data/lib/brakeman/version.rb +1 -1
  516. data/lib/brakeman/warning.rb +37 -15
  517. data/lib/brakeman/warning_codes.rb +13 -0
  518. data/lib/ruby_parser/bm_sexp.rb +16 -11
  519. data/lib/ruby_parser/bm_sexp_processor.rb +1 -0
  520. metadata +434 -497
  521. data/bundle/ruby/2.5.0/gems/haml-4.0.7/MIT-LICENSE +0 -20
  522. data/bundle/ruby/2.5.0/gems/haml-4.0.7/lib/haml/compiler.rb +0 -540
  523. data/bundle/ruby/2.5.0/gems/haml-4.0.7/lib/haml/error.rb +0 -61
  524. data/bundle/ruby/2.5.0/gems/haml-4.0.7/lib/haml/railtie.rb +0 -22
  525. data/bundle/ruby/2.5.0/gems/haml-4.0.7/lib/haml/template/plugin.rb +0 -41
  526. data/bundle/ruby/2.5.0/gems/haml-4.0.7/lib/haml/util.rb +0 -377
  527. data/bundle/ruby/2.5.0/gems/haml-4.0.7/lib/haml/version.rb +0 -3
  528. data/bundle/ruby/2.5.0/gems/highline-1.7.10/Gemfile +0 -11
  529. data/bundle/ruby/2.5.0/gems/highline-1.7.10/INSTALL +0 -59
  530. data/bundle/ruby/2.5.0/gems/highline-1.7.10/README.rdoc +0 -74
  531. data/bundle/ruby/2.5.0/gems/highline-1.7.10/highline.gemspec +0 -37
  532. data/bundle/ruby/2.5.0/gems/highline-1.7.10/lib/highline.rb +0 -1048
  533. data/bundle/ruby/2.5.0/gems/highline-1.7.10/lib/highline/compatibility.rb +0 -16
  534. data/bundle/ruby/2.5.0/gems/highline-1.7.10/lib/highline/import.rb +0 -41
  535. data/bundle/ruby/2.5.0/gems/highline-1.7.10/lib/highline/menu.rb +0 -381
  536. data/bundle/ruby/2.5.0/gems/highline-1.7.10/lib/highline/simulate.rb +0 -48
  537. data/bundle/ruby/2.5.0/gems/highline-1.7.10/lib/highline/string_extensions.rb +0 -111
  538. data/bundle/ruby/2.5.0/gems/highline-1.7.10/lib/highline/style.rb +0 -192
  539. data/bundle/ruby/2.5.0/gems/highline-1.7.10/lib/highline/system_extensions.rb +0 -254
  540. data/bundle/ruby/2.5.0/gems/highline-1.7.10/setup.rb +0 -1360
  541. data/bundle/ruby/2.5.0/gems/ruby_parser-3.12.0/lib/ruby20_parser.rb +0 -6687
  542. data/bundle/ruby/2.5.0/gems/ruby_parser-3.12.0/lib/ruby20_parser.y +0 -2345
  543. data/bundle/ruby/2.5.0/gems/ruby_parser-3.12.0/lib/ruby21_parser.rb +0 -6767
  544. data/bundle/ruby/2.5.0/gems/ruby_parser-3.12.0/lib/ruby22_parser.rb +0 -6803
  545. data/bundle/ruby/2.5.0/gems/ruby_parser-3.12.0/lib/ruby23_parser.rb +0 -6818
  546. data/bundle/ruby/2.5.0/gems/ruby_parser-3.12.0/lib/ruby24_parser.rb +0 -6818
  547. data/bundle/ruby/2.5.0/gems/ruby_parser-3.12.0/lib/ruby25_parser.rb +0 -6818
  548. data/bundle/ruby/2.5.0/gems/sass-3.4.25/CODE_OF_CONDUCT.md +0 -10
  549. data/bundle/ruby/2.5.0/gems/sass-3.4.25/CONTRIBUTING.md +0 -148
  550. data/bundle/ruby/2.5.0/gems/sass-3.4.25/MIT-LICENSE +0 -20
  551. data/bundle/ruby/2.5.0/gems/sass-3.4.25/README.md +0 -227
  552. data/bundle/ruby/2.5.0/gems/sass-3.4.25/REVISION +0 -1
  553. data/bundle/ruby/2.5.0/gems/sass-3.4.25/VERSION +0 -1
  554. data/bundle/ruby/2.5.0/gems/sass-3.4.25/VERSION_DATE +0 -1
  555. data/bundle/ruby/2.5.0/gems/sass-3.4.25/VERSION_NAME +0 -1
  556. data/bundle/ruby/2.5.0/gems/sass-3.4.25/extra/sass-spec-ref.sh +0 -32
  557. data/bundle/ruby/2.5.0/gems/sass-3.4.25/extra/update_watch.rb +0 -13
  558. data/bundle/ruby/2.5.0/gems/sass-3.4.25/init.rb +0 -18
  559. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass.rb +0 -109
  560. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/cache_stores.rb +0 -15
  561. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/cache_stores/base.rb +0 -88
  562. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/cache_stores/chain.rb +0 -34
  563. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/cache_stores/filesystem.rb +0 -60
  564. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/cache_stores/memory.rb +0 -46
  565. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/cache_stores/null.rb +0 -25
  566. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/callbacks.rb +0 -67
  567. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/css.rb +0 -408
  568. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/deprecation.rb +0 -55
  569. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/engine.rb +0 -1226
  570. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/environment.rb +0 -215
  571. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/error.rb +0 -198
  572. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/exec.rb +0 -9
  573. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/exec/base.rb +0 -199
  574. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/exec/sass_convert.rb +0 -283
  575. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/exec/sass_scss.rb +0 -440
  576. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/features.rb +0 -47
  577. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/importers.rb +0 -23
  578. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/importers/base.rb +0 -182
  579. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/importers/deprecated_path.rb +0 -51
  580. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/importers/filesystem.rb +0 -219
  581. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/logger.rb +0 -17
  582. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/logger/base.rb +0 -36
  583. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/logger/delayed.rb +0 -50
  584. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/logger/log_level.rb +0 -45
  585. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/media.rb +0 -210
  586. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/plugin.rb +0 -134
  587. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/plugin/compiler.rb +0 -582
  588. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/plugin/configuration.rb +0 -134
  589. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/plugin/generic.rb +0 -15
  590. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/plugin/merb.rb +0 -48
  591. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/plugin/rack.rb +0 -60
  592. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/plugin/rails.rb +0 -47
  593. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/plugin/staleness_checker.rb +0 -199
  594. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/railtie.rb +0 -10
  595. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/repl.rb +0 -57
  596. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/root.rb +0 -7
  597. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/script.rb +0 -66
  598. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/script/css_lexer.rb +0 -33
  599. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/script/css_parser.rb +0 -33
  600. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/script/css_variable_warning.rb +0 -52
  601. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/script/functions.rb +0 -2693
  602. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/script/lexer.rb +0 -464
  603. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/script/parser.rb +0 -832
  604. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/script/tree.rb +0 -16
  605. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/script/tree/funcall.rb +0 -313
  606. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/script/tree/interpolation.rb +0 -223
  607. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/script/tree/list_literal.rb +0 -104
  608. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/script/tree/literal.rb +0 -49
  609. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/script/tree/map_literal.rb +0 -64
  610. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/script/tree/node.rb +0 -127
  611. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/script/tree/operation.rb +0 -156
  612. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/script/tree/selector.rb +0 -26
  613. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/script/tree/string_interpolation.rb +0 -125
  614. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/script/tree/unary_operation.rb +0 -69
  615. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/script/tree/variable.rb +0 -57
  616. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/script/value.rb +0 -11
  617. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/script/value/arg_list.rb +0 -36
  618. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/script/value/base.rb +0 -241
  619. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/script/value/bool.rb +0 -35
  620. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/script/value/color.rb +0 -698
  621. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/script/value/helpers.rb +0 -272
  622. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/script/value/list.rb +0 -113
  623. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/script/value/map.rb +0 -70
  624. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/script/value/null.rb +0 -44
  625. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/script/value/number.rb +0 -563
  626. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/script/value/string.rb +0 -138
  627. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/scss.rb +0 -14
  628. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/scss/css_parser.rb +0 -56
  629. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/scss/parser.rb +0 -1254
  630. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/scss/rx.rb +0 -140
  631. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/scss/static_parser.rb +0 -373
  632. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/selector.rb +0 -323
  633. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/selector/abstract_sequence.rb +0 -111
  634. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/selector/comma_sequence.rb +0 -191
  635. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/selector/pseudo.rb +0 -266
  636. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/selector/sequence.rb +0 -636
  637. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/selector/simple.rb +0 -117
  638. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/selector/simple_sequence.rb +0 -344
  639. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/shared.rb +0 -76
  640. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/source/map.rb +0 -213
  641. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/source/position.rb +0 -39
  642. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/source/range.rb +0 -41
  643. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/stack.rb +0 -120
  644. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/supports.rb +0 -225
  645. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/tree/at_root_node.rb +0 -83
  646. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/tree/charset_node.rb +0 -22
  647. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/tree/comment_node.rb +0 -82
  648. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/tree/content_node.rb +0 -9
  649. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/tree/css_import_node.rb +0 -68
  650. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/tree/debug_node.rb +0 -18
  651. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/tree/directive_node.rb +0 -59
  652. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/tree/each_node.rb +0 -24
  653. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/tree/error_node.rb +0 -18
  654. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/tree/extend_node.rb +0 -43
  655. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/tree/for_node.rb +0 -36
  656. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/tree/function_node.rb +0 -44
  657. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/tree/if_node.rb +0 -52
  658. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/tree/import_node.rb +0 -75
  659. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/tree/keyframe_rule_node.rb +0 -15
  660. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/tree/media_node.rb +0 -48
  661. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/tree/mixin_def_node.rb +0 -38
  662. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/tree/mixin_node.rb +0 -52
  663. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/tree/node.rb +0 -240
  664. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/tree/prop_node.rb +0 -170
  665. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/tree/return_node.rb +0 -19
  666. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/tree/root_node.rb +0 -44
  667. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/tree/rule_node.rb +0 -155
  668. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/tree/supports_node.rb +0 -38
  669. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/tree/trace_node.rb +0 -33
  670. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/tree/variable_node.rb +0 -36
  671. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/tree/visitors/base.rb +0 -72
  672. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/tree/visitors/check_nesting.rb +0 -173
  673. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/tree/visitors/convert.rb +0 -351
  674. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/tree/visitors/cssize.rb +0 -373
  675. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/tree/visitors/deep_copy.rb +0 -107
  676. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/tree/visitors/extend.rb +0 -70
  677. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/tree/visitors/perform.rb +0 -564
  678. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/tree/visitors/set_options.rb +0 -139
  679. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/tree/visitors/to_css.rb +0 -409
  680. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/tree/warn_node.rb +0 -18
  681. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/tree/while_node.rb +0 -18
  682. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/util.rb +0 -1375
  683. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/util/cross_platform_random.rb +0 -19
  684. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/util/multibyte_string_scanner.rb +0 -155
  685. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/util/normalized_map.rb +0 -129
  686. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/util/ordered_hash.rb +0 -192
  687. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/util/subset_map.rb +0 -109
  688. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/util/test.rb +0 -9
  689. data/bundle/ruby/2.5.0/gems/sass-3.4.25/lib/sass/version.rb +0 -124
  690. data/bundle/ruby/2.5.0/gems/sass-3.4.25/rails/init.rb +0 -1
  691. data/bundle/ruby/2.5.0/gems/sass-3.4.25/vendor/listen/CHANGELOG.md +0 -1
  692. data/bundle/ruby/2.5.0/gems/sass-3.4.25/vendor/listen/CONTRIBUTING.md +0 -38
  693. data/bundle/ruby/2.5.0/gems/sass-3.4.25/vendor/listen/Gemfile +0 -20
  694. data/bundle/ruby/2.5.0/gems/sass-3.4.25/vendor/listen/Guardfile +0 -8
  695. data/bundle/ruby/2.5.0/gems/sass-3.4.25/vendor/listen/README.md +0 -349
  696. data/bundle/ruby/2.5.0/gems/sass-3.4.25/vendor/listen/Rakefile +0 -5
  697. data/bundle/ruby/2.5.0/gems/sass-3.4.25/vendor/listen/Vagrantfile +0 -96
  698. data/bundle/ruby/2.5.0/gems/sass-3.4.25/vendor/listen/lib/listen.rb +0 -54
  699. data/bundle/ruby/2.5.0/gems/sass-3.4.25/vendor/listen/lib/listen/adapter.rb +0 -327
  700. data/bundle/ruby/2.5.0/gems/sass-3.4.25/vendor/listen/lib/listen/adapters/bsd.rb +0 -75
  701. data/bundle/ruby/2.5.0/gems/sass-3.4.25/vendor/listen/lib/listen/adapters/darwin.rb +0 -48
  702. data/bundle/ruby/2.5.0/gems/sass-3.4.25/vendor/listen/lib/listen/adapters/linux.rb +0 -81
  703. data/bundle/ruby/2.5.0/gems/sass-3.4.25/vendor/listen/lib/listen/adapters/polling.rb +0 -58
  704. data/bundle/ruby/2.5.0/gems/sass-3.4.25/vendor/listen/lib/listen/adapters/windows.rb +0 -91
  705. data/bundle/ruby/2.5.0/gems/sass-3.4.25/vendor/listen/lib/listen/directory_record.rb +0 -406
  706. data/bundle/ruby/2.5.0/gems/sass-3.4.25/vendor/listen/lib/listen/listener.rb +0 -323
  707. data/bundle/ruby/2.5.0/gems/sass-3.4.25/vendor/listen/lib/listen/turnstile.rb +0 -32
  708. data/bundle/ruby/2.5.0/gems/sass-3.4.25/vendor/listen/lib/listen/version.rb +0 -3
  709. data/bundle/ruby/2.5.0/gems/sass-3.4.25/vendor/listen/listen.gemspec +0 -28
  710. data/bundle/ruby/2.5.0/gems/sass-3.4.25/vendor/listen/spec/listen/adapter_spec.rb +0 -149
  711. data/bundle/ruby/2.5.0/gems/sass-3.4.25/vendor/listen/spec/listen/adapters/bsd_spec.rb +0 -36
  712. data/bundle/ruby/2.5.0/gems/sass-3.4.25/vendor/listen/spec/listen/adapters/darwin_spec.rb +0 -37
  713. data/bundle/ruby/2.5.0/gems/sass-3.4.25/vendor/listen/spec/listen/adapters/linux_spec.rb +0 -47
  714. data/bundle/ruby/2.5.0/gems/sass-3.4.25/vendor/listen/spec/listen/adapters/polling_spec.rb +0 -68
  715. data/bundle/ruby/2.5.0/gems/sass-3.4.25/vendor/listen/spec/listen/adapters/windows_spec.rb +0 -30
  716. data/bundle/ruby/2.5.0/gems/sass-3.4.25/vendor/listen/spec/listen/directory_record_spec.rb +0 -1250
  717. data/bundle/ruby/2.5.0/gems/sass-3.4.25/vendor/listen/spec/listen/listener_spec.rb +0 -258
  718. data/bundle/ruby/2.5.0/gems/sass-3.4.25/vendor/listen/spec/listen/turnstile_spec.rb +0 -56
  719. data/bundle/ruby/2.5.0/gems/sass-3.4.25/vendor/listen/spec/listen_spec.rb +0 -67
  720. data/bundle/ruby/2.5.0/gems/sass-3.4.25/vendor/listen/spec/spec_helper.rb +0 -25
  721. data/bundle/ruby/2.5.0/gems/sass-3.4.25/vendor/listen/spec/support/adapter_helper.rb +0 -666
  722. data/bundle/ruby/2.5.0/gems/sass-3.4.25/vendor/listen/spec/support/directory_record_helper.rb +0 -57
  723. data/bundle/ruby/2.5.0/gems/sass-3.4.25/vendor/listen/spec/support/fixtures_helper.rb +0 -29
  724. data/bundle/ruby/2.5.0/gems/sass-3.4.25/vendor/listen/spec/support/listeners_helper.rb +0 -179
  725. data/bundle/ruby/2.5.0/gems/sass-3.4.25/vendor/listen/spec/support/platform_helper.rb +0 -15
  726. data/bundle/ruby/2.5.0/gems/temple-0.8.0/lib/temple/version.rb +0 -3
  727. data/bundle/ruby/2.5.0/gems/tilt-2.0.9/CHANGELOG.md +0 -132
  728. data/bundle/ruby/2.5.0/gems/tilt-2.0.9/Gemfile +0 -70
  729. data/bundle/ruby/2.5.0/gems/tilt-2.0.9/HACKING +0 -16
  730. data/bundle/ruby/2.5.0/gems/tilt-2.0.9/README.md +0 -233
  731. data/bundle/ruby/2.5.0/gems/tilt-2.0.9/tilt.gemspec +0 -130
  732. data/bundle/ruby/2.5.0/gems/unicode-display_width-1.4.1/data/display_width.marshal.gz +0 -0
@@ -1,18 +0,0 @@
1
- module Sass
2
- module Tree
3
- # A dynamic node representing a Sass `@warn` statement.
4
- #
5
- # @see Sass::Tree
6
- class WarnNode < Node
7
- # The expression to print.
8
- # @return [Script::Tree::Node]
9
- attr_accessor :expr
10
-
11
- # @param expr [Script::Tree::Node] The expression to print
12
- def initialize(expr)
13
- @expr = expr
14
- super()
15
- end
16
- end
17
- end
18
- end
@@ -1,18 +0,0 @@
1
- require 'sass/tree/node'
2
-
3
- module Sass::Tree
4
- # A dynamic node representing a Sass `@while` loop.
5
- #
6
- # @see Sass::Tree
7
- class WhileNode < Node
8
- # The parse tree for the continuation expression.
9
- # @return [Script::Tree::Node]
10
- attr_accessor :expr
11
-
12
- # @param expr [Script::Tree::Node] See \{#expr}
13
- def initialize(expr)
14
- @expr = expr
15
- super()
16
- end
17
- end
18
- end
@@ -1,1375 +0,0 @@
1
- # -*- coding: utf-8 -*-
2
- require 'erb'
3
- require 'set'
4
- require 'enumerator'
5
- require 'stringio'
6
- require 'rbconfig'
7
- require 'uri'
8
- require 'thread'
9
- require 'pathname'
10
-
11
- require 'sass/root'
12
- require 'sass/util/subset_map'
13
-
14
- module Sass
15
- # A module containing various useful functions.
16
- # @comment
17
- # rubocop:disable ModuleLength
18
- module Util
19
- extend self
20
-
21
- # An array of ints representing the Ruby version number.
22
- # @api public
23
- RUBY_VERSION_COMPONENTS = RUBY_VERSION.split(".").map {|s| s.to_i}
24
-
25
- # The Ruby engine we're running under. Defaults to `"ruby"`
26
- # if the top-level constant is undefined.
27
- # @api public
28
- RUBY_ENGINE = defined?(::RUBY_ENGINE) ? ::RUBY_ENGINE : "ruby"
29
-
30
- # Returns the path of a file relative to the Sass root directory.
31
- #
32
- # @param file [String] The filename relative to the Sass root
33
- # @return [String] The filename relative to the the working directory
34
- def scope(file)
35
- File.join(Sass::ROOT_DIR, file)
36
- end
37
-
38
- # Converts an array of `[key, value]` pairs to a hash.
39
- #
40
- # @example
41
- # to_hash([[:foo, "bar"], [:baz, "bang"]])
42
- # #=> {:foo => "bar", :baz => "bang"}
43
- # @param arr [Array<(Object, Object)>] An array of pairs
44
- # @return [Hash] A hash
45
- def to_hash(arr)
46
- ordered_hash(*arr.compact)
47
- end
48
-
49
- # Maps the keys in a hash according to a block.
50
- #
51
- # @example
52
- # map_keys({:foo => "bar", :baz => "bang"}) {|k| k.to_s}
53
- # #=> {"foo" => "bar", "baz" => "bang"}
54
- # @param hash [Hash] The hash to map
55
- # @yield [key] A block in which the keys are transformed
56
- # @yieldparam key [Object] The key that should be mapped
57
- # @yieldreturn [Object] The new value for the key
58
- # @return [Hash] The mapped hash
59
- # @see #map_vals
60
- # @see #map_hash
61
- def map_keys(hash)
62
- map_hash(hash) {|k, v| [yield(k), v]}
63
- end
64
-
65
- # Maps the values in a hash according to a block.
66
- #
67
- # @example
68
- # map_values({:foo => "bar", :baz => "bang"}) {|v| v.to_sym}
69
- # #=> {:foo => :bar, :baz => :bang}
70
- # @param hash [Hash] The hash to map
71
- # @yield [value] A block in which the values are transformed
72
- # @yieldparam value [Object] The value that should be mapped
73
- # @yieldreturn [Object] The new value for the value
74
- # @return [Hash] The mapped hash
75
- # @see #map_keys
76
- # @see #map_hash
77
- def map_vals(hash)
78
- # We don't delegate to map_hash for performance here
79
- # because map_hash does more than is necessary.
80
- rv = hash.class.new
81
- hash = hash.as_stored if hash.is_a?(NormalizedMap)
82
- hash.each do |k, v|
83
- rv[k] = yield(v)
84
- end
85
- rv
86
- end
87
-
88
- # Maps the key-value pairs of a hash according to a block.
89
- #
90
- # @example
91
- # map_hash({:foo => "bar", :baz => "bang"}) {|k, v| [k.to_s, v.to_sym]}
92
- # #=> {"foo" => :bar, "baz" => :bang}
93
- # @param hash [Hash] The hash to map
94
- # @yield [key, value] A block in which the key-value pairs are transformed
95
- # @yieldparam [key] The hash key
96
- # @yieldparam [value] The hash value
97
- # @yieldreturn [(Object, Object)] The new value for the `[key, value]` pair
98
- # @return [Hash] The mapped hash
99
- # @see #map_keys
100
- # @see #map_vals
101
- def map_hash(hash)
102
- # Copy and modify is more performant than mapping to an array and using
103
- # to_hash on the result.
104
- rv = hash.class.new
105
- hash.each do |k, v|
106
- new_key, new_value = yield(k, v)
107
- new_key = hash.denormalize(new_key) if hash.is_a?(NormalizedMap) && new_key == k
108
- rv[new_key] = new_value
109
- end
110
- rv
111
- end
112
-
113
- # Computes the powerset of the given array.
114
- # This is the set of all subsets of the array.
115
- #
116
- # @example
117
- # powerset([1, 2, 3]) #=>
118
- # Set[Set[], Set[1], Set[2], Set[3], Set[1, 2], Set[2, 3], Set[1, 3], Set[1, 2, 3]]
119
- # @param arr [Enumerable]
120
- # @return [Set<Set>] The subsets of `arr`
121
- def powerset(arr)
122
- arr.inject([Set.new].to_set) do |powerset, el|
123
- new_powerset = Set.new
124
- powerset.each do |subset|
125
- new_powerset << subset
126
- new_powerset << subset + [el]
127
- end
128
- new_powerset
129
- end
130
- end
131
-
132
- # Restricts a number to falling within a given range.
133
- # Returns the number if it falls within the range,
134
- # or the closest value in the range if it doesn't.
135
- #
136
- # @param value [Numeric]
137
- # @param range [Range<Numeric>]
138
- # @return [Numeric]
139
- def restrict(value, range)
140
- [[value, range.first].max, range.last].min
141
- end
142
-
143
- # Like [Fixnum.round], but leaves rooms for slight floating-point
144
- # differences.
145
- #
146
- # @param value [Numeric]
147
- # @return [Numeric]
148
- def round(value)
149
- # If the number is within epsilon of X.5, round up (or down for negative
150
- # numbers).
151
- return value.round if (value % 1) - 0.5 <= -1 * Script::Value::Number.epsilon
152
- value > 0 ? value.ceil : value.floor
153
- end
154
-
155
- # Concatenates all strings that are adjacent in an array,
156
- # while leaving other elements as they are.
157
- #
158
- # @example
159
- # merge_adjacent_strings([1, "foo", "bar", 2, "baz"])
160
- # #=> [1, "foobar", 2, "baz"]
161
- # @param arr [Array]
162
- # @return [Array] The enumerable with strings merged
163
- def merge_adjacent_strings(arr)
164
- # Optimize for the common case of one element
165
- return arr if arr.size < 2
166
- arr.inject([]) do |a, e|
167
- if e.is_a?(String)
168
- if a.last.is_a?(String)
169
- a.last << e
170
- else
171
- a << e.dup
172
- end
173
- else
174
- a << e
175
- end
176
- a
177
- end
178
- end
179
-
180
- # Non-destructively replaces all occurrences of a subsequence in an array
181
- # with another subsequence.
182
- #
183
- # @example
184
- # replace_subseq([1, 2, 3, 4, 5], [2, 3], [:a, :b])
185
- # #=> [1, :a, :b, 4, 5]
186
- #
187
- # @param arr [Array] The array whose subsequences will be replaced.
188
- # @param subseq [Array] The subsequence to find and replace.
189
- # @param replacement [Array] The sequence that `subseq` will be replaced with.
190
- # @return [Array] `arr` with `subseq` replaced with `replacement`.
191
- def replace_subseq(arr, subseq, replacement)
192
- new = []
193
- matched = []
194
- i = 0
195
- arr.each do |elem|
196
- if elem != subseq[i]
197
- new.push(*matched)
198
- matched = []
199
- i = 0
200
- new << elem
201
- next
202
- end
203
-
204
- if i == subseq.length - 1
205
- matched = []
206
- i = 0
207
- new.push(*replacement)
208
- else
209
- matched << elem
210
- i += 1
211
- end
212
- end
213
- new.push(*matched)
214
- new
215
- end
216
-
217
- # Intersperses a value in an enumerable, as would be done with `Array#join`
218
- # but without concatenating the array together afterwards.
219
- #
220
- # @param enum [Enumerable]
221
- # @param val
222
- # @return [Array]
223
- def intersperse(enum, val)
224
- enum.inject([]) {|a, e| a << e << val}[0...-1]
225
- end
226
-
227
- def slice_by(enum)
228
- results = []
229
- enum.each do |value|
230
- key = yield(value)
231
- if !results.empty? && results.last.first == key
232
- results.last.last << value
233
- else
234
- results << [key, [value]]
235
- end
236
- end
237
- results
238
- end
239
-
240
- # Substitutes a sub-array of one array with another sub-array.
241
- #
242
- # @param ary [Array] The array in which to make the substitution
243
- # @param from [Array] The sequence of elements to replace with `to`
244
- # @param to [Array] The sequence of elements to replace `from` with
245
- def substitute(ary, from, to)
246
- res = ary.dup
247
- i = 0
248
- while i < res.size
249
- if res[i...i + from.size] == from
250
- res[i...i + from.size] = to
251
- end
252
- i += 1
253
- end
254
- res
255
- end
256
-
257
- # Destructively strips whitespace from the beginning and end
258
- # of the first and last elements, respectively,
259
- # in the array (if those elements are strings).
260
- #
261
- # @param arr [Array]
262
- # @return [Array] `arr`
263
- def strip_string_array(arr)
264
- arr.first.lstrip! if arr.first.is_a?(String)
265
- arr.last.rstrip! if arr.last.is_a?(String)
266
- arr
267
- end
268
-
269
- # Return an array of all possible paths through the given arrays.
270
- #
271
- # @param arrs [Array<Array>]
272
- # @return [Array<Arrays>]
273
- #
274
- # @example
275
- # paths([[1, 2], [3, 4], [5]]) #=>
276
- # # [[1, 3, 5],
277
- # # [2, 3, 5],
278
- # # [1, 4, 5],
279
- # # [2, 4, 5]]
280
- def paths(arrs)
281
- arrs.inject([[]]) do |paths, arr|
282
- arr.map {|e| paths.map {|path| path + [e]}}.flatten(1)
283
- end
284
- end
285
-
286
- # Computes a single longest common subsequence for `x` and `y`.
287
- # If there are more than one longest common subsequences,
288
- # the one returned is that which starts first in `x`.
289
- #
290
- # @param x [Array]
291
- # @param y [Array]
292
- # @yield [a, b] An optional block to use in place of a check for equality
293
- # between elements of `x` and `y`.
294
- # @yieldreturn [Object, nil] If the two values register as equal,
295
- # this will return the value to use in the LCS array.
296
- # @return [Array] The LCS
297
- def lcs(x, y, &block)
298
- x = [nil, *x]
299
- y = [nil, *y]
300
- block ||= proc {|a, b| a == b && a}
301
- lcs_backtrace(lcs_table(x, y, &block), x, y, x.size - 1, y.size - 1, &block)
302
- end
303
-
304
- # Converts a Hash to an Array. This is usually identical to `Hash#to_a`,
305
- # with the following exceptions:
306
- #
307
- # * In Ruby 1.8, `Hash#to_a` is not deterministically ordered, but this is.
308
- # * In Ruby 1.9 when running tests, this is ordered in the same way it would
309
- # be under Ruby 1.8 (sorted key order rather than insertion order).
310
- #
311
- # @param hash [Hash]
312
- # @return [Array]
313
- def hash_to_a(hash)
314
- return hash.to_a unless ruby1_8? || defined?(Test::Unit)
315
- hash.sort_by {|k, _v| k}
316
- end
317
-
318
- # Performs the equivalent of `enum.group_by.to_a`, but with a guaranteed
319
- # order. Unlike {Util#hash_to_a}, the resulting order isn't sorted key order;
320
- # instead, it's the same order as `#group_by` has under Ruby 1.9 (key
321
- # appearance order).
322
- #
323
- # @param enum [Enumerable]
324
- # @return [Array<[Object, Array]>] An array of pairs.
325
- def group_by_to_a(enum)
326
- return enum.group_by {|e| yield(e)}.to_a unless ruby1_8?
327
- order = {}
328
- arr = []
329
- groups = enum.group_by do |e|
330
- res = yield(e)
331
- unless order.include?(res)
332
- order[res] = order.size
333
- end
334
- res
335
- end
336
- groups.each do |key, vals|
337
- arr[order[key]] = [key, vals]
338
- end
339
- arr
340
- end
341
-
342
- # Like `String.upcase`, but only ever upcases ASCII letters.
343
- def upcase(string)
344
- return string.upcase unless ruby2_4?
345
- string.upcase(:ascii)
346
- end
347
-
348
- # Like `String.downcase`, but only ever downcases ASCII letters.
349
- def downcase(string)
350
- return string.downcase unless ruby2_4?
351
- string.downcase(:ascii)
352
- end
353
-
354
- # Returns a sub-array of `minuend` containing only elements that are also in
355
- # `subtrahend`. Ensures that the return value has the same order as
356
- # `minuend`, even on Rubinius where that's not guaranteed by `Array#-`.
357
- #
358
- # @param minuend [Array]
359
- # @param subtrahend [Array]
360
- # @return [Array]
361
- def array_minus(minuend, subtrahend)
362
- return minuend - subtrahend unless rbx?
363
- set = Set.new(minuend) - subtrahend
364
- minuend.select {|e| set.include?(e)}
365
- end
366
-
367
- # Returns the maximum of `val1` and `val2`. We use this over \{Array.max} to
368
- # avoid unnecessary garbage collection.
369
- def max(val1, val2)
370
- val1 > val2 ? val1 : val2
371
- end
372
-
373
- # Returns the minimum of `val1` and `val2`. We use this over \{Array.min} to
374
- # avoid unnecessary garbage collection.
375
- def min(val1, val2)
376
- val1 <= val2 ? val1 : val2
377
- end
378
-
379
- # Returns a string description of the character that caused an
380
- # `Encoding::UndefinedConversionError`.
381
- #
382
- # @param e [Encoding::UndefinedConversionError]
383
- # @return [String]
384
- def undefined_conversion_error_char(e)
385
- # Rubinius (as of 2.0.0.rc1) pre-quotes the error character.
386
- return e.error_char if rbx?
387
- # JRuby (as of 1.7.2) doesn't have an error_char field on
388
- # Encoding::UndefinedConversionError.
389
- return e.error_char.dump unless jruby?
390
- e.message[/^"[^"]+"/] # "
391
- end
392
-
393
- # Asserts that `value` falls within `range` (inclusive), leaving
394
- # room for slight floating-point errors.
395
- #
396
- # @param name [String] The name of the value. Used in the error message.
397
- # @param range [Range] The allowed range of values.
398
- # @param value [Numeric, Sass::Script::Value::Number] The value to check.
399
- # @param unit [String] The unit of the value. Used in error reporting.
400
- # @return [Numeric] `value` adjusted to fall within range, if it
401
- # was outside by a floating-point margin.
402
- def check_range(name, range, value, unit = '')
403
- grace = (-0.00001..0.00001)
404
- str = value.to_s
405
- value = value.value if value.is_a?(Sass::Script::Value::Number)
406
- return value if range.include?(value)
407
- return range.first if grace.include?(value - range.first)
408
- return range.last if grace.include?(value - range.last)
409
- raise ArgumentError.new(
410
- "#{name} #{str} must be between #{range.first}#{unit} and #{range.last}#{unit}")
411
- end
412
-
413
- # Returns whether or not `seq1` is a subsequence of `seq2`. That is, whether
414
- # or not `seq2` contains every element in `seq1` in the same order (and
415
- # possibly more elements besides).
416
- #
417
- # @param seq1 [Array]
418
- # @param seq2 [Array]
419
- # @return [Boolean]
420
- def subsequence?(seq1, seq2)
421
- i = j = 0
422
- loop do
423
- return true if i == seq1.size
424
- return false if j == seq2.size
425
- i += 1 if seq1[i] == seq2[j]
426
- j += 1
427
- end
428
- end
429
-
430
- # Returns information about the caller of the previous method.
431
- #
432
- # @param entry [String] An entry in the `#caller` list, or a similarly formatted string
433
- # @return [[String, Integer, (String, nil)]]
434
- # An array containing the filename, line, and method name of the caller.
435
- # The method name may be nil
436
- def caller_info(entry = nil)
437
- # JRuby evaluates `caller` incorrectly when it's in an actual default argument.
438
- entry ||= caller[1]
439
- info = entry.scan(/^((?:[A-Za-z]:)?.*?):(-?.*?)(?::.*`(.+)')?$/).first
440
- info[1] = info[1].to_i
441
- # This is added by Rubinius to designate a block, but we don't care about it.
442
- info[2].sub!(/ \{\}\Z/, '') if info[2]
443
- info
444
- end
445
-
446
- # Returns whether one version string represents a more recent version than another.
447
- #
448
- # @param v1 [String] A version string.
449
- # @param v2 [String] Another version string.
450
- # @return [Boolean]
451
- def version_gt(v1, v2)
452
- # Construct an array to make sure the shorter version is padded with nil
453
- Array.new([v1.length, v2.length].max).zip(v1.split("."), v2.split(".")) do |_, p1, p2|
454
- p1 ||= "0"
455
- p2 ||= "0"
456
- release1 = p1 =~ /^[0-9]+$/
457
- release2 = p2 =~ /^[0-9]+$/
458
- if release1 && release2
459
- # Integer comparison if both are full releases
460
- p1, p2 = p1.to_i, p2.to_i
461
- next if p1 == p2
462
- return p1 > p2
463
- elsif !release1 && !release2
464
- # String comparison if both are prereleases
465
- next if p1 == p2
466
- return p1 > p2
467
- else
468
- # If only one is a release, that one is newer
469
- return release1
470
- end
471
- end
472
- end
473
-
474
- # Returns whether one version string represents the same or a more
475
- # recent version than another.
476
- #
477
- # @param v1 [String] A version string.
478
- # @param v2 [String] Another version string.
479
- # @return [Boolean]
480
- def version_geq(v1, v2)
481
- version_gt(v1, v2) || !version_gt(v2, v1)
482
- end
483
-
484
- # Throws a NotImplementedError for an abstract method.
485
- #
486
- # @param obj [Object] `self`
487
- # @raise [NotImplementedError]
488
- def abstract(obj)
489
- raise NotImplementedError.new("#{obj.class} must implement ##{caller_info[2]}")
490
- end
491
-
492
- # Prints a deprecation warning for the caller method.
493
- #
494
- # @param obj [Object] `self`
495
- # @param message [String] A message describing what to do instead.
496
- def deprecated(obj, message = nil)
497
- obj_class = obj.is_a?(Class) ? "#{obj}." : "#{obj.class}#"
498
- full_message = "DEPRECATION WARNING: #{obj_class}#{caller_info[2]} " +
499
- "will be removed in a future version of Sass.#{("\n" + message) if message}"
500
- Sass::Util.sass_warn full_message
501
- end
502
-
503
- # Silence all output to STDERR within a block.
504
- #
505
- # @yield A block in which no output will be printed to STDERR
506
- def silence_warnings
507
- the_real_stderr, $stderr = $stderr, StringIO.new
508
- yield
509
- ensure
510
- $stderr = the_real_stderr
511
- end
512
-
513
- # Silences all Sass warnings within a block.
514
- #
515
- # @yield A block in which no Sass warnings will be printed
516
- def silence_sass_warnings
517
- old_level, Sass.logger.log_level = Sass.logger.log_level, :error
518
- yield
519
- ensure
520
- Sass.logger.log_level = old_level
521
- end
522
-
523
- # The same as `Kernel#warn`, but is silenced by \{#silence\_sass\_warnings}.
524
- #
525
- # @param msg [String]
526
- def sass_warn(msg)
527
- msg += "\n" unless ruby1?
528
- Sass.logger.warn(msg)
529
- end
530
-
531
- ## Cross Rails Version Compatibility
532
-
533
- # Returns the root of the Rails application,
534
- # if this is running in a Rails context.
535
- # Returns `nil` if no such root is defined.
536
- #
537
- # @return [String, nil]
538
- def rails_root
539
- if defined?(::Rails.root)
540
- return ::Rails.root.to_s if ::Rails.root
541
- raise "ERROR: Rails.root is nil!"
542
- end
543
- return RAILS_ROOT.to_s if defined?(RAILS_ROOT)
544
- nil
545
- end
546
-
547
- # Returns the environment of the Rails application,
548
- # if this is running in a Rails context.
549
- # Returns `nil` if no such environment is defined.
550
- #
551
- # @return [String, nil]
552
- def rails_env
553
- return ::Rails.env.to_s if defined?(::Rails.env)
554
- return RAILS_ENV.to_s if defined?(RAILS_ENV)
555
- nil
556
- end
557
-
558
- # Returns whether this environment is using ActionPack
559
- # version 3.0.0 or greater.
560
- #
561
- # @return [Boolean]
562
- def ap_geq_3?
563
- ap_geq?("3.0.0.beta1")
564
- end
565
-
566
- # Returns whether this environment is using ActionPack
567
- # of a version greater than or equal to that specified.
568
- #
569
- # @param version [String] The string version number to check against.
570
- # Should be greater than or equal to Rails 3,
571
- # because otherwise ActionPack::VERSION isn't autoloaded
572
- # @return [Boolean]
573
- def ap_geq?(version)
574
- # The ActionPack module is always loaded automatically in Rails >= 3
575
- return false unless defined?(ActionPack) && defined?(ActionPack::VERSION) &&
576
- defined?(ActionPack::VERSION::STRING)
577
-
578
- version_geq(ActionPack::VERSION::STRING, version)
579
- end
580
-
581
- # Returns whether this environment is using Listen
582
- # version 2.0.0 or greater.
583
- #
584
- # @return [Boolean]
585
- def listen_geq_2?
586
- return @listen_geq_2 if defined?(@listen_geq_2)
587
- @listen_geq_2 =
588
- begin
589
- # Make sure we're loading listen/version from the same place that
590
- # we're loading listen itself.
591
- load_listen!
592
- require 'listen/version'
593
- version_geq(::Listen::VERSION, '2.0.0')
594
- rescue LoadError
595
- false
596
- end
597
- end
598
-
599
- # Returns an ActionView::Template* class.
600
- # In pre-3.0 versions of Rails, most of these classes
601
- # were of the form `ActionView::TemplateFoo`,
602
- # while afterwards they were of the form `ActionView;:Template::Foo`.
603
- #
604
- # @param name [#to_s] The name of the class to get.
605
- # For example, `:Error` will return `ActionView::TemplateError`
606
- # or `ActionView::Template::Error`.
607
- def av_template_class(name)
608
- return ActionView.const_get("Template#{name}") if ActionView.const_defined?("Template#{name}")
609
- ActionView::Template.const_get(name.to_s)
610
- end
611
-
612
- ## Cross-OS Compatibility
613
- #
614
- # These methods are cached because some of them are called quite frequently
615
- # and even basic checks like String#== are too costly to be called repeatedly.
616
-
617
- # Whether or not this is running on Windows.
618
- #
619
- # @return [Boolean]
620
- def windows?
621
- return @windows if defined?(@windows)
622
- @windows = (RbConfig::CONFIG['host_os'] =~ /mswin|windows|mingw/i)
623
- end
624
-
625
- # Whether or not this is running on IronRuby.
626
- #
627
- # @return [Boolean]
628
- def ironruby?
629
- return @ironruby if defined?(@ironruby)
630
- @ironruby = RUBY_ENGINE == "ironruby"
631
- end
632
-
633
- # Whether or not this is running on Rubinius.
634
- #
635
- # @return [Boolean]
636
- def rbx?
637
- return @rbx if defined?(@rbx)
638
- @rbx = RUBY_ENGINE == "rbx"
639
- end
640
-
641
- # Whether or not this is running on JRuby.
642
- #
643
- # @return [Boolean]
644
- def jruby?
645
- return @jruby if defined?(@jruby)
646
- @jruby = RUBY_PLATFORM =~ /java/
647
- end
648
-
649
- # Returns an array of ints representing the JRuby version number.
650
- #
651
- # @return [Array<Integer>]
652
- def jruby_version
653
- @jruby_version ||= ::JRUBY_VERSION.split(".").map {|s| s.to_i}
654
- end
655
-
656
- # Like `Dir.glob`, but works with backslash-separated paths on Windows.
657
- #
658
- # @param path [String]
659
- def glob(path)
660
- path = path.tr('\\', '/') if windows?
661
- if block_given?
662
- Dir.glob(path) {|f| yield(f)}
663
- else
664
- Dir.glob(path)
665
- end
666
- end
667
-
668
- # Like `Pathname.new`, but normalizes Windows paths to always use backslash
669
- # separators.
670
- #
671
- # `Pathname#relative_path_from` can break if the two pathnames aren't
672
- # consistent in their slash style.
673
- #
674
- # @param path [String]
675
- # @return [Pathname]
676
- def pathname(path)
677
- path = path.tr("/", "\\") if windows?
678
- Pathname.new(path)
679
- end
680
-
681
- # Like `Pathname#cleanpath`, but normalizes Windows paths to always use
682
- # backslash separators. Normally, `Pathname#cleanpath` actually does the
683
- # reverse -- it will convert backslashes to forward slashes, which can break
684
- # `Pathname#relative_path_from`.
685
- #
686
- # @param path [String, Pathname]
687
- # @return [Pathname]
688
- def cleanpath(path)
689
- path = Pathname.new(path) unless path.is_a?(Pathname)
690
- pathname(path.cleanpath.to_s)
691
- end
692
-
693
- # Returns `path` with all symlinks resolved.
694
- #
695
- # @param path [String, Pathname]
696
- # @return [Pathname]
697
- def realpath(path)
698
- path = Pathname.new(path) unless path.is_a?(Pathname)
699
-
700
- # Explicitly DON'T run #pathname here. We don't want to convert
701
- # to Windows directory separators because we're comparing these
702
- # against the paths returned by Listen, which use forward
703
- # slashes everywhere.
704
- begin
705
- path.realpath
706
- rescue SystemCallError
707
- # If [path] doesn't actually exist, don't bail, just
708
- # return the original.
709
- path
710
- end
711
- end
712
-
713
- # Returns `path` relative to `from`.
714
- #
715
- # This is like `Pathname#relative_path_from` except it accepts both strings
716
- # and pathnames, it handles Windows path separators correctly, and it throws
717
- # an error rather than crashing if the paths use different encodings
718
- # (https://github.com/ruby/ruby/pull/713).
719
- #
720
- # @param path [String, Pathname]
721
- # @param from [String, Pathname]
722
- # @return [Pathname?]
723
- def relative_path_from(path, from)
724
- pathname(path.to_s).relative_path_from(pathname(from.to_s))
725
- rescue NoMethodError => e
726
- raise e unless e.name == :zero?
727
-
728
- # Work around https://github.com/ruby/ruby/pull/713.
729
- path = path.to_s
730
- from = from.to_s
731
- raise ArgumentError("Incompatible path encodings: #{path.inspect} is #{path.encoding}, " +
732
- "#{from.inspect} is #{from.encoding}")
733
- end
734
-
735
- # Converts `path` to a "file:" URI. This handles Windows paths correctly.
736
- #
737
- # @param path [String, Pathname]
738
- # @return [String]
739
- def file_uri_from_path(path)
740
- path = path.to_s if path.is_a?(Pathname)
741
- path = path.tr('\\', '/') if windows?
742
- path = Sass::Util.escape_uri(path)
743
- return path.start_with?('/') ? "file://" + path : path unless windows?
744
- return "file:///" + path.tr("\\", "/") if path =~ %r{^[a-zA-Z]:[/\\]}
745
- return "file:" + path.tr("\\", "/") if path =~ %r{\\\\[^\\]+\\[^\\/]+}
746
- path.tr("\\", "/")
747
- end
748
-
749
- # Retries a filesystem operation if it fails on Windows. Windows
750
- # has weird and flaky locking rules that can cause operations to fail.
751
- #
752
- # @yield [] The filesystem operation.
753
- def retry_on_windows
754
- return yield unless windows?
755
-
756
- begin
757
- yield
758
- rescue SystemCallError
759
- sleep 0.1
760
- yield
761
- end
762
- end
763
-
764
- # Prepare a value for a destructuring assignment (e.g. `a, b =
765
- # val`). This works around a performance bug when using
766
- # ActiveSupport, and only needs to be called when `val` is likely
767
- # to be `nil` reasonably often.
768
- #
769
- # See [this bug report](http://redmine.ruby-lang.org/issues/4917).
770
- #
771
- # @param val [Object]
772
- # @return [Object]
773
- def destructure(val)
774
- val || []
775
- end
776
-
777
- ## Cross-Ruby-Version Compatibility
778
-
779
- # Whether or not this is running under a Ruby version under 2.0.
780
- #
781
- # @return [Boolean]
782
- def ruby1?
783
- return @ruby1 if defined?(@ruby1)
784
- @ruby1 = RUBY_VERSION_COMPONENTS[0] <= 1
785
- end
786
-
787
- # Whether or not this is running under Ruby 1.8 or lower.
788
- #
789
- # Note that IronRuby counts as Ruby 1.8,
790
- # because it doesn't support the Ruby 1.9 encoding API.
791
- #
792
- # @return [Boolean]
793
- def ruby1_8?
794
- # IronRuby says its version is 1.9, but doesn't support any of the encoding APIs.
795
- # We have to fall back to 1.8 behavior.
796
- return @ruby1_8 if defined?(@ruby1_8)
797
- @ruby1_8 = ironruby? ||
798
- (RUBY_VERSION_COMPONENTS[0] == 1 && RUBY_VERSION_COMPONENTS[1] < 9)
799
- end
800
-
801
- # Whether or not this is running under Ruby 1.9.2 exactly.
802
- #
803
- # @return [Boolean]
804
- def ruby1_9_2?
805
- return @ruby1_9_2 if defined?(@ruby1_9_2)
806
- @ruby1_9_2 = RUBY_VERSION_COMPONENTS == [1, 9, 2]
807
- end
808
-
809
- # Whether or not this is running under Ruby 2.4 or higher.
810
- #
811
- # @return [Boolean]
812
- def ruby2_4?
813
- return @ruby2_4 if defined?(@ruby2_4)
814
- @ruby2_4 =
815
- if RUBY_VERSION_COMPONENTS[0] == 2
816
- RUBY_VERSION_COMPONENTS[1] >= 4
817
- else
818
- RUBY_VERSION_COMPONENTS[0] > 2
819
- end
820
- end
821
-
822
- # Wehter or not this is running under JRuby 1.6 or lower.
823
- def jruby1_6?
824
- return @jruby1_6 if defined?(@jruby1_6)
825
- @jruby1_6 = jruby? && jruby_version[0] == 1 && jruby_version[1] < 7
826
- end
827
-
828
- # Whether or not this is running under MacRuby.
829
- #
830
- # @return [Boolean]
831
- def macruby?
832
- return @macruby if defined?(@macruby)
833
- @macruby = RUBY_ENGINE == 'macruby'
834
- end
835
-
836
- require 'sass/util/ordered_hash' if ruby1_8?
837
-
838
- # Converts a hash or a list of pairs into an order-preserving hash.
839
- #
840
- # On Ruby 1.8.7, this uses the orderedhash gem to simulate an
841
- # order-preserving hash. On Ruby 1.9 and up, it just uses the native Hash
842
- # class, since that preserves the order itself.
843
- #
844
- # @overload ordered_hash(hash)
845
- # @param hash [Hash] a normal hash to convert to an ordered hash
846
- # @return [Hash]
847
- # @overload ordered_hash(*pairs)
848
- # @example
849
- # ordered_hash([:foo, "bar"], [:baz, "bang"])
850
- # #=> {:foo => "bar", :baz => "bang"}
851
- # ordered_hash #=> {}
852
- # @param pairs [Array<(Object, Object)>] the list of key/value pairs for
853
- # the hash.
854
- # @return [Hash]
855
- def ordered_hash(*pairs_or_hash)
856
- if pairs_or_hash.length == 1 && pairs_or_hash.first.is_a?(Hash)
857
- hash = pairs_or_hash.first
858
- return hash unless ruby1_8?
859
- return OrderedHash.new.merge hash
860
- end
861
-
862
- return Hash[pairs_or_hash] unless ruby1_8?
863
- (pairs_or_hash.is_a?(NormalizedMap) ? NormalizedMap : OrderedHash)[*pairs_or_hash.flatten(1)]
864
- end
865
-
866
- unless ruby1_8?
867
- CHARSET_REGEXP = /\A@charset "([^"]+)"/
868
- bom = "\uFEFF"
869
- UTF_8_BOM = bom.encode("UTF-8").force_encoding('BINARY')
870
- UTF_16BE_BOM = bom.encode("UTF-16BE").force_encoding('BINARY')
871
- UTF_16LE_BOM = bom.encode("UTF-16LE").force_encoding('BINARY')
872
- end
873
-
874
- # Like {\#check\_encoding}, but also checks for a `@charset` declaration
875
- # at the beginning of the file and uses that encoding if it exists.
876
- #
877
- # Sass follows CSS's decoding rules.
878
- #
879
- # @param str [String] The string of which to check the encoding
880
- # @return [(String, Encoding)] The original string encoded as UTF-8,
881
- # and the source encoding of the string (or `nil` under Ruby 1.8)
882
- # @raise [Encoding::UndefinedConversionError] if the source encoding
883
- # cannot be converted to UTF-8
884
- # @raise [ArgumentError] if the document uses an unknown encoding with `@charset`
885
- # @raise [Sass::SyntaxError] If the document declares an encoding that
886
- # doesn't match its contents, or it doesn't declare an encoding and its
887
- # contents are invalid in the native encoding.
888
- def check_sass_encoding(str)
889
- # On Ruby 1.8 we can't do anything complicated with encodings.
890
- # Instead, we just strip out a UTF-8 BOM if it exists and
891
- # sanitize according to Section 3.3 of CSS Syntax Level 3. We
892
- # don't sanitize null characters since they might be components
893
- # of other characters.
894
- if ruby1_8?
895
- return str.gsub(/\A\xEF\xBB\xBF/, '').gsub(/\r\n?|\f/, "\n"), nil
896
- end
897
-
898
- # Determine the fallback encoding following section 3.2 of CSS Syntax Level 3 and Encodings:
899
- # http://www.w3.org/TR/2013/WD-css-syntax-3-20130919/#determine-the-fallback-encoding
900
- # http://encoding.spec.whatwg.org/#decode
901
- binary = str.dup.force_encoding("BINARY")
902
- if binary.start_with?(UTF_8_BOM)
903
- binary.slice! 0, UTF_8_BOM.length
904
- str = binary.force_encoding('UTF-8')
905
- elsif binary.start_with?(UTF_16BE_BOM)
906
- binary.slice! 0, UTF_16BE_BOM.length
907
- str = binary.force_encoding('UTF-16BE')
908
- elsif binary.start_with?(UTF_16LE_BOM)
909
- binary.slice! 0, UTF_16LE_BOM.length
910
- str = binary.force_encoding('UTF-16LE')
911
- elsif binary =~ CHARSET_REGEXP
912
- charset = $1.force_encoding('US-ASCII')
913
- # Ruby 1.9.2 doesn't recognize a UTF-16 encoding without an endian marker.
914
- if ruby1_9_2? && charset.downcase == 'utf-16'
915
- encoding = Encoding.find('UTF-8')
916
- else
917
- encoding = Encoding.find(charset)
918
- if encoding.name == 'UTF-16' || encoding.name == 'UTF-16BE'
919
- encoding = Encoding.find('UTF-8')
920
- end
921
- end
922
- str = binary.force_encoding(encoding)
923
- elsif str.encoding.name == "ASCII-8BIT"
924
- # Normally we want to fall back on believing the Ruby string
925
- # encoding, but if that's just binary we want to make sure
926
- # it's valid UTF-8.
927
- str = str.force_encoding('utf-8')
928
- end
929
-
930
- find_encoding_error(str) unless str.valid_encoding?
931
-
932
- begin
933
- # If the string is valid, preprocess it according to section 3.3 of CSS Syntax Level 3.
934
- return str.encode("UTF-8").gsub(/\r\n?|\f/, "\n").tr("\u0000", "�"), str.encoding
935
- rescue EncodingError
936
- find_encoding_error(str)
937
- end
938
- end
939
-
940
- # Checks to see if a class has a given method.
941
- # For example:
942
- #
943
- # Sass::Util.has?(:public_instance_method, String, :gsub) #=> true
944
- #
945
- # Method collections like `Class#instance_methods`
946
- # return strings in Ruby 1.8 and symbols in Ruby 1.9 and on,
947
- # so this handles checking for them in a compatible way.
948
- #
949
- # @param attr [#to_s] The (singular) name of the method-collection method
950
- # (e.g. `:instance_methods`, `:private_methods`)
951
- # @param klass [Module] The class to check the methods of which to check
952
- # @param method [String, Symbol] The name of the method do check for
953
- # @return [Boolean] Whether or not the given collection has the given method
954
- def has?(attr, klass, method)
955
- klass.send("#{attr}s").include?(ruby1_8? ? method.to_s : method.to_sym)
956
- end
957
-
958
- # A version of `Enumerable#enum_with_index` that works in Ruby 1.8 and 1.9.
959
- #
960
- # @param enum [Enumerable] The enumerable to get the enumerator for
961
- # @return [Enumerator] The with-index enumerator
962
- def enum_with_index(enum)
963
- ruby1_8? ? enum.enum_with_index : enum.each_with_index
964
- end
965
-
966
- # A version of `Enumerable#enum_cons` that works in Ruby 1.8 and 1.9.
967
- #
968
- # @param enum [Enumerable] The enumerable to get the enumerator for
969
- # @param n [Integer] The size of each cons
970
- # @return [Enumerator] The consed enumerator
971
- def enum_cons(enum, n)
972
- ruby1_8? ? enum.enum_cons(n) : enum.each_cons(n)
973
- end
974
-
975
- # A version of `Enumerable#enum_slice` that works in Ruby 1.8 and 1.9.
976
- #
977
- # @param enum [Enumerable] The enumerable to get the enumerator for
978
- # @param n [Integer] The size of each slice
979
- # @return [Enumerator] The consed enumerator
980
- def enum_slice(enum, n)
981
- ruby1_8? ? enum.enum_slice(n) : enum.each_slice(n)
982
- end
983
-
984
- # Destructively removes all elements from an array that match a block, and
985
- # returns the removed elements.
986
- #
987
- # @param array [Array] The array from which to remove elements.
988
- # @yield [el] Called for each element.
989
- # @yieldparam el [*] The element to test.
990
- # @yieldreturn [Boolean] Whether or not to extract the element.
991
- # @return [Array] The extracted elements.
992
- def extract!(array)
993
- out = []
994
- array.reject! do |e|
995
- next false unless yield e
996
- out << e
997
- true
998
- end
999
- out
1000
- end
1001
-
1002
- # Returns the ASCII code of the given character.
1003
- #
1004
- # @param c [String] All characters but the first are ignored.
1005
- # @return [Integer] The ASCII code of `c`.
1006
- def ord(c)
1007
- ruby1_8? ? c[0] : c.ord
1008
- end
1009
-
1010
- # Flattens the first level of nested arrays in `arrs`. Unlike
1011
- # `Array#flatten`, this orders the result by taking the first
1012
- # values from each array in order, then the second, and so on.
1013
- #
1014
- # @param arrs [Array] The array to flatten.
1015
- # @return [Array] The flattened array.
1016
- def flatten_vertically(arrs)
1017
- result = []
1018
- arrs = arrs.map {|sub| sub.is_a?(Array) ? sub.dup : Array(sub)}
1019
- until arrs.empty?
1020
- arrs.reject! do |arr|
1021
- result << arr.shift
1022
- arr.empty?
1023
- end
1024
- end
1025
- result
1026
- end
1027
-
1028
- # Like `Object#inspect`, but preserves non-ASCII characters rather than
1029
- # escaping them under Ruby 1.9.2. This is necessary so that the
1030
- # precompiled Haml template can be `#encode`d into `@options[:encoding]`
1031
- # before being evaluated.
1032
- #
1033
- # @param obj {Object}
1034
- # @return {String}
1035
- def inspect_obj(obj)
1036
- return obj.inspect unless version_geq(RUBY_VERSION, "1.9.2")
1037
- return ':' + inspect_obj(obj.to_s) if obj.is_a?(Symbol)
1038
- return obj.inspect unless obj.is_a?(String)
1039
- '"' + obj.gsub(/[\x00-\x7F]+/) {|s| s.inspect[1...-1]} + '"'
1040
- end
1041
-
1042
- # Extracts the non-string vlaues from an array containing both strings and non-strings.
1043
- # These values are replaced with escape sequences.
1044
- # This can be undone using \{#inject\_values}.
1045
- #
1046
- # This is useful e.g. when we want to do string manipulation
1047
- # on an interpolated string.
1048
- #
1049
- # The precise format of the resulting string is not guaranteed.
1050
- # However, it is guaranteed that newlines and whitespace won't be affected.
1051
- #
1052
- # @param arr [Array] The array from which values are extracted.
1053
- # @return [(String, Array)] The resulting string, and an array of extracted values.
1054
- def extract_values(arr)
1055
- values = []
1056
- mapped = arr.map do |e|
1057
- next e.gsub('{', '{{') if e.is_a?(String)
1058
- values << e
1059
- next "{#{values.count - 1}}"
1060
- end
1061
- return mapped.join, values
1062
- end
1063
-
1064
- # Undoes \{#extract\_values} by transforming a string with escape sequences
1065
- # into an array of strings and non-string values.
1066
- #
1067
- # @param str [String] The string with escape sequences.
1068
- # @param values [Array] The array of values to inject.
1069
- # @return [Array] The array of strings and values.
1070
- def inject_values(str, values)
1071
- return [str.gsub('{{', '{')] if values.empty?
1072
- # Add an extra { so that we process the tail end of the string
1073
- result = (str + '{{').scan(/(.*?)(?:(\{\{)|\{(\d+)\})/m).map do |(pre, esc, n)|
1074
- [pre, esc ? '{' : '', n ? values[n.to_i] : '']
1075
- end.flatten(1)
1076
- result[-2] = '' # Get rid of the extra {
1077
- merge_adjacent_strings(result).reject {|s| s == ''}
1078
- end
1079
-
1080
- # Allows modifications to be performed on the string form
1081
- # of an array containing both strings and non-strings.
1082
- #
1083
- # @param arr [Array] The array from which values are extracted.
1084
- # @yield [str] A block in which string manipulation can be done to the array.
1085
- # @yieldparam str [String] The string form of `arr`.
1086
- # @yieldreturn [String] The modified string.
1087
- # @return [Array] The modified, interpolated array.
1088
- def with_extracted_values(arr)
1089
- str, vals = extract_values(arr)
1090
- str = yield str
1091
- inject_values(str, vals)
1092
- end
1093
-
1094
- # Builds a sourcemap file name given the generated CSS file name.
1095
- #
1096
- # @param css [String] The generated CSS file name.
1097
- # @return [String] The source map file name.
1098
- def sourcemap_name(css)
1099
- css + ".map"
1100
- end
1101
-
1102
- # Escapes certain characters so that the result can be used
1103
- # as the JSON string value. Returns the original string if
1104
- # no escaping is necessary.
1105
- #
1106
- # @param s [String] The string to be escaped
1107
- # @return [String] The escaped string
1108
- def json_escape_string(s)
1109
- return s if s !~ /["\\\b\f\n\r\t]/
1110
-
1111
- result = ""
1112
- s.split("").each do |c|
1113
- case c
1114
- when '"', "\\"
1115
- result << "\\" << c
1116
- when "\n" then result << "\\n"
1117
- when "\t" then result << "\\t"
1118
- when "\r" then result << "\\r"
1119
- when "\f" then result << "\\f"
1120
- when "\b" then result << "\\b"
1121
- else
1122
- result << c
1123
- end
1124
- end
1125
- result
1126
- end
1127
-
1128
- # Converts the argument into a valid JSON value.
1129
- #
1130
- # @param v [Integer, String, Array, Boolean, nil]
1131
- # @return [String]
1132
- def json_value_of(v)
1133
- case v
1134
- when Integer
1135
- v.to_s
1136
- when String
1137
- "\"" + json_escape_string(v) + "\""
1138
- when Array
1139
- "[" + v.map {|x| json_value_of(x)}.join(",") + "]"
1140
- when NilClass
1141
- "null"
1142
- when TrueClass
1143
- "true"
1144
- when FalseClass
1145
- "false"
1146
- else
1147
- raise ArgumentError.new("Unknown type: #{v.class.name}")
1148
- end
1149
- end
1150
-
1151
- VLQ_BASE_SHIFT = 5
1152
- VLQ_BASE = 1 << VLQ_BASE_SHIFT
1153
- VLQ_BASE_MASK = VLQ_BASE - 1
1154
- VLQ_CONTINUATION_BIT = VLQ_BASE
1155
-
1156
- BASE64_DIGITS = ('A'..'Z').to_a + ('a'..'z').to_a + ('0'..'9').to_a + ['+', '/']
1157
- BASE64_DIGIT_MAP = begin
1158
- map = {}
1159
- Sass::Util.enum_with_index(BASE64_DIGITS).map do |digit, i|
1160
- map[digit] = i
1161
- end
1162
- map
1163
- end
1164
-
1165
- # Encodes `value` as VLQ (http://en.wikipedia.org/wiki/VLQ).
1166
- #
1167
- # @param value [Integer]
1168
- # @return [String] The encoded value
1169
- def encode_vlq(value)
1170
- if value < 0
1171
- value = ((-value) << 1) | 1
1172
- else
1173
- value <<= 1
1174
- end
1175
-
1176
- result = ''
1177
- begin
1178
- digit = value & VLQ_BASE_MASK
1179
- value >>= VLQ_BASE_SHIFT
1180
- if value > 0
1181
- digit |= VLQ_CONTINUATION_BIT
1182
- end
1183
- result << BASE64_DIGITS[digit]
1184
- end while value > 0
1185
- result
1186
- end
1187
-
1188
- # This is a hack around the fact that you can't instantiate a URI parser on
1189
- # 1.8, so we have to have this hacky stuff to work around it. When 1.8
1190
- # support is dropped, we can remove this method.
1191
- #
1192
- # @private
1193
- URI_ESCAPE = URI.const_defined?("DEFAULT_PARSER") ? URI::DEFAULT_PARSER : URI
1194
-
1195
- # URI-escape `string`.
1196
- #
1197
- # @param string [String]
1198
- # @return [String]
1199
- def escape_uri(string)
1200
- URI_ESCAPE.escape string
1201
- end
1202
-
1203
- # A cross-platform implementation of `File.absolute_path`.
1204
- #
1205
- # @param path [String]
1206
- # @param dir_string [String] The directory to consider [path] relative to.
1207
- # @return [String] The absolute version of `path`.
1208
- def absolute_path(path, dir_string = nil)
1209
- # Ruby 1.8 doesn't support File.absolute_path.
1210
- return File.absolute_path(path, dir_string) unless ruby1_8?
1211
-
1212
- # File.expand_path expands "~", which we don't want.
1213
- return File.expand_path(path, dir_string) unless path[0] == ?~
1214
- File.expand_path(File.join(".", path), dir_string)
1215
- end
1216
-
1217
- ## Static Method Stuff
1218
-
1219
- # The context in which the ERB for \{#def\_static\_method} will be run.
1220
- class StaticConditionalContext
1221
- # @param set [#include?] The set of variables that are defined for this context.
1222
- def initialize(set)
1223
- @set = set
1224
- end
1225
-
1226
- # Checks whether or not a variable is defined for this context.
1227
- #
1228
- # @param name [Symbol] The name of the variable
1229
- # @return [Boolean]
1230
- def method_missing(name, *args)
1231
- super unless args.empty? && !block_given?
1232
- @set.include?(name)
1233
- end
1234
- end
1235
-
1236
- # @private
1237
- ATOMIC_WRITE_MUTEX = Mutex.new
1238
-
1239
- # This creates a temp file and yields it for writing. When the
1240
- # write is complete, the file is moved into the desired location.
1241
- # The atomicity of this operation is provided by the filesystem's
1242
- # rename operation.
1243
- #
1244
- # @param filename [String] The file to write to.
1245
- # @param perms [Integer] The permissions used for creating this file.
1246
- # Will be masked by the process umask. Defaults to readable/writeable
1247
- # by all users however the umask usually changes this to only be writable
1248
- # by the process's user.
1249
- # @yieldparam tmpfile [Tempfile] The temp file that can be written to.
1250
- # @return The value returned by the block.
1251
- def atomic_create_and_write_file(filename, perms = 0666)
1252
- require 'tempfile'
1253
- tmpfile = Tempfile.new(File.basename(filename), File.dirname(filename))
1254
- tmpfile.binmode if tmpfile.respond_to?(:binmode)
1255
- result = yield tmpfile
1256
- tmpfile.close
1257
- ATOMIC_WRITE_MUTEX.synchronize do
1258
- begin
1259
- File.chmod(perms & ~File.umask, tmpfile.path)
1260
- rescue Errno::EPERM
1261
- # If we don't have permissions to chmod the file, don't let that crash
1262
- # the compilation. See issue 1215.
1263
- end
1264
- File.rename tmpfile.path, filename
1265
- end
1266
- result
1267
- ensure
1268
- # close and remove the tempfile if it still exists,
1269
- # presumably due to an error during write
1270
- tmpfile.close if tmpfile
1271
- tmpfile.unlink if tmpfile
1272
- end
1273
-
1274
- def load_listen!
1275
- if defined?(gem)
1276
- begin
1277
- gem 'listen', '>= 1.1.0', '< 3.0.0'
1278
- require 'listen'
1279
- rescue Gem::LoadError
1280
- dir = scope("vendor/listen/lib")
1281
- $LOAD_PATH.unshift dir
1282
- begin
1283
- require 'listen'
1284
- rescue LoadError => e
1285
- if version_geq(RUBY_VERSION, "1.9.3")
1286
- version_constraint = "~> 3.0"
1287
- else
1288
- version_constraint = "~> 1.1"
1289
- end
1290
- e.message << "\n" <<
1291
- "Run \"gem install listen --version '#{version_constraint}'\" to get it."
1292
- raise e
1293
- end
1294
- end
1295
- else
1296
- begin
1297
- require 'listen'
1298
- rescue LoadError => e
1299
- dir = scope("vendor/listen/lib")
1300
- if $LOAD_PATH.include?(dir)
1301
- raise e unless File.exist?(scope(".git"))
1302
- e.message << "\n" <<
1303
- 'Run "git submodule update --init" to get the bundled version.'
1304
- else
1305
- $LOAD_PATH.unshift dir
1306
- retry
1307
- end
1308
- end
1309
- end
1310
- end
1311
-
1312
- private
1313
-
1314
- def find_encoding_error(str)
1315
- encoding = str.encoding
1316
- cr = Regexp.quote("\r".encode(encoding).force_encoding('BINARY'))
1317
- lf = Regexp.quote("\n".encode(encoding).force_encoding('BINARY'))
1318
- ff = Regexp.quote("\f".encode(encoding).force_encoding('BINARY'))
1319
- line_break = /#{cr}#{lf}?|#{ff}|#{lf}/
1320
-
1321
- str.force_encoding("binary").split(line_break).each_with_index do |line, i|
1322
- begin
1323
- line.encode(encoding)
1324
- rescue Encoding::UndefinedConversionError => e
1325
- raise Sass::SyntaxError.new(
1326
- "Invalid #{encoding.name} character #{undefined_conversion_error_char(e)}",
1327
- :line => i + 1)
1328
- end
1329
- end
1330
-
1331
- # We shouldn't get here, but it's possible some weird encoding stuff causes it.
1332
- return str, str.encoding
1333
- end
1334
-
1335
- # Calculates the memoization table for the Least Common Subsequence algorithm.
1336
- # Algorithm from [Wikipedia](http://en.wikipedia.org/wiki/Longest_common_subsequence_problem#Computing_the_length_of_the_LCS)
1337
- def lcs_table(x, y)
1338
- # This method does not take a block as an explicit parameter for performance reasons.
1339
- c = Array.new(x.size) {[]}
1340
- x.size.times {|i| c[i][0] = 0}
1341
- y.size.times {|j| c[0][j] = 0}
1342
- (1...x.size).each do |i|
1343
- (1...y.size).each do |j|
1344
- c[i][j] =
1345
- if yield x[i], y[j]
1346
- c[i - 1][j - 1] + 1
1347
- else
1348
- [c[i][j - 1], c[i - 1][j]].max
1349
- end
1350
- end
1351
- end
1352
- c
1353
- end
1354
- # rubocop:disable ParameterLists
1355
-
1356
- # Computes a single longest common subsequence for arrays x and y.
1357
- # Algorithm from [Wikipedia](http://en.wikipedia.org/wiki/Longest_common_subsequence_problem#Reading_out_an_LCS)
1358
- def lcs_backtrace(c, x, y, i, j, &block)
1359
- # rubocop:enable ParameterList
1360
- return [] if i == 0 || j == 0
1361
- if (v = yield(x[i], y[j]))
1362
- return lcs_backtrace(c, x, y, i - 1, j - 1, &block) << v
1363
- end
1364
-
1365
- return lcs_backtrace(c, x, y, i, j - 1, &block) if c[i][j - 1] > c[i - 1][j]
1366
- lcs_backtrace(c, x, y, i - 1, j, &block)
1367
- end
1368
-
1369
- singleton_methods.each {|method| module_function method}
1370
- end
1371
- end
1372
-
1373
- require 'sass/util/multibyte_string_scanner'
1374
- require 'sass/util/normalized_map'
1375
- require 'sass/util/cross_platform_random'