Article View: news.software.readers
Article #258643Re: configuration with slrn/vim
From: Dale
Date: Thu, 20 Nov 2014 19:12
Date: Thu, 20 Nov 2014 19:12
75 lines
3692 bytes
3692 bytes
On 2014-11-19, Eli the Bearded <*@eli.users.panix.com> wrote:
> In news.software.readers, Dale <dale@dalekelly.org> wrote:
>> I can get line wrap to 80 characters on things I cut and paste into
>> slrn. with
>>
>> set editor_command "vim '+set tw=80' +%d '%s'
>
> (note to readers: The missing quote issue has already been addressed
> downthread)
>
>> if I type, it wraps to 80 characters too, but when I send I have to
>> force send because it says a line is above 80 characters
>
> I'm not a slrn user, but I do use vim with my newsreader of choice.
> Two things to note:
>
> 1) vim won't wrap lines that start out over the textwrap ("tw") limit,
> so if you follow-up to a post with 79 character lines, and then those
> get extended to 81 because of a leading "> ", you'll need to fix them on
> your own somehow. (See below)
>
> 2) vim won't wrap lines longer than the textwrap limit if there is no
> whitespace in the line to wrap. Typically I find that happens very
> rarely unless you count web URLs pasted in.
>
> My newsreader has a very predictable and reasonably unique naming scheme
> for posts I am composing: "~/.article.PID". Instead of setting a command
> line preference for how I want those articles to have a different vim
> configuration, I use a line in my vimrc:
>
> " Set up macros for Pnews
> autocmd BufRead .article.* :so ~eli/.news_vimrc
>
> (The " line is a comment and not required.)
>
> My .news_vimrc has several map! commands to translate smart quotes into
> old-fashioned ASCII, a few other commands helpful to me, plus one "set"
> line for news article specific settings:
>
> map! ’ '
> map! ‘ '
> map! “ "
> map! ” "
> map! … ...
> " n-dash
> map! – --
> " m-dash
> map! — --
> " map function-5 to find non-tab, non-space to tilde (ie, non-ASCII)
> map <F5> /[^ -~]<cr>
> map <F6> iContent-Type: text/plain; charset="UTF-8"<cr>MIME-Version: 1.0<cr><esc>
> map! <F6> Content-Type: text/plain; charset="UTF-8"<cr>MIME-Version: 1.0<cr>
> set ai sw=4 tw=72
>
> The autoindent ("ai") with vim's default setting of the "comments" means
> that ">" indented text can usually be safely reformatted with the vim's
> built in text reformatter: "gq{motion}". See ":help gq" in vim. The most
> frequent motion command I use when reformatting quoted text is "}",
> which is "from here to next blank line".
>
> I think the reformat command may be of particular use to you, because
> I'm guessing that it is existing long lines which are triggering your
> over 80 columns problem.
>
> Elijah
> ------
> has a similar file for Rnmail's "reply by email temporary file" settings
I don't hardly know what to say ELijah, thanks, it will take me awhile
to digest this, thanks again
--
(my whereabouts below)
http://www.dalekelly.org
Technical Details
Message-ID:
<80i408.ad1.17.2@news.alt.net>Path:
mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.readers.20141227.mbox.gz!border2.nntp.dca1.giganews.com!nntp.giganews.com!usenet.blueworldhosting.com!feeder01.blueworldhosting.com!news.alt.netReferences:
<80fgrl.use.17.1@news.alt.net> <eli$1411191700@qz.little-neck.ny.us>Show Full Headers
Complete Article Headers
Message-ID: <80i408.ad1.17.2@news.alt.net> Subject: Re: configuration with slrn/vim Date: Thu, 20 Nov 2014 19:12:38 +0000 From: Dale <dale@dalekelly.org> References: <80fgrl.use.17.1@news.alt.net> <eli$1411191700@qz.little-neck.ny.us> Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.readers.20141227.mbox.gz!border2.nntp.dca1.giganews.com!nntp.giganews.com!usenet.blueworldhosting.com!feeder01.blueworldhosting.com!news.alt.net Newsgroups: news.software.readers Organization: Dale Lines: 75 Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit User-Agent: slrn/1.0.1 (Linux)