SublimeText / TrailingSpaces

Highlight trailing spaces and delete them in a flash.
MIT License
897 stars 94 forks source link

TrailingSpaces always trims on save although it's set to false #79

Closed Heart1010 closed 1 year ago

Heart1010 commented 9 years ago

I'm on Linux build ST3 3065 and although I kept the default settings

{
    "trailing_spaces_modified_lines_only": false,
    "trailing_spaces_trim_on_save": false,
}

the plugin always deletes all whitespaces in my file when I save it.

Heart1010 commented 9 years ago

Ok, my fault.... the ST3 internal setting was set to true, I changed that to false and now it works as it should. Closing this...

{
    "trim_trailing_white_space_on_save": false,
}
Heart1010 commented 9 years ago

Hmmm, I set my user setting for the plugin to

{
    "trailing_spaces_modified_lines_only": true,
    "trailing_spaces_trim_on_save": true,
}

but when I save the file all the whitespaces are deleted and not only whitespaces from the lines I modified.

alkemann commented 9 years ago

Yes. It does NOT respect the setting of only on modified lines.

BenMQ commented 9 years ago

Do you guys have other tools that may conflict with this? For example is there a .editorconfig with trim_trailing_whitespace = true?

YurkoHoshko commented 9 years ago

@BenMQ I have not any other tools that could conflict with TrailingSpaces and I have the same issue as @Heart1010 .

Update: I restarted Sublime Text and everything seems to be ok.

arkhi commented 8 years ago

I’m on MacOSX with a build 3103.

After removing the folders “Installed Packages” and “Packages” in /Users/fabien//Library/Application Support/, I have the same issue: The lines are trimmed by default, even though the default SublimeText default settings (“/Users/fabien/Library/Application Support/Sublime Text 3/Packages/Default/Preferences.sublime-settings”) for trim_trailing_white_space_on_save is set to false.

Is there a way to check what is the actual value for a specific setting?

lakesare commented 4 years ago

Thank you @BenMQ, I had trim_trailing_whitespace set to true in .editorconfig.

rchl commented 1 year ago

Resolving as I've tested this and it appears to work for me now (few years later). If it doesn't for someone then we need more info.