Matthias Meyer <matthias.meyer@gmx.li> (Sa 31 Jan 2009 00:31:44 CET): > Hallo, > > Ich kriegs irgendwie nicht hin den date Befehl in eine Variable zu packen. > Also fast nicht ;-) > timestamp="date +%Y/%m/%d_%T" > echo "`$timestamp - text" > funktioniert. > Aber > timestamp="date +%Y/%m/%d %T" > echo "`$timestamp - text" > funktioniert nicht. Also das BLANK vor dem %T will er nicht. echo "$(date +'%Y %T') text" reicht Dir nicht? timestamp="date +'%Y %T'" echo "$(eval $timestamp) TEXT" Geht bestimmt auch noch einfacher. Dazu müsste man vielleicht den Kontext wissen. Best regards from Atlanta, GA (currently) Viele Grüße aus z.Z. Atlanta Heiko Schlittermann -- SCHLITTERMANN.de ---------------------------- internet & unix support - Heiko Schlittermann HS12-RIPE ----------------------------------------- gnupg encrypted messages are welcome - key ID: 48D0359B --------------- gnupg fingerprint: 3061 CFBF 2D88 F034 E8D2 7E92 EE4E AC98 48D0 359B -
Attachment:
signature.asc
Description: Digital signature