* hush command output string
@ 2012-12-14 8:01 guenter.gebhardt
2012-12-14 8:40 ` Sascha Hauer
0 siblings, 1 reply; 2+ messages in thread
From: guenter.gebhardt @ 2012-12-14 8:01 UTC (permalink / raw)
To: barebox
[-- Attachment #1.1: Type: text/plain, Size: 173 bytes --]
Hello,
I want to write a hush script which evaluates standard output of some
command, e.g.:
VARIABLE=$(command)
or
VARIABLE=`command`
How can this be done within hush?
[-- Attachment #1.2: Type: text/html, Size: 440 bytes --]
[-- Attachment #2: Type: text/plain, Size: 149 bytes --]
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: hush command output string
2012-12-14 8:01 hush command output string guenter.gebhardt
@ 2012-12-14 8:40 ` Sascha Hauer
0 siblings, 0 replies; 2+ messages in thread
From: Sascha Hauer @ 2012-12-14 8:40 UTC (permalink / raw)
To: guenter.gebhardt; +Cc: barebox
On Fri, Dec 14, 2012 at 09:01:08AM +0100, guenter.gebhardt@rafi.de wrote:
> Hello,
>
> I want to write a hush script which evaluates standard output of some
> command, e.g.:
>
> VARIABLE=$(command)
>
> or
>
> VARIABLE=`command`
>
> How can this be done within hush?
This can't be done. For this we would need output redirection, multiple
thread contexts, ...
In some commands we work around this by specifying the variable name on
the command line.
For example the readline command works like this:
Usage: readline <prompt> VAR
readline reads a line of user input into variable VAR.
Sascha
--
Pengutronix e.K. | |
Industrial Linux Solutions | http://www.pengutronix.de/ |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2012-12-14 8:41 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-12-14 8:01 hush command output string guenter.gebhardt
2012-12-14 8:40 ` Sascha Hauer
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox