unix时间戳转换

Posted by 4Aiur on 05/14/2010 in SysAdmin |

unix时间戳转换, Convert unix timestamp utime(){ date -d @$1; } utime(){ date -d “1970-01-01 GMT $1 seconds”; } utime(){ awk -v d=$1 ‘BEGIN{print strftime(“%a %b %d %H:%M:%S %Y”, d)}’; } utime(){ perl -e “print localtime($1).\”\n\””; } utime(){ python -c “import time; print(time.strftime(‘%a %b %d %H:%M:%S %Y’, time.localtime($1)))”; } [root@test test]# utime(){ date -d @$1; } [root@test test]# […]

Tags:

Copyright © 2010-2019 4Aiur All rights reserved.
This site is using the Desk Mess Mirrored theme, v2.5, from BuyNowShop.com.