vim tabular only on the first match on the line?

后端 未结 4 943
忘了有多久
忘了有多久 2020-12-31 06:32

I\'m trying to format some python code with the tabular.vim plugin. It\'s currently a sqlalchemy declarative class, and looks something like this:

id     =           


        
4条回答
  •  傲寒
    傲寒 (楼主)
    2020-12-31 07:07

    The suggestions above are good, but in this case they are a little too complicated and require too much typing. How about:

    :Tab /=.*/
    

    This works just fine -- match the first equal sign and everything after it, aligned left (default, which works just fine!).

提交回复
热议问题