lynx-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Lynx-dev] copy out of lynx, replace and paste


From: Tim Chase
Subject: Re: [Lynx-dev] copy out of lynx, replace and paste
Date: Thu, 24 Mar 2022 10:59:02 -0500

On 2022-03-23 08:21, s18@stof999.ch wrote:
> lynx makes line-breaks with 3spaces where there would be
> normaly a dynamic word wrap in html.

You can use lynx to dump the output of a URL to a file if you prefer:

  $ lynx -width=99999 -dump https://example.com > example.txt

which sets the wrap-width to a super-wide value (thus hopefully
preventing the wrapping you want to avoid)

> 3) doing something "nasty", storing it tmp, let something (i have
> done it by python) going over the text for formating it, and put it
> back to the clipboard, like yu made a suggestion (thanks!)

If you want to un-wrap *everything* (not just the particular pattern
of newline-followed-by-three-spaces), it's a lot less complex, as you
can use `fmt` with a really wide width

  $ fmt -w 999999 < wrapped.txt > unwrapped.txt

which is a *lot* tidier than my awk solution which targets the
very specialized/limited requirement of your original request.

-tim



reply via email to

[Prev in Thread] Current Thread [Next in Thread]