Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > gnu.bash.bug > #14285

Re: Directing into a variable doesn't work

Path csiph.com!goblin2!goblin1!goblin.stu.neva.ru!usenet.stanford.edu!not-for-mail
From Piotr Grzybowski <narsil.pl@gmail.com>
Newsgroups gnu.bash.bug
Subject Re: Directing into a variable doesn't work
Date Thu, 28 Jun 2018 14:12:12 +0200
Lines 263
Approved bug-bash@gnu.org
Message-ID <mailman.2689.1530187946.1292.bug-bash@gnu.org> (permalink)
References <bd7807e251dfeb07ef1247a60f946551b9f61bd0@webmail.dreamhost.com>
NNTP-Posting-Host lists.gnu.org
Mime-Version 1.0 (Apple Message framework v1085)
Content-Type multipart/mixed; boundary=Apple-Mail-195--22564486
X-Trace usenet.stanford.edu 1530187947 2548 208.118.235.17 (28 Jun 2018 12:12:27 GMT)
X-Complaints-To action@cs.stanford.edu
Cc chet.ramey@case.edu, "Peter Passchier" <peter@passchier.net>, "Martijn Dekker" <martijn@inlv.org>, bug-bash@gnu.org
To tetsujin@scope-eye.net
Envelope-to bug-bash@gnu.org
DKIM-Signature v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:mime-version:from:in-reply-to:date:cc:message-id:references :to; bh=hTZEqDGxL0FrXZ27F7aUN98ambNNbr5ug3ck6jezgxc=; b=ifW17qpYZMwxhRw75GOxReXzLaCCLzviHWFKOmy+fTjMa0vxVMUaNcDKBCCXjshdJX zGMd8qKpigvimaVNRwDC6HGVfaum+TgfOFNN3wJSRighmWPPE4ETDF441X+xmyqPF1Z7 Xnkp9PHG2OY7D/kxuOSOBLD2xTjwN7XLgWLylB0X2wDalHDkpSZbWIdSRp/8q847D45v OTBHHXkrnYYxqT1W0c3DKAKzsw6vuR/Ss66hznwT4oa2nA3wYvvSHL/sZnafNNV9lEn0 tSn9TnZlSjzo59KzKjrwR9DgVABmav72PVk/ZsHk6HVdU5n21dl6JbryPc57AUhvrfTJ uMCQ==
X-Google-DKIM-Signature v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:mime-version:from:in-reply-to:date:cc :message-id:references:to; bh=hTZEqDGxL0FrXZ27F7aUN98ambNNbr5ug3ck6jezgxc=; b=fwnfe/7FGnQv4cP0sSc9Fi6WgvIEhMkY7IEcdbihdBwBv4GJXcwsmLsai43IxRTiJG 4NFQmDTY9kQYXdaoST4H+/+hcIFDJjK5dmIPVu6TAxjJog4hJBqg6c9e0uU1JVR3E1pB ymx+gS/dxlq6LBC9ezux8GIguSE/wrjWU7h90fGhGtaYE2t4B6wGteKiQcQkjqSiG4nX EhCqh38kvm8/224biA408yYFI7sk2GgYq6OhxaOFgwX56/lDRoV5tctNsVUxxmoqYgf3 K1ANy8ZaemM+7MjCSbAdgZCxOlZ6c1mafyNJlwNyDJEb4lND56Z8ec6gNv6Lix0Vd8B3 lGFQ==
X-Gm-Message-State APt69E0pZU2DgnLz9z49v7hkcSH2JniFmvIpwzZImjLK7zAPWNLIDU0o 6MhOuIze1IcJ7cQ+4SoNz/8=
X-Google-Smtp-Source ADUXVKIayi0VFfgsJsQ0bvn9e+qPXc1jb51fVAqm7rZ52Cvg2sPhm51AhJrZtFXTA/t9ZQfd6DNaWg==
X-Received by 2002:a2e:9887:: with SMTP id b7-v6mr6874372ljj.80.1530187936982; Thu, 28 Jun 2018 05:12:16 -0700 (PDT)
In-Reply-To <bd7807e251dfeb07ef1247a60f946551b9f61bd0@webmail.dreamhost.com>
X-Mailer Apple Mail (2.1085)
X-detected-operating-system by eggs.gnu.org: Genre and OS details not recognized.
X-Received-From 2a00:1450:4864:20::243
X-BeenThere bug-bash@gnu.org
X-Mailman-Version 2.1.21
Precedence list
List-Id Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe <https://lists.gnu.org/mailman/options/bug-bash>, <mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive <http://lists.gnu.org/archive/html/bug-bash/>
List-Post <mailto:bug-bash@gnu.org>
List-Help <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe <https://lists.gnu.org/mailman/listinfo/bug-bash>, <mailto:bug-bash-request@gnu.org?subject=subscribe>
Xref csiph.com gnu.bash.bug:14285

Show key headers only | View raw


[Multipart message — attachments visible in raw view] - view raw

hello,

 I wanted to play around with this idea, and see how it works. Quick and dirty patch (against devel@c181950a89c0f0ca4a3ae2480b783da2f7de9565) is attached. Just modified parser and hardcoded tempfile /tmp/v_save.bash.temp. result:

bash-5.0$ echo 'hello a' >>> a; echo $a
hello a 

 If you don't mind we can get it off the list, and see if we can workout a better way to bind data from redirection with variable, and come up with something. If not, maybe you will find something useful in this patch, I have no idea if I will be able to present any decent version of it.

cheers,
pg
 

Back to gnu.bash.bug | Previous | Next | Find similar | Unroll thread


Thread

Re: Directing into a variable doesn't work Piotr Grzybowski <narsil.pl@gmail.com> - 2018-06-28 14:12 +0200

csiph-web