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

disable dotspacemacs-whitespace-cleanup on certain mode #5961

Closed
ntcong opened this issue May 2, 2016 · 8 comments
Closed

disable dotspacemacs-whitespace-cleanup on certain mode #5961

ntcong opened this issue May 2, 2016 · 8 comments
Assignees

Comments

@ntcong
Copy link
Contributor

ntcong commented May 2, 2016

Can dotspacemacs-whitespace-cleanup be disabled on certain mode. It's really useful when I programming, but I want to disable in on something like Markdown (New line = two trailing whitespace).

A toggle on cleanup/not cleanup would be fine I guess.

@TheBB
Copy link
Collaborator

TheBB commented Jun 2, 2016

See #6204

@syl20bnr
Copy link
Owner

syl20bnr commented Jun 3, 2016

There is now a toggle thanks to @TheBB
See spacemacs/toggle-whitespace-cleanup-off and commits 5a4e8a3 and c0f19ca

@ntcong
Copy link
Contributor Author

ntcong commented Jun 3, 2016

Great work as usual 👍

@magnetophon
Copy link
Contributor

magnetophon commented Jun 22, 2016

I agree it's a big improvement, but ideal would still be to turn it of automatically in certain modes.
Especially since it's only a minority of modes that need it off, you'll forget to toggle manually, and lose work.

Speaking from experience here! ;)

@ntcong
Copy link
Contributor Author

ntcong commented Jun 23, 2016

if you had a toggle, it will be easy enough to add a hook I think.

@d12frosted
Copy link
Collaborator

Fixed with released of Spacemacs v0.200. Let us know if you still have any problems with this issue.

@yeonghoey
Copy link

yeonghoey commented Oct 6, 2016

(defun dotspacemacs/init ()
  (setq-default
   dotspacemacs-whitespace-cleanup 'trailing
  ))

(defun dotspacemacs/user-config ()
  (add-hook 'markdown-mode-hook 'spacemacs/toggle-whitespace-cleanup-off)
  )

I added configurations like this, but it had still been enabled when I opened a markdown file.
How can I solve this problem?

@liweitianux
Copy link

Please see #8221 .

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

No branches or pull requests

8 participants