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:message-id:date:from:subject:to:references :content-type; q=dns; s=default; b=tiVQ4y7fYphi5Ps/eToMf7MDHqfqK D+N0s8Et+EoPyfB5zr3YSieoiwYuHjH371braZvhcKMCLrd3b4dZtl/d4gMlsl6T BPw1JAfd3ZTVCVHi0EL43nMw67R7t5Hm5FUapaBLmpewb8PNLI+VK2+IuuW27u3p 9rM9HB0DPv70zw= 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:message-id:date:from:subject:to:references :content-type; s=default; bh=6e2lXR1ZjL4MVtQK1hf/mBnhx5A=; b=UW1 Q+IZGzZnIzVw8KwiZDqPLN3+4BPXILAXSkRt6kX1klCDgV0UWGt0JL2JbG5tdUef 4ueYpnTWujDDSzjx3tNOgzqdY8qINpDWp7CPFF6OT3u+i26nSkMTS6v7UWKzgKjL RvlpoAv3PE9zIc7hyUtAfLvHOQyCxWt/UkTZE8f0= 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=-1.9 required=5.0 tests=BAYES_00,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE,SPF_PASS autolearn=ham version=3.3.2 spammy=intricacies, Thata, That'a, thata X-HELO: mail-ot0-f180.google.com X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:message-id:date:from:subject:to:references :user-agent; bh=Vif8hwYCw6EbhMW3ZIk53SHoi4y9n0+JNPd8scRArNo=; b=FbGvrEs5Rk5SwWQXMGt456OGyyx3tdfpLu+UzB+oGu2we8wsxmZBrRfbAwlmXhISEE xvaRfoTEef/PDhYhT128j+7i+7qrEtX25azM9vbw21oKHjJgeK/u50mBBDwTrOt39Mq6 u9W5i2sLNaFnLZK/mq4geDaWWPnekr1I3BidR96/HMbDALJYdMOdgoXB14EzHM1y5+Ek 7oyGdeh+BkJ1c8aWm1lG4UaXwnGmBARZuTUk5wE3CgOB/4jNtebvKG8Gl4Wn2ueTyBo6 I9ocET9rtSZ8hd2u95xctDU83ass/rQocRbAVCQN//mDZknUJj6sM5um7JyqphwwuTJ/ JX5w== X-Gm-Message-State: AKGB3mLq0uLFnropbYKcY8Qw8cwG74R8GT4ba0S3XLGo4c5rQKxnKmNw xGJPQm2hOWEJ/rvjoolyf+w6VA== X-Google-Smtp-Source: ACJfBosx4csOyzYqmvIUFvXMCDw2c+jheKkcAgOvsTdwsv7snBaAai3ymvdFRb1KYZgF17IJgzwkBg== X-Received: by 10.157.14.241 with SMTP id 104mr22675883otj.301.1514338680906; Tue, 26 Dec 2017 17:38:00 -0800 (PST) Message-ID: <5a42f978.e4149d0a.552a1.1125@mx.google.com> Date: Tue, 26 Dec 2017 17:38:00 -0800 (PST) From: Steven Penny X-Google-Original-From: Steven Penny Subject: Re: Run command in new window To: cygwin AT cygwin DOT com References: <844ea576-1047-8366-d5b0-36a7ac2a5be7 AT wagner DOT is> Content-Type: text/plain; charset=utf8; format=flowed User-Agent: Tryst/2.0.1 (github.com/svnpenn/tryst) On Wed, 27 Dec 2017 02:11:52, Jürgen Wagner wrote: > Why don't you put the stuff to execute into a nice shell script and get > rid of the intricacies of quoting on the command line level? > That'a way easier to manage and test. really that seems like the best option. the only drawback to that is you wouldnt be able to pass parameters to the script, else you run right back into the previous problem: $ cat hw.sh printf '%s\n' "$@" read $ z='hello world' $ cygstart bash hw.sh "$z" hello world so then you try to fix it with quoting: $ cygstart bash hw.sh "'$z'" hello world which works until you get a variable with single quote: $ z=\' $ cygstart bash hw.sh "'$z'" # nothing so you would either need a robust quoting solution [1], or need to create temporary scripts for each invocation needed. not ideal either way [1] http://cygwin.com/ml/cygwin/2017-12/msg00265.html -- 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