Si si..... hice man sh pero no me acalraba. creo que ponia mal las comillas.
Ademas con $(comando) a mi no me funciona

gracias de todas formas ;-)





Santiago Vila wrote:

> Jaime Rodr�guez Molina wrote:
> > Como puedo hacer que en un script con sh una variable cualquiera me almacene
> > la salida de un comando?
> >
> > Por ejemplo necesito en la variable dia la salida del comando date
>
> Si hubieras hecho man bash habr�as le�do esto:
>
>    Command Substitution
>        Command substitution allows the output  of  a  command  to
>        replace the command name.  There are two forms:
>
>               $(command)
>        or
>               `command`
>
> En tu caso:
>
> variable=`date`
>
> --
> To UNSUBSCRIBE, email to [EMAIL PROTECTED]
> with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Responder a