当前位置:网站首页>Busybox specified date modification temporarily does not require clock -w to write to hardware
Busybox specified date modification temporarily does not require clock -w to write to hardware
2022-07-19 06:27:00 【xp5xp6】
#!/bin/bash
y_begin=$1
m_begin=$2
d_begin=$3
y_end=$4
m_end=$5
d_end=$6
echo $y_begin $m_begin $d_begin
echo $y_end $m_end $d_end
tmp=""
tomorrowday=""
begin="$y_begin$m_begin$d_begin"
echo $begin
end="$y_end$m_end$d_end"
echo $end
year=$y_begin
month=$m_begin
day=$d_begin
echo ${year} ${month} ${day}
fun_next_day()
{
#echo "---${year} ${month} ${day}"
if [[ "$day" == "31" ]];then
if [[ "$month" == "12" ]];then
day="01"
month="01"
year=`expr $year + 1`
elif [[ "$month" == "01" || "$month" == "03" || "$month" == "05" || "$month" == "07" || "$month" == "08" || "$month" == "10" ]];then
day="01"
month=`expr ${
month} + 1`
month=$(printf "%02d" "$month")
fi
elif [[ "$day" == "30" ]];then
#echo "--30-----"
if [[ "$month" == "04" || "$month" == "06" || "$month" == "09" || "$month" == "11" ]];then
#echo "--31-----"
day="01"
month=`expr ${
month} + 1`
month=$(printf "%02d" "$month")
else
#echo "--32-----"
day=`expr $day + 1`
day=$(printf "%02d" "$day")
#echo "day------$day"
fi
elif [[ "$day" == "29" && "$month" == "02" ]];then
day="01"
month=`expr ${
month} + 1`
month=$(printf "%02d" "$month")
tomorrowday="${year}${month}${day}"
elif [[ "$day" == "28" && "$month" == "02" ]];then
year_type=`expr ${
year} % 4`
if [[ "$year_type" == "0" ]];then
day=`expr $day + 1`
day=$(printf "%02d" "$day")
else
day="01"
month=`expr ${
month} + 1`
month=$(printf "%02d" "$month")
fi
else
day=`expr $day + 1`
day=$(printf "%02d" "$day")
#echo "day---$day"
fi
tomorrowday="${year}${month}$day"
echo $tomorrowday
#tmp="${year}${month}$day"
#echo $tmp
#echo "end ---${year} ${month} ${day}"
#return $tomorrowday
}
echo "----------begin------"
echo $end
while [ "$begin" != "$end" ]
do
echo "begin--- $begin"
date -s "$begin"0000""
fun_next_day
begin=$tomorrowday
sleep 5
done
边栏推荐
- Decorate Apple Tree
- 【力扣】二叉树的前序遍历
- Basic mathematics course 2_ Euler function, linear sieve, extended Euler
- Internship written examination answers
- Guess the string (dichotomy, interaction)
- 结合图片看常用串口通信UART
- 2022/07/10 第五小组 丁帅 学习笔记 day03
- MySQL workbench basically uses [create a data table]
- 索引库中的文档的操作
- 數學基礎課2_歐拉函數,線性篩,擴歐
猜你喜欢
![MySQL workbench basically uses [create a data table]](/img/cf/00818451ef0e8bcd5cc1d12f00d27c.png)
MySQL workbench basically uses [create a data table]
![[force buckle] realize stack with queue](/img/9b/8b09eb60ad1191a24eb31478620c07.png)
[force buckle] realize stack with queue

Qt Creator闪退解决办法
![[force buckle] realize queue with stack](/img/cb/7c4d01cab50b8027b8a4d67509b7dd.png)
[force buckle] realize queue with stack
![[simple and fast] after startup, the desktop is normal, and the taskbar below is unresponsive / the mouse keeps turning](/img/65/fbb975491d4abd5d1babdf000513e2.png)
[simple and fast] after startup, the desktop is normal, and the taskbar below is unresponsive / the mouse keeps turning

Talking about several solutions of cross domain

通過VOR深度估計解决三維注視交互中的目標模糊問題

有线电视网(树上分组)
![[force buckle] symmetric binary tree](/img/a4/31e936fb242aa8a3243ea257f5fd29.png)
[force buckle] symmetric binary tree

RestClient查询文档
随机推荐
Darwin's analytical experience
WebService接口的创建与实现
你的企业最适合哪种深度学习?
单表查询、添加、更新与删除数据
XOR gun (bit operation, thinking, interval violence)
Markdown syntax and common shortcuts
filezilla传输虚拟机速度慢解决方法
Eye tracking in virtual reality
Unity2D学习 Fox Game制作 过程1:基本的游戏角色控制,动画效果,镜头控制,物品收集,bug优化
【力扣】复制带随机指针的链表
[force buckle] bracket matching
串口循环缓存区 简单 免初始化 不用堆、指针、分段memcpy
Antd is not defined
Make config analysis of configuration commands before uboot compilation
实习笔试解答
vscode one dark和c扩展变量颜色冲突 设置settings.json如下即可
uboot 编译前的配置命令make config分析
Decorate Apple Tree
Simple chrome script automatically skips the charging acknowledgment page after the video playback of station B ends
Longest bracket match (linear DP)