How do I make text wrapping match current indentation level in vim?

前端 未结 5 1463
无人及你
无人及你 2020-12-16 00:28

Does anyone know of a way to get vim to wrap long lines of text such that the position of the wrapped text is based on the indentation of the current line? I don\'t want to

5条回答
  •  长情又很酷
    2020-12-16 01:10

    I recommend this vimscript:

    http://www.vim.org/scripts/script.php?script_id=974

    "This indentation script for python tries to match more closely what is suggested in PEP 8 (http://www.python.org/peps/pep-0008.html). In particular, it handles continuation lines implied by open (parentheses), [brackets] and {braces} correctly and it indents multiline if/for/while statements differently."

提交回复
热议问题