Proposal: Improved Implementation of Sleep Command
With this patch, the sleep command will be able to process floating point numbers as input so that it will be possible to sleep for shorter time periods, such as 0.5 seconds. It will also be able to accept input with a human-readable suffix indicating the duration of time to sleep (s for seconds, m for minutes, h for hours and d for days). Finally, it will also be able to accept multiple input arguments, allowing sleep to sleep for the combined amount of time specified (will make more sense for why when given the following example). In addition, I've also replaced the deprecated code with the current standard.
Example:
-
sleep 60
is equivalent tosleep 1m
-
sleep 90
is equivalent tosleep 1.5m
is equivalent tosleep 1m 30s