delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2018/08/28/13:46:05

X-Recipient: archive-cygwin AT delorie DOT com
DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id
:list-unsubscribe:list-subscribe:list-archive:list-post
:list-help:sender:mime-version:in-reply-to:references:from:date
:message-id:subject:to:content-type; q=dns; s=default; b=p7FNcIv
j1qmi9KMNoPO0kjcnjBlSyUVpEwk2bvKlWMyXPijqlH9CkYLhYND/jjph0W0XmWt
lQtn4cMPsHKnM8ChqZkcqk07aBKPiLXNIIasfUJiZO2X46FLdphGFkda1rJEFqAK
CvnC/WqYTriq4xyKmAPu08y1wfHTJmY9CtoE=
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id
:list-unsubscribe:list-subscribe:list-archive:list-post
:list-help:sender:mime-version:in-reply-to:references:from:date
:message-id:subject:to:content-type; s=default; bh=FVO6t3f/SGjP9
2ZUSsr9Pz6aknQ=; b=pWW81jyOHfzOojQqfXXvEJMjUbyLcmm+FakuFOAkggFe5
crcY3RHf5q+Sx0Q2xJlbO3pzjuSvDKBUAjEnydpbZ20PflJajozbSf2IRqOBhoTr
HQhY/GhVarbUZJe3/2e25osDYZk8wxTMd1b5r1Nv7JB3DON4BM5hVhsDKkXmWQ=
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com
Authentication-Results: sourceware.org; auth=none
X-Spam-SWARE-Status: No, score=-1.6 required=5.0 tests=AWL,BAYES_00,FREEMAIL_ENVFROM_END_DIGIT,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE,SPF_PASS autolearn=no version=3.3.2 spammy=mintty, D*yandex.ru, d2u, answers
X-HELO: mail-it0-f41.google.com
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to; bh=ueIpt/SfQovUY1NdDaWVxqyc1k6PNXwpAGkbP675eoY=; b=M5VtvKjDHsmDVvXAlpmS8hNC2wNdEYIXAfaq8UsDDRpUG6KJYpvMRSQVqA1Y2DYrMW j8ycEDPZYuELNinaUYLF0Vx2zuQU1gJlyJg8iBXlXx9W2zziaMmrmaUszNuna0bMlD/B JaBR8zy+ff9AcUWUBg5HmBgxEYr1vKhCdbVqJhyW7PQqx0uCDlT0oIxdSMjl4sPUEaD5 x42HK2Zigvw1GYqvMufQo+plpnooqYx7yI8it+epWXb0hj6oUGv8K9vQB7cYcjqw2ns6 zm75IYuiKqhP6mVvwP6o5tdaKMQB8XTGBOAnPV/5gYyJ7Lk6fZh3Hghfo6OLEdOVrBqv Q7Rw==
MIME-Version: 1.0
In-Reply-To: <633886764.20180825225107@yandex.ru>
References: <CAD8GWstSbJHnP3XWKvhbtRisB=jJL7SJA9aMOWMJVDbMC_VdYA AT mail DOT gmail DOT com> <1e37af1d-21fa-9c56-b135-cb9a4375d902 AT gmail DOT com> <CAD8GWstSh96mfvMmHFwfu4JJySUm-0doZsF7HX6LKWGqnyddMg AT mail DOT gmail DOT com> <8ea768ba-0fdb-710f-e41a-c9bc52057198 AT razorcat DOT de> <CAD8GWssUk8BAf=Fr+=Yev1KC3zJRSqR1k279wLmqPHqz1F4b7A AT mail DOT gmail DOT com> <633886764 DOT 20180825225107 AT yandex DOT ru>
From: Lee <ler762 AT gmail DOT com>
Date: Tue, 28 Aug 2018 13:45:13 -0400
Message-ID: <CAD8GWss92mGTJRsL1eAjUGux4pbnzqVhC5o6xf4HGFwPz6yyfA@mail.gmail.com>
Subject: Re: speeding up a paste operation
To: cygwin AT cygwin DOT com
X-IsSubscribed: yes

On 8/25/18, Andrey Repin <anrdaemon AT yandex DOT ru> wrote:
> Greetings, Lee!
>
>>>
>>> what about 'cp /dev/clipbord /tmp/hosts'?
>
>> Much better!  That takes about the same time as pasting into notepad,
>> so I'm guessing that's about as fast as I can expect.
>
>> but I need to convert line endings:
>> $ file hosts.txt
>> hosts.txt: ASCII text, with CRLF line terminators
>
> Do you expect us to answer "d2u < /dev/clipboard | wherever" ?
> Or can you stop being lazy and start producing such simple answers
> yourself?

It's not laziness, it's hoping for the magical incantation that will
speed up the right click/paste operation.  But nobody has referenced
my
>> Oh well...  I was hoping I'd set up something wrong in cygwin
so let's close out the thread; at least on my machine, there's a clear
winner for pasting in an absurdly large amount of text:

$ time d2u < /dev/clipboard > hosts-3.txt

real    0m11.372s
user    0m3.749s
sys     0m6.984s

$ time cat /dev/clipboard | tr -d '\r' > hosts-2.txt

real    0m4.405s
user    0m0.124s
sys     0m3.577s

$ time getclip -u > hosts.txt

real    0m0.734s
user    0m0.031s
sys     0m0.031s

My thanks to everyone who gave me alternatives to simple pasting.

And a special thanks to all the devs that have made things so much
better that I completely forgot about pasting text being slow.  In an
off-list conversation I mentioned that I used to limit pasting to no
more than 5-10K lines.  But that was back in WinXP days; since then
there's been cygwin-64, mintty, and I don't know what all else that
are so much better now.  Thank you!!

Lee

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019