-
Notifications
You must be signed in to change notification settings - Fork 7
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
Extension 'standard ruby' is configured as formatter but it cannot format 'Ruby'-files #2
Comments
I also have this issue. |
I get this if I create a new file within a Rails project using Strangely, if I do try to save the file then VSCode gives it an extension of |
Another idea, because you don't have very many settings set:
|
I saw a reference on SO to the extension issue being down to VSCode Ruby. I disabled it (which also meant disabling the main Ruby extension) and while ruby files now save with a I realise that this is probably a VSCode core issue rather than something relating to this extension, just mentioning it here FYI. Cheers. |
Do you have something like this in your settings.json? "[ruby]": {
"editor.defaultFormatter": "testdouble.vscode-standard-ruby"
}, And when you're editing unsaved Ruby documents that aren't formatting, do they show up as Ruby in the right side of the status bar? If the answer to both is "yes", then I'm stumped. |
Yes, I'm afraid so. And linting works, just not formatting. It's no biggie now that I know that the problem is only happening on unsaved files (for me at least). Thanks for taking time to look at this. I can live with it as it stands though. |
Thanks for the response. Since my post the issue seems to have resolved itself, though I'm not really sure why. I don't have any workspace settings on my installation, so that shouldn't be a problem. After doing a little more investigation I think the
However I get the "cannot format ruby files" error in the badge. I've also notice when it is working, I'll still be shown that message until Standard has finished starting up, then it will go to normal. So it seems it may just be a case of a misleading error message showing regardless of the actual problem. Hope this helps, now that it's working for me I'm really happy with the extension! |
We ran into this as well after switching to and getting everyone on the Standard extension. We discovered Ruby was setup with a different formatter. If you see the |
Folks in this thread, did you follow this step in the readme? "[ruby]": {
"editor.defaultFormatter": "testdouble.vscode-standard-ruby"
}, Or was this already set? |
@searls I did already have that setting configured. |
@robingram Rats. Are you still experiencing this issue? |
Yeah but only in the limited circumstances I mentioned, for a new file that hasn't been saved, so it is easy to work around. |
Hi,
I'm getting this odd error after installing the vscode-standard-ruby extension.
Extension 'standard ruby' is configured as formatter but it cannot format 'Ruby'-files
I'm using the following versions:
Here is my settings.json:
And here is a list of extensions I have installed:
Happy to provide more detail if needed.
The text was updated successfully, but these errors were encountered: