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

Whitespace settings lost in neovim when changing which git commit is checked out #157

Open
stevenroose opened this issue Nov 4, 2020 · 4 comments
Labels

Comments

@stevenroose
Copy link

I've been having trouble with this plugin for about a year now. My default on most projects is to use tabs. Our work project uses spaces and has a .editorconfig to reflect this. Though very often when I have (Neo)vim open and meanwhile checkout different commits on the underlying directory, I start typing tabs again instead of spaces. As if this plugin suddenly breaks down or so.

@cxw42
Copy link
Member

cxw42 commented Nov 6, 2020

Sorry you're having trouble! Please:

  • Update to the latest
  • let g:EditorConfig_verbose=1
  • take a look at the resulting report when you open a file.

If the latest still doesn't work, please send us a full report: versions of neovim, OS, windowing system; steps to reproduce; a minimal example if at all possible.

Note that if you are using symlinks you may not get the results you expect (e.g., #123).

Edit Are you checking out older commits that don't have .editorconfig files, or that have different settings?

@cxw42 cxw42 changed the title Breaks somehow when checking out another git commit Whitespace settings lost in neovim when changing which git commit is checked out Nov 6, 2020
@cxw42 cxw42 added the neovim label Aug 2, 2022
@stevenroose
Copy link
Author

Lol, it's been 4 years and I'm here to report the same behavior has persisted ever since. I just filed an issue with LazyVim about it as well.

@cxw42
Copy link
Member

cxw42 commented Sep 2, 2024

@stevenroose Could you post a git bundle (or git-fast-export) and instructions of a minimal repo that shows the issue?

@cxw42
Copy link
Member

cxw42 commented Sep 7, 2024

As of current master, the .editorconfig file is reloaded in a number of different cases, e.g., BufReadPost. Any of those cases would cause settings to change if the underlying commit has different settings in its .editorconfig.

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

No branches or pull requests

2 participants