Re: [vim/vim] ":join" truncates a comments "
On 2017-12-24, Gary Johnson wrote:
> On 2017-12-24, AvianY wrote:
> > I tried it and it works as it should with both NORC and NONE.
>
> For me, with NONE and with
>
> vim -u NORC --cmd "set rtp=/usr/local/share/vim/vim80" comment.xml
>
> it works fine. (My plugin dependencies prevent me from using just
> NORC.) However, if I run just vim with no options and execute the
> :join on line 3, I get this:
>
> <bar/> comment -->
>
> So there is something common between Dmitrii's configuration and
> mine that causes this, but I don't know what. I also tried this,
>
> vim -u NORC --cmd "set rtp=/usr/local/share/vim/vim80" --cmd "filetype
> plugin indent on" --cmd "syntax on" comment.xml
>
> but it also worked fine. Is a puzzlement. I'll poke around some
> more.
It happens when 'comments' is set to
s:<!--,m: ,e:-->
as it is for XML files, and 'formatoptions' includes 'j'.
You can reproduce the problem this way:
$ vim -u NONE comment.xml
:let comments = "s:<!--,m: ,e:-->"
:set fo+=j
:3join
where comment.xml contains Dmitrii's example.
Regards,
Gary
--
--
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php
---
You received this message because you are subscribed to the Google Groups
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.
- Re: [vim/vim] ":join" truncates a comments "&l... Gary Johnson
- Re: [vim/vim] ":join" truncates a comments &qu... Gary Johnson
- Re: [vim/vim] ":join" truncates a comments... Gary Johnson
