RE: Some functions to read mailing list digests with Vim.
- Hi Benji
Thanks for your scrutiny :) This is just an off-the-hip response.
Proper consideration deferred.
> 1. Do you really get messages of 1 (one) line yanked? Does this comeYes, it's the 'report' option that's causing this.
> from Make_toc()? Have you tried setting 'report' to a large number?
> Minor point: if you use :copy 0 instead of :yank|0put in your :globalYour minor points are my favourites.
> command, you will not overwrite the unnamed register.
> BTW, in vim 6.0 it is possible to execute commands with :silent, whichIndeed.
> is simpler than changing 'report'.
> 2. I have no opinion on usability, whether there is any problem withI'll give this a shot. Don't know yet how it will tally with all the
> setting the @/ register to get the highlighting. If you want to avoid
> this, make your own syntax group.
other searching going on.
> In vim 5.x, if you want to leave 'wrapscan' set, you can always checkI think I'd rather save & unset wrapscan ..
> line(".") after the search and see whether you have gone in the wrong
> 4. Suggestion: use <C-O> after :normal ?<C-R>a<CR>zt instead ofWill do!
> repeating the search.
> 5. In order to avoid code duplication in browsing and searching, tryI'll have to iterate on this point for a while before I get it ..
> writing a function that returns a string to be :execute'd.
> 6. If you want to preserve message-number order,Actually, I much prefer having threads alphabetically. I don't care in
which order threads arose, as long as I can browse them comfortably.
> 7. After making the toc, can't you figure out how long it is byThis is a definite TODO item.
> finding the line number of the first empty line?
> 8. Only look for subject lines after the message separator:Cool! Although I believe this almost comes out in the wash: subject
lines not garnered from the real headers will get Sort'ed and Uniq'ed
out with the real ones, so only the unique ones remain. The only
divergence would be in the case where a quoted subject line doesn't
match any thread. It would show up in the toc and in Next_thread(), and
this *might* be counted as a feature (allowing browsing by
quoted-traces-of-threads, if you get my drift), if I fixed
Next_in_thread() in the way you specify. Actually, it's probably more of
a can-of-worms than a feature. I'll look into using your way.
Jimi Hendrix's modem was a Purple Hayes.