在Bash Script裡要怎樣才能每當01:05、02:05、03:05...等時刻執行某段指令?
目前想到的方法只有每分鐘讀一次date +%H%M,然後檢查一大串的0105、0205...:
(sleep 60)
if [ current_time -eq 0105 ] || [ current_time -eq 0205 ] || ..............
這下一共要寫二十四個,好像很白痴又累墜。請問有沒有什麼其他解法?謝謝。
--
--
目前想到的方法只有每分鐘讀一次date +%H%M,然後檢查一大串的0105、0205...:
(sleep 60)
if [ current_time -eq 0105 ] || [ current_time -eq 0205 ] || ..............
這下一共要寫二十四個,好像很白痴又累墜。請問有沒有什麼其他解法?謝謝。
--
推 defenser:我承認她們全都是我的後宮(  ̄ c ̄)y▇▇▇▇▇▇▇~※ 04/08 21:32
推 BSpowerx: ◤ 大砲 █● 04/08 21:34
推 cy0816: ▇▇▇▇▇▇▇▇▇▇04/08 21:35
→ Augustus5: ●04/08 21:35
→ LoveMakeLove: *******************04/08 21:35
推 Raptorjet:樓上那啥鬼04/08 21:38
--
All Comments