ruby-beautify
ruby-beautify copied to clipboard
a cli tool to beautify ruby output to screen.
`#!/usr/bin/env ruby puts "hola" ` root#[ /home/linkedsoul/spykit/forensic/Exiftool_ruby ]> ruby-beautify helloworld.rb EXPR_BEGEXPR_CMDARGEXPR_CMDARGEXPR_CMDARGEXPR_CMDARGEXPR_END|EXPR_ENDARGEXPR_BEGEXPR_BEGEXPR_BEG
after upgrade to ruby 2.5.0 i'm getting rubbish with .rb files like this EXPR_BEGEXPR_BEGEXPR_CMDARGEXPR_BEG EXPR_BEGEXPR_CLASSEXPR_CLASSEXPR_BEGEXPR_BEGEXPR_ENDEXPR_BEG EXPR_BEGEXPR_FNAMEEXPR_FNAMEEXPR_ENDFNEXPR_BEG|EXPR_LABELEXPR_ARGEXPR_ENDFNEXPR_BEG EXPR_BEGEXPR_CMDARGEXPR_CMDARGEXPR_BEGEXPR_BEGEXPR_ARGEXPR_DOTEXPR_ARGEXPR_BEG|EXPR_LABELEXPR_ARG|EXPR_LABELEDEXPR_ARG|EXPR_LABELEDEXPR_END|EXPR_LABELEXPR_DOTEXPR_ARGEXPR_BEG|EXPR_LABELEXPR_BEG|EXPR_LABELEXPR_ARG|EXPR_LABELEDEXPR_ARG|EXPR_LABELEDEXPR_END|EXPR_ENDARGEXPR_ENDFNEXPR_DOTEXPR_ARGEXPR_BEG EXPR_BEGEXPR_BEGEXPR_BEGEXPR_END|EXPR_LABELEXPR_DOTEXPR_ARGEXPR_BEG EXPR_BEGEXPR_BEGEXPR_BEGEXPR_END|
I think this is somewhat related to #24 : The gem does this: ``` puts "Hi there " + "Whatever " + "yay!" puts "Hi there ", "Whatever ", "yay!"...
When invoking `ruby-beautify -c 2 -s`, I run into the following: Expected: ```ruby module Foo def self.bar foo + 'bar' end private_class_method def self.foo 'foo' end end ``` Received: ```ruby...
Fixes #45
The current method is very problematic, because it expects `ruby` command on the PATH. There may not be any, for example when user has only JRuby installed, or it may...
Hey Everybody, Thought I would chime in and let everybody know that I'm planning on rewriting this to leverage the rubocop app, while still allowing for the same behavior currently...
I encountered invalid results. ``` >rbeautify ident2.rb ..............ruby/lib/ruby/gems/2.2.0/gems/rbeautify-0.0.7/lib/rbeautify.rb:115: warning: character class has duplicated range: /.*=\s*
When I have this code, it's all ok: def my_function array = [{ }] end But, when I change to this: def my_function array = [{ } ] end That...