From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Perry Smith Newsgroups: gmane.emacs.help Subject: Re: waiting for asynchronous processes Date: Sat, 15 Oct 2011 20:49:51 -0500 Message-ID: References: <87hb39zydn.fsf@gmail.com> <9669B9E0-85E4-4025-9596-FA77C8754E84@gmail.com> <87d3dxzqgl.fsf@gmail.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 (Apple Message framework v1251.1) Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Trace: dough.gmane.org 1318729812 10890 80.91.229.12 (16 Oct 2011 01:50:12 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Sun, 16 Oct 2011 01:50:12 +0000 (UTC) Cc: help-gnu-emacs List To: =?utf-8?Q?=C5=A0t=C4=9Bp=C3=A1n_N=C4=9Bmec?= Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Sun Oct 16 03:50:07 2011 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([140.186.70.17]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1RFFrb-0000oA-Mu for geh-help-gnu-emacs@m.gmane.org; Sun, 16 Oct 2011 03:50:07 +0200 Original-Received: from localhost ([::1]:60540 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RFFrV-0005Yt-Mb for geh-help-gnu-emacs@m.gmane.org; Sat, 15 Oct 2011 21:50:01 -0400 Original-Received: from eggs.gnu.org ([140.186.70.92]:60963) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RFFrR-0005Ye-Fy for help-gnu-emacs@gnu.org; Sat, 15 Oct 2011 21:49:58 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RFFrP-0005pl-Ac for help-gnu-emacs@gnu.org; Sat, 15 Oct 2011 21:49:57 -0400 Original-Received: from mail-iy0-f169.google.com ([209.85.210.169]:33298) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RFFrP-0005pR-4y for help-gnu-emacs@gnu.org; Sat, 15 Oct 2011 21:49:55 -0400 Original-Received: by iagf6 with SMTP id f6so3501590iag.0 for ; Sat, 15 Oct 2011 18:49:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=subject:mime-version:content-type:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to:x-mailer; bh=AENlSe6gqXmjpgjdwY8zblvSZrlx9BDmrrWoYvMDs9s=; b=uLuZiBKhdQmjsbTzRPGZnzCqzSMeVdz+Zj3YqdwiQqJsesjFu86bxiMA/Pqn3SdbjY lh5FcDR5n50vMOdTZ9awtu7PKZjqJhITWrwxvx/pX35xcMShFOXiKM3ZbSMEIUzw2QHr OLebBzw3lG47ACBVkfk3vbSEozpg56vt9tecs= Original-Received: by 10.42.244.133 with SMTP id lq5mr1365106icb.29.1318729794394; Sat, 15 Oct 2011 18:49:54 -0700 (PDT) Original-Received: from [10.0.0.4] ([64.128.19.234]) by mx.google.com with ESMTPS id jm11sm22520678ibb.1.2011.10.15.18.49.52 (version=TLSv1/SSLv3 cipher=OTHER); Sat, 15 Oct 2011 18:49:53 -0700 (PDT) In-Reply-To: <87d3dxzqgl.fsf@gmail.com> X-Mailer: Apple Mail (2.1251.1) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) X-Received-From: 209.85.210.169 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:82570 Archived-At: On Oct 15, 2011, at 8:15 PM, =C5=A0t=C4=9Bp=C3=A1n N=C4=9Bmec wrote: > On Sun, 16 Oct 2011 02:17:03 +0200 > Perry Smith wrote: >=20 >> Well, as I said, what I really wanted to use is "grep" (the built in = emacs function). =20 >> I assumed I couldn't reach in and change him from asynchronous to = synchronous -- can I? >=20 > I don't think you can, indeed. `grep' uses `compilation-start', which > only starts a synchronous process when asynchronous processes are not > available. >=20 > Depending on what exactly it is you're after, it might be better to = just > define your own command, or try to modify the sentinel of the grep > process (the `grep' command returns the compilation buffer; you can = get > at the associated process and its sentinel using the usual functions), > which, when done cleanly, would actually require defining another > command, too. >=20 > Looking at `compilation-handle-exit', even the default sentinel = provides > several hooks for customising what happens when the process finishes, > namely `compilation-exit-message-function' and > `compilation-finish-function(s)', so just using (one of) these = variables > might be sufficient for your needs. Thanks. One more question, not sure how to ask it. I was hooking this into a keyboard macro so I basically wanted to "do = nothing" while I waited for the process to complete. What is the proper = way to "do nothing" in emacs? Thanks pedz