shell-script-pt
[Top][All Lists]
Advanced

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

Re: [shell-script] Como exibir variáveis


From: Daniel Duclos
Subject: Re: [shell-script] Como exibir variáveis
Date: Sat, 15 Sep 2001 14:38:22 -0300 (EST)

On Sat, 15 Sep 2001 address@hidden wrote:

> Olá lista,
>
> sei que é meio bobo, mas sou novo em shel script,
> gostaria de saber como exibir valores de variáveis na tela,
> algo com:
>
> MES='date +%m'
> echo 'MES'
>
> Só exibe a palavra MES;
>
> Como faço para exibir o valor da vaviável, não
> ela em si?

        Use um sifrao na frente ($), assim:

        MES=`date +%m`
        echo $MES

[]s

Daniel Lobato Duclos - address@hidden - http://www.cybershark.net
---------------------------------------------------------------------------
Open Up Your Mind / And Go Your Own Way
(Sepultura - Breed Apart)



reply via email to

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