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

fix: set b:undo_plugin properly and set options locally in ftplugin #282

Merged
merged 4 commits into from
May 31, 2024

Conversation

rhysd
Copy link
Contributor

@rhysd rhysd commented May 31, 2024

This PR contains the following fixes and cleanups:

  • Set b:undo_ftplugin. This is used when a user changes a file type with :setfiletype. Vim does clean up options set by a previous file type plugin before loading a new file type plugin.
  • Use :setlocal instead of :set so that those option changes don't affect other buffers globally.
  • ftplugin/typescript.vim mixes 2-spaces and 4-spaces indentations. Use 2-spaces indentation persistently.
  • :autocmds in ftdetect are a bit redundant. Use a single :autocmd to match multiple patterns.

Copy link
Owner

@HerringtonDarkholme HerringtonDarkholme left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks

@HerringtonDarkholme HerringtonDarkholme merged commit 9b16b86 into HerringtonDarkholme:master May 31, 2024
2 checks passed
@rhysd rhysd changed the title fix: set b:undo=plugin properly and set options locally in ftplugin fix: set b:undo_plugin properly and set options locally in ftplugin May 31, 2024
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

Successfully merging this pull request may close these issues.

2 participants