When editing HTML files with Vim I pondered about extending the
'matchpairs' setting for editing convenience. The default is
matchpairs=(:),{:},[:]
For the HTML editing purpose I temporarily change that to
matchpairs=(:),{:},[:],<:>
I'd like to hear opinions about making that a fix change in the
configuration file. Or keep it an ad hoc change on demand? Could
there be any undesired side-effects I didn't think of when making
it persistent?
In comp.editors, Janis Papanagnou <janis_papanagnou+ng@hotmail.com> wrote:
When editing HTML files with Vim I pondered about extending the
'matchpairs' setting for editing convenience. The default is
matchpairs=(:),{:},[:]
For the HTML editing purpose I temporarily change that to
matchpairs=(:),{:},[:],<:>
I'd like to hear opinions about making that a fix change in the
configuration file. Or keep it an ad hoc change on demand? Could
there be any undesired side-effects I didn't think of when making
it persistent?
You can use vim's auto commands to make that happen for only HTML files
if you like.
autocmd BufNewFile,BufRead *.html set matchpairs=(:),{:},[:],<:>
Personally I stick a bunch of Unicode pairs in there, too.
https://qaz.wtf/qz/blosxom/2022/06/02/matchpairs
I keep showmatch turned off, so I don't know if the worst case is worse,
but, daily drive over a year, no issues with manual % matching.
When editing HTML files with Vim I pondered about extending the
'matchpairs' setting for editing convenience. The default is
matchpairs=(:),{:},[:]
For the HTML editing purpose I temporarily change that to
matchpairs=(:),{:},[:],<:>
I'd like to hear opinions about making that a fix change in the
configuration file. Or keep it an ad hoc change on demand? Could
there be any undesired side-effects I didn't think of when making
it persistent?
Janis Papanagnou <janis_papanagnou+ng@hotmail.com> wrote:
When editing HTML files with Vim I pondered about extending the
'matchpairs' setting for editing convenience. The default is
matchpairs=(:),{:},[:]
For the HTML editing purpose I temporarily change that to
matchpairs=(:),{:},[:],<:>
I'd like to hear opinions about making that a fix change in the
configuration file. Or keep it an ad hoc change on demand? Could
there be any undesired side-effects I didn't think of when making
it persistent?
I use this for C++ files, no undesired side-effects so far. It works.
On 30.12.2023 20:46, Rene Kita wrote:
Janis Papanagnou <janis_papanagnou+ng@hotmail.com> wrote:
For the HTML editing purpose I temporarily change that toI use this for C++ files, no undesired side-effects so far. It works.
matchpairs=(:),{:},[:],<:>
This is great! - I didn't think of C++ (despite using it occasionally).
Sysop: | Keyop |
---|---|
Location: | Huddersfield, West Yorkshire, UK |
Users: | 490 |
Nodes: | 16 (2 / 14) |
Uptime: | 63:14:57 |
Calls: | 9,676 |
Files: | 13,719 |
Messages: | 6,171,686 |