The results of beautification are not what I expect.
I'm work with rbenv and I did gem install robucop and it did not work.
This is what the code looked like before:
class BookInStock
def initialize(isbn, price)
@isbn = isbn
@price = Float(price)
end
def to_s
"ISBN: #{@isbn}, price: #{@price}"
end
end
The beautified code should have looked like this:
class BookInStock
def initialize(isbn, price)
@isbn = isbn
@price = Float(price)
end
def to_s
"ISBN: #{@isbn}, price: #{@price}"
end
end
The beautified code actually looked like this:

Could not find 'rubocop'. The program may not be installed.
Atom Beautify: Beautify EditorHere is a link to the debug.md Gist:
GIST
I have:
Atom Beautify: Help Debug Editor command in Atom and added link for debug.md Gist to this issuehaving the same issue. When I try and run
gem install rubocop
I get the following:
// ♥ gem install rubocop
Building native extensions. This could take a while...
ERROR: Error installing rubocop:
ERROR: Failed to build gem native extension.
current directory: /Users/rogerperez/.rvm/gems/ruby-2.5.3/gems/jaro_winkler-1.5.2/ext/jaro_winkler
/Users/rogerperez/.rvm/rubies/ruby-2.5.3/bin/ruby -r ./siteconf20190201-95719-di5gax.rb extconf.rb
creating Makefile
current directory: /Users/rogerperez/.rvm/gems/ruby-2.5.3/gems/jaro_winkler-1.5.2/ext/jaro_winkler
make "DESTDIR=" clean
xcrun: error: invalid active developer path (/Library/Developer/CommandLineTools), missing xcrun at: /Library/Developer/CommandLineTools/usr/bin/xcrun
current directory: /Users/rogerperez/.rvm/gems/ruby-2.5.3/gems/jaro_winkler-1.5.2/ext/jaro_winkler
make "DESTDIR="
xcrun: error: invalid active developer path (/Library/Developer/CommandLineTools), missing xcrun at: /Library/Developer/CommandLineTools/usr/bin/xcrun
make failed, exit code 1
Gem files will remain installed in /Users/rogerperez/.rvm/gems/ruby-2.5.3/gems/jaro_winkler-1.5.2 for inspection.
Results logged to /Users/rogerperez/.rvm/gems/ruby-2.5.3/extensions/x86_64-darwin-17/2.5.0/jaro_winkler-1.5.2/gem_make.out
xcode-select --install
Then try running
gem install rubocop
This issue has been automatically marked as stale because it has not had recent activity. If this is still an issue, please add a comment. It will be closed if no further activity occurs. Thank you for your contributions.
Most helpful comment
A SOLUTION:
xcode-select --installThen try running
gem install rubocop