Skip to content

Syntax Checking can no longer be disabled #193

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

Closed
TimNN opened this issue Jul 17, 2017 · 6 comments
Closed

Syntax Checking can no longer be disabled #193

TimNN opened this issue Jul 17, 2017 · 6 comments

Comments

@TimNN
Copy link

TimNN commented Jul 17, 2017

Sublime Text Version

Sublime Text 3 (Build 3141)

Rust Enhanced Version

2.0.1

Operating system

macOS El Capitan 10.11.6

Expected behavior

Setting "rust_syntax_checking": false, in the Sublime Text Settings should disable syntax checking on save.

Actual behavior

Syntax checking is still performed.

@TimNN
Copy link
Author

TimNN commented Jul 17, 2017

The problem appears to be that util.get_setting checks the Rust Enhanced configuration before the general Sublime Text preferences. While this is likely working as intended if the user specified settings the the Rust Enhanced "User Settings", this also means that all settings from the general Sublime Text preferences will be overwritten by the Rust Enhanced settings.

@ehuss
Copy link

ehuss commented Jul 17, 2017

I agree, it should probably just work. For now, Preferences > Package Settings > Rust Enhanced > Settings - User is the preferred route for changing settings (and in general is the way most plugins work). The proper solution I think is to just comment out the values that are distributed in RustEnhanced.sublime-settings since they are only there to document to the user what the possible settings are and their defaults.

@TimNN
Copy link
Author

TimNN commented Jul 17, 2017

Yeah, I agree that Preferences > Package Settings > Rust Enhanced > Settings - User is a better place for overriding that settings, and that is what I did to "fix" the issue. However I think before #165 only the global settings were consulted? At least I think I remember that I originally tried the user settings, but they did not work back then.

@ehuss
Copy link

ehuss commented Jul 17, 2017

You are correct, and it was an oversight on my part, sorry about that.

@TimNN
Copy link
Author

TimNN commented Jul 17, 2017

No problem and thanks for your work on the plugin :)

If you fix the issue, you may also want to update the ToggleRustSyntaxSettingCommand to change the User Setting instead of the global one (which is what it currently does as far as I can tell).

@ehuss
Copy link

ehuss commented Jul 30, 2018

The toggle command now changes the setting per-window, and adjusting global settings should be done in RustEnhanced.sublime-settings.

@ehuss ehuss closed this as completed Jul 30, 2018
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