From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Lennart Borgman Newsgroups: gmane.emacs.devel Subject: Re: start-process somehow expands *.org Date: Tue, 1 Mar 2011 16:20:03 +0100 Message-ID: References: <19820.22901.674486.120802@fencepost.gnu.org> <48384.130.55.118.19.1298992472.squirrel@webmail.lanl.gov> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Trace: dough.gmane.org 1298992931 6756 80.91.229.12 (1 Mar 2011 15:22:11 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Tue, 1 Mar 2011 15:22:11 +0000 (UTC) Cc: Emacs developers To: herring@lanl.gov Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Mar 01 16:22:07 2011 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1PuRNm-0002Rm-7M for ged-emacs-devel@m.gmane.org; Tue, 01 Mar 2011 16:22:06 +0100 Original-Received: from localhost ([127.0.0.1]:51988 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PuRNV-0001Du-Fg for ged-emacs-devel@m.gmane.org; Tue, 01 Mar 2011 10:20:45 -0500 Original-Received: from [140.186.70.92] (port=50889 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PuRNL-0000vN-VA for emacs-devel@gnu.org; Tue, 01 Mar 2011 10:20:37 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PuRNB-0003NK-Ss for emacs-devel@gnu.org; Tue, 01 Mar 2011 10:20:26 -0500 Original-Received: from mail-ey0-f169.google.com ([209.85.215.169]:40465) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PuRNA-0003Mu-5k; Tue, 01 Mar 2011 10:20:24 -0500 Original-Received: by eyh6 with SMTP id 6so1752965eyh.0 for ; Tue, 01 Mar 2011 07:20:23 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc:content-type:content-transfer-encoding; bh=AFyjbnphsSn52h0pGjWgTYkmcKcb9UZ//CGfrz4X+R8=; b=REKnuuCFERmn25jbscHi145Jirxne5xl3kXWC5PHv63kFlO9iwuTw3th6uunQ1WVcH 0BvOG631qtY0B3QislC8ZsOc9yaWIhQAh4zpGgDhWGubyhFkHJmFcwtewsPzrfQjtnx9 ZI1oG29Wsq7+7JUgi7/e+RaAmn+cg+/MHrpkw= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-type:content-transfer-encoding; b=LhfxFjGjjxtTocXn5A0Pfl8lMMyB+vJSoBWyhmc4nHD+w5YjSnQm1Acue8QaDNoldh ++xCqVZ68meEd/V0tpg0cK0kPwWzcGZHFH7EZaplONHKe2FVjRE7/AOsobP3qu47nGi+ OBAhYILNsjef+tKI0AUjkPDZqu8+PKEl0Fbxg= Original-Received: by 10.213.2.204 with SMTP id 12mr609597ebk.94.1298992823123; Tue, 01 Mar 2011 07:20:23 -0800 (PST) Original-Received: by 10.213.108.136 with HTTP; Tue, 1 Mar 2011 07:20:03 -0800 (PST) In-Reply-To: <48384.130.55.118.19.1298992472.squirrel@webmail.lanl.gov> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) X-Received-From: 209.85.215.169 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:136663 Archived-At: On Tue, Mar 1, 2011 at 4:14 PM, Davis Herring wrote: >> =C2=A0 =C2=A0(setq command >> =C2=A0 =C2=A0 =C2=A0 ("ruby.exe" "c:\\path-to\\idxsearch.rb" "--root" >> "c:/where-to-search/" "--filepatt" "*.org" "--query" "word1,word2") >> >> =C2=A0 =C2=A0(apply 'start-process (downcase mode-name) outbuf command) >> >> It looks like idxsearch.rb recieves the first file matching *.org, in >> my case "act.org" - instead of "*.org" as I expected. >> >> It might be ruby.exe that expands *.org, but if I try a similar >> command line ruby.exe does not expand *.org. >> >> This is on w32, as usual with my patched version. > > The system shell on w32 does not expand wildcards (or even split words), > so programs built for w32 must do any expansion themselves. =C2=A0The var= ious > Unix-on-Windows approaches typically try to do splitting/expansion before > calling main() so that the ported programs see what they would expect fro= m > a Unix shell. > > So it's likely that ruby is choosing to do the expansion itself (and then > doing who knows what with the other matches). =C2=A0You might be able to = fix it > by passing the argument with double quotes or so; it depends on the > details of the Unix emulation layer in use. But if I give "*.ext" to ruby the same way I thought Emacs did it does not expand "*.ext". So I thought that maybe Emacs does this expansion, but since know one seems to know about it I guess it does not. Now I am a bit puzzled...