| |
配合邮件的命令,发送报告。

引用

思想:判断月末最后1天,也须是28,29,30,31号;但是月末最后1天的下1天肯定是1号。


适用于:bsh,bash,ksh,Perl
操作系统:Unix平台 linux

#!/bin/bash
#file=
if [ `TZ=PST-24 date +%d` = '01' ];then
       echo "fuck the world"
fi
#$file


更为简单的linux平台下应用。

if [`date -d tomorrow +%d` = '01'];then
    echo "this is cool"
fi



if [`date -d "+1day" +%d` = '01'];then
    echo "day of the month"
fi


本文链接:http://www.52zhe.cn/read.php/48.htm
本文作者:kook(若就博客内所涉及的技术问题交流,请用下面的MSN或Gmail联系我)
联系方式:(MSN:kook#live.com) (Google talk:kookliu)
没有版权:GNU,转载时请注明“转载人”欠本人一顿饭,来日见面之时兑现!谢谢合作!
by kook | 分类: SHELL | 评论(0) | 引用(0) | 阅读(1441)
发表评论
表情
emotemotemotemotemot
emotemotemotemotemot
emotemotemotemotemot
emotemotemotemotemot
emotemotemotemotemot
打开HTML
打开UBB
打开表情
隐藏
记住我
昵称   密码   游客无需密码
网址   电邮   [注册]