Shell__타임 스탬프

582 단어 html.netBlogbash
http://blog.chinaunix.net/u3/91453/showart_1856489.html


#!/bin/bash
BegTime=`date -d "2010-07-25" +%s`
EndTiem=`date -d "2010-08-05" +%s`
Step=60*60*24

for ((i=BegTime; i < EndTiem; i = i + Step))
do
    echo $i|awk '{print strftime("%Y%m%d",$1)}'
    echo `date -d '1970-01-01 UTC '$i' seconds' +"%Y%m%d"`
done


좋은 웹페이지 즐겨찾기