From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Kevin Rodgers Newsgroups: gmane.emacs.help Subject: Re: copy visible text with some lines hidden with hide-lines Date: Mon, 25 Feb 2008 21:22:14 -0700 Message-ID: References: <6c22270a-576c-41c4-8f01-75b23433ca69@60g2000hsy.googlegroups.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1203999756 795 80.91.229.12 (26 Feb 2008 04:22:36 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 26 Feb 2008 04:22:36 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Tue Feb 26 05:23:01 2008 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1JTrLH-0003XY-Jr for geh-help-gnu-emacs@m.gmane.org; Tue, 26 Feb 2008 05:22:59 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1JTrKl-0006v7-Jf for geh-help-gnu-emacs@m.gmane.org; Mon, 25 Feb 2008 23:22:27 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1JTrKU-0006uw-I5 for help-gnu-emacs@gnu.org; Mon, 25 Feb 2008 23:22:10 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1JTrKT-0006ud-5u for help-gnu-emacs@gnu.org; Mon, 25 Feb 2008 23:22:10 -0500 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1JTrKT-0006ua-0H for help-gnu-emacs@gnu.org; Mon, 25 Feb 2008 23:22:09 -0500 Original-Received: from main.gmane.org ([80.91.229.2] helo=ciao.gmane.org) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1JTrKS-0002dt-PU for help-gnu-emacs@gnu.org; Mon, 25 Feb 2008 23:22:08 -0500 Original-Received: from list by ciao.gmane.org with local (Exim 4.43) id 1JTrKL-0007qZ-Kz for help-gnu-emacs@gnu.org; Tue, 26 Feb 2008 04:22:01 +0000 Original-Received: from c-67-162-159-170.hsd1.co.comcast.net ([67.162.159.170]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Tue, 26 Feb 2008 04:22:01 +0000 Original-Received: from kevin.d.rodgers by c-67-162-159-170.hsd1.co.comcast.net with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Tue, 26 Feb 2008 04:22:01 +0000 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 32 Original-X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: c-67-162-159-170.hsd1.co.comcast.net User-Agent: Thunderbird 2.0.0.9 (Macintosh/20071031) In-Reply-To: X-detected-kernel: by monty-python.gnu.org: Linux 2.6, seldom 2.4 (older, 4) X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:51866 Archived-At: Rupert Swarbrick wrote: > On Thu, 21 Feb 2008 16:46:20 -0800, jdzhang wrote: > >> I need looking at large (10s of MB) log files regularly. I use hide- >> lines to filter out the lines I don't care. However, I was able to >> figure out how to copy only the text being displayed. Any suggestions >> are welcome. >> >> Thanks. >> >> Jason Zhang > > One thing I've done in the past was to use C-M-! and run a grep command > which will give me the lines I want (and not too much cruft). Then you > get a temporary buffer, with which you can't accidentally blat your log > file by saving (so you needn't be scared of deleting lots more stuff) and > which is hopefully small enough the Emacs won't get upset about buffer > size. I think you meant `M-!'. Have you tried `M-x occur'? > If it's a regular job, I suspect one could write a short elisp function > to get the relevant bits in this way, and maybe rename the buffer to > something more informative than the standard thing with ** in it. > > Rupert > -- Kevin Rodgers Denver, Colorado, USA