A
A
Asker18882020-12-06 15:12:33
vim
Asker1888, 2020-12-06 15:12:33

How to prevent vim from splitting lines?

Good day!
I'm learning vim, I ran into this problem: if a line is longer than the specified maximum line width, then vim breaks it and wraps it with a real line break (\n). Those. when this file is opened elsewhere, these wraps are preserved, which is neither expected nor required.

Is it possible to set it up so that the lines are visually wrapped, but there is no real splitting?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
U
uvelichitel, 2020-12-06
@Asker1888

:set nocompatible
:set nowrap
:set formatoptions-=t
" Или чтобы оставить мягкое/визуальное форматирование 
:set textwidth=0 wrapmargin=0

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question