Unix 时区

OLDTZ=$TZ

export TZ=GMT; echo "GMT: `date +/"%F %R (%Z)/"`"

GMT: 2008-10-31 12:30 (GMT)

export TZ=Europe/Stockholm; echo "Stockholm: `date +/"%F %R (%Z)/"`"

Stockholm:    2008-10-31 13:30 (CET)

export TZ=Asia/Kuala_Lumpur; echo "Kuala Lumpur: `date +/"%F %R (%Z)/"`"

Kuala Lumpur: 2008-10-31 20:30 (MYT)

export TZ=US/Central; echo "Dallas: `date +/"%F %R (%Z)/"`"

Dallas: 2008-10-31 07:30 (CDT)

export TZ=$OLDTZ

你可能感兴趣的:(Date,unix)