Skip to content

Commit

Permalink
truncate
Browse files Browse the repository at this point in the history
  • Loading branch information
ipitio committed Jan 26, 2024
1 parent affa215 commit a5f60fc
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions advanced/Scripts/webpage.sh
Original file line number Diff line number Diff line change
Expand Up @@ -640,6 +640,11 @@ generate_systemd_calendar() {
local hour=$(echo "$current_second / 3600" | bc)
local minute=$(echo "($current_second % 3600) / 60" | bc)
local second=$(echo "$current_second % 60" | bc)

hour=${hour%.*}
minute=${minute%.*}
second=${second%.*}

freq_entries+=("*-*-* $(printf "%02d:%02d:%02d" $hour $minute $second)")
current_second=$(echo "$current_second + $total_seconds" | bc)
done
Expand Down

0 comments on commit a5f60fc

Please sign in to comment.