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

Autoformat doesn't work with non *.rb files #32

Open
martinos opened this issue Aug 2, 2022 · 2 comments
Open

Autoformat doesn't work with non *.rb files #32

martinos opened this issue Aug 2, 2022 · 2 comments

Comments

@martinos
Copy link

martinos commented Aug 2, 2022

When I am working with non .rb files, like thor, Rakefile, rb executable, the autoformat does not work even when activated with :RufoOn.

@Nitrodist
Copy link

Looks like this is configured here: https://github.com/ruby-formatter/rufo-vim/blame/master/plugin/rufo.vim#L33

@thomaswitt
Copy link

Just add this to your vimrc in the meantime:

augroup RufoAutoFormat
  autocmd!
  autocmd BufWritePre *.rb,*.rake silent! call rufo#AutoFormat()
augroup END

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

3 participants