Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

:RuboCop makes code window blank #8

Open
tomaszwojcik opened this issue May 13, 2014 · 2 comments
Open

:RuboCop makes code window blank #8

tomaszwojcik opened this issue May 13, 2014 · 2 comments

Comments

@tomaszwojcik
Copy link

Hey,

I have a strange issue with the new version of the vim-rubocop plugin.
Now when I run the :RuboCop command the code window gets cleared (code is not deleted, window is just blank).

My test code:

class TestRubocop
  def method
  end
end

Sometimes I get proper warnings, but most of the time I get something like this (notice the error in the column & row):

/Users/twojcik/playground/1.9.3/test_rubocop.rb:1|1 error| C: Missing top-level class documentation comment.
/Users/twojcik/playground/1.9.3/test_rubocop.rb:1|1 error| C: Missing utf-8 encoding comment.

What I use:

  • MacVim 7.4.52 (reproduced the issue in "normal" Vim)
  • ruby 1.9.3p484
  • rubocop gem (0.21.0, 0.12.0)

Before I've updated the vim-rubocop everything was fine - that's why I assume it can be the plugin's fault.

@ngmy
Copy link
Owner

ngmy commented May 24, 2014

Hi.

I was not able to reproduce the problem.

I always got proper warnings following:

test_rubocop.rb|1 col 1| C: Missing top-level class documentation comment.
test_rubocop.rb|1 col 1| C: Missing utf-8 encoding comment.

What I use:

  • MacVim 7.4.52
  • ruby 1.9.3p484 (use RVM)
  • rubocop gem (0.21.0, 0.12.0)
  • vim-rubocop plugin (latest version d3caa5d)

What I did:

  1. Open the test_rubocop.rb using MacVim.

    $ mvim test_rubocop.rb
    
  2. Run the :RuboCop command.

@tomaszwojcik
Copy link
Author

Hmm it now works fine for me (reinstalled everything). However do you think that this augroup could be the issue?

  autocmd FileType ruby
        \ if expand("%") =~# '_spec\.rb$' |
        \   compiler rspec | setl makeprg=rspec\ $*|
        \ else |
        \   compiler ruby | setl makeprg=ruby\ -wc\ \"%:p\" |
        \ endif

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants