Rewrote generate_time_entries, smaller & pwettier

Also less safe. But eh, doesn't seem to be a big deal?