[PLUG] Emacs: sort-paragraph deletes strings from some paragraphs

Rich Shepard rshepard at appl-ecosys.com
Thu Jan 25 15:49:15 UTC 2018


On Thu, 25 Jan 2018, Johnathan Mantey wrote:

> Have you checked to see if your data contains values that get successfully
> match the regexp within the paragraph-start or paragraph-separate lisp
> variables? Perhaps there are some whitespace characters (TAB, or FF) in
> unusual locations in the data. In my experience CSV always has an
> irregular character in it somewhere that causes heartache.

Johnathan,

   My understanding is that csv format has been standardized only very
recently and not every application adheres to it. In this case, I had
changed the extension to .txt and the field separator is "|". The only
spaces are within a field. The "paragraphs" are separated by two newlines as
each is a block of lines separated by a single newline.

   What you wrote makes sense but if the problem was a whitespace issue why
would it be limited to only the first field and only the first three
paragraphs?

   Anyway, as there are always multiple ways to accomplish the same thing in
linux I used 'sort' on the one-line-per-contact file and will soon reformat
it into discrete "paragraphs."

Thanks,

Rich



More information about the PLUG mailing list