bug-bash
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: i/o redirection into variables


From: Eric Blake
Subject: Re: i/o redirection into variables
Date: Tue, 28 Mar 2006 07:00:51 -0700
User-agent: Thunderbird 1.5 (Windows/20051201)

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

According to Dirk H. Schulz on 3/28/2006 6:32 AM:
> Hi folks,
> 
> I am looking for a possiblity to redirect error output into a variable:
> 
> Instead of redirecting to a file
> ( e.g.
>       command 2>>errorlogfile
> )
> 
> I would like to redirect into a variable.

variable=$(command 2>&1)

- --
Life is short - so eat dessert first!

Eric Blake             address@hidden
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.2.1 (Cygwin)
Comment: Public key at home.comcast.net/~ericblake/eblake.gpg
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFEKUGT84KuGfSFAYARAv5pAJkBcJx7Y11iVKnSNkIlhSypL6QCFACfSnhC
P8wijxoc/LU7P4jaB9P5FB4=
=pnef
-----END PGP SIGNATURE-----




reply via email to

[Prev in Thread] Current Thread [Next in Thread]