Atom Beautify Ruby with rubocop doens't work

Léo Rocha Source

I have Atom Beautify plugin installed in Atom and the rubocop gem installed in my app. Even after these steps the beautify don't work.

My rubocop location:

  $ which rubocop 
  /home/leonardo/.rbenv/shims/rubocop

In my config.cson i have the code:

...
    ruby:
      rubocop_path: "/home/leonardo/.rbenv/shims/rubocop"
...

When I try using Beatify(Ctrl+Alt+B) this return the error:

Error: rbenv: rubocop: command not found
The `rubocop' command exists in these Ruby versions:
  2.4.3
    at /home/leonardo/.atom/packages/atom-beautify/src/beautifiers/executable.coffee:182:23
    at tryCatcher (/home/leonardo/.atom/packages/atom-beautify/node_modules/bluebird/js/release/util.js:16:23)
    at Promise._settlePromiseFromHandler (/home/leonardo/.atom/packages/atom-beautify/node_modules/bluebird/js/release/promise.js:512:31)
    at Promise._settlePromise (/home/leonardo/.atom/packages/atom-beautify/node_modules/bluebird/js/release/promise.js:569:18)
    at Promise._settlePromise0 (/home/leonardo/.atom/packages/atom-beautify/node_modules/bluebird/js/release/promise.js:614:10)
    at Promise._settlePromises (/home/leonardo/.atom/packages/atom-beautify/node_modules/bluebird/js/release/promise.js:693:18)
    at Async._drainQueue (/home/leonardo/.atom/packages/atom-beautify/node_modules/bluebird/js/release/async.js:133:16)
    at Async._drainQueues (/home/leonardo/.atom/packages/atom-beautify/node_modules/bluebird/js/release/async.js:143:10)
    at Async.drainQueues (/home/leonardo/.atom/packages/atom-beautify/node_modules/bluebird/js/release/async.js:17:14)
    at process._tickCallback (internal/process/next_tick.js:103:7)
ruby-on-railsrubyatom-editoratom-beautify

Answers

comments powered by Disqus