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:date :message-id:subject:from:to:content-type; q=dns; s=default; b=TK LABr7q2IlTdz+AZd8u1U6+cMZiSsirHHJUIG9HUJMcJZWgoU7majCW9azv9o/ln3 BlrsLcpEzwN1KlPpd4xJoI9cCtHqJqQy7bNqOtvP5TUdcAAVoUW5P35fibMIzrYt 3QQB29igH24aNmf3PvZ6jbfDBRA+RuS0SWe9AcNj4= 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:date :message-id:subject:from:to:content-type; s=default; bh=kTIBwa9g RpzbskgvnNhQJb4CnjY=; b=Jw2H0XaA5q0rMGGZS9dRxVyDN7i2p3BFVcvEYUQR O2GbW4s89iOcgbo5Fk+MkFrLHzytdDo6QdsT64BQoGmqb6oviaHK32AFXGSWQYYI yYAdEkPyuHgIAK1lAwcpItGHh1MVYpEjWbHu812G/7864p2oo055V4MDAkd0AC8W ALM= Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , 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-Virus-Found: No X-Spam-SWARE-Status: No, score=-0.7 required=5.0 tests=BAYES_40,RCVD_IN_DNSWL_LOW,SPF_PASS autolearn=ham version=3.3.2 spammy=fight, Hx-languages-length:1311, lewis, Lewis X-HELO: mail-ob0-f173.google.com X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to; bh=cXdNlHHURnNVDeuzVwFZ+wqRDAT382g1gYgnU/8l390=; b=BS63c0UVGL/O1QSvMDP3n3qk8DuEzqPxtVihQx4/cUDKZ3qPK3y11+aEcUcusybGYA GRom9rmVAKhB/gGgd4YZ5P1W12Ky6//0eO3mwji3uo+sIrWtQ3+C8YtQVi6IIm42EFK2 kV6mya9e0xTCpQOS1CGsnQK/Fa9EHteCJCEfsgX5HRqAZMAl8pLD6kXCY+w15+sHBN1F nr6qbHnmVeA8QLv7DSZ4hmGckMD9OT5O3Rikqoa5KG+iqo+MPpWs/kjTZGdzQalAjtKZ 1QfrgFSp1snPoxzBU4f3A5XIYLZ8QAyJBLMiC7pjoqU1rLpq8v3NG4U0qlwJ4vxq+07i o4sA== X-Gm-Message-State: AD7BkJJhQw9fY058AgKkVsLRoJgYFl5+0mFQ9YpeGJiXiCLwI+LSITWgzy25omUyVWhlDCHzv1atCeLSVmUHVQ== MIME-Version: 1.0 X-Received: by 10.60.59.226 with SMTP id c2mr6989756oer.40.1459625650889; Sat, 02 Apr 2016 12:34:10 -0700 (PDT) In-Reply-To: References: Date: Sat, 2 Apr 2016 12:34:10 -0700 Message-ID: Subject: Re: pass arguments enclosed with double quotes from bash shell to windows program From: Michael Enright To: cygwin AT cygwin DOT com Content-Type: text/plain; charset=UTF-8 X-IsSubscribed: yes On Sat, Apr 2, 2016 at 11:59 AM, Cary Lewis wrote: > I need to start acrobat from a bash shell. > > Acrobat needs some of its parameters to be enclosed with double > quotes. This is needed to automatically open and print a pdf. > > > If I try to do a \", then it passes the \" to the windows app. I frequently use WinMerge, a graphical text file comparision program, from the bash shell. Occasionally this involves a file in the current directory vs a file at the end of a path full of spaces and slashes. If this question had come up yesterday I could have looked at my history for examples. My recollection is that the rules for expanding arguments enclosed in single quotes are helpful. Single-quoted arguments are processed much less by bash than even double-quoted arguments. A simple example is if you need to put a backslash in an environment variable, you don't have as many layers to fight if you use single quotes export regex='search\$'. I also use $(cygpath) in some fashion to convert the path since WinMerge is not a Cygwin program. I get the full path to one of the files using tab completion, and then I modify the path by surrounding it with the necessary cygpath syntax to convert the path to a Windows path. -- 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