hlissner / evil-snipe

2-char searching ala vim-sneak & vim-seek, for evil-mode
MIT License
340 stars 25 forks source link

Combine minor modes into one #30

Closed justbur closed 8 years ago

justbur commented 8 years ago

Note: This is a breaking change for those using override mode and I'm not sure to what extent you want to provide backwards compatibility.

Override mode is now just a variable that controls whether more keys are added to the keymap.

Besides simplifying the package, this fixes a problem where it was not possible to disable the override mode in a local buffer without disabling the global version of the mode. Quoting the docstring of define-globalized-minor-mode, this is what should happen

"When a major mode is initialized, MODE is actually turned on just after running the major mode's hook. However, MODE is not turned on if the hook has explicitly disabled it."

It seems that the problem was caused by "chaining" the two modes together. See https://github.com/syl20bnr/spacemacs/pull/3605 for some of the difficulties we've been having

justbur commented 8 years ago

I think something along these lines is a good idea, but I'm going to close in favor of the much simpler and non-breaking #31