Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

unwanted indention level after C# attribute in Vim

Tags:

c#

vim

Vim is indenting method definitions an extra level after an attribute. This is driving me crazy but I can't figure out how to make it stop. I've disabled indenting entirely but this isn't behavior I want. Is there a way to make Vim not indent an extra level after an attribute definition?

Here is a sample:

[Foo]
  public void Bar()
  {
  }
like image 713
Frank Hale Avatar asked Feb 22 '23 01:02

Frank Hale


1 Answers

Grab from here cs.vim file and put it in your vimfiles\indent folder.

Notice that you should have a string filetype indent plugin on in your vimrc file.

like image 146
rpeshkov Avatar answered Mar 04 '23 14:03

rpeshkov