batch that comes with the
atd daemon is pretty useful in principle, running commands only when the system utilisation falls below a certain level (by default, 1.5). However, using it (and also
at) is pretty ugly by modern standards: you either have to feed a script which can be run by
/bin/sh, or type commands interactively into a basic prompt with no completion, color-coding, etc.
What would be really nice is a command prefix tool, more like
nice, that one can put in front of any command to add it to the batch queue (and a similar utility for
at would be handy, although that's not the main point of my question). For example, it might work like this:
my-batchifying-command python some_longrunning_computational_script.py
Does such a thing exist? If not, how might it be created? I use
zsh for my main shell, but a
bash answer would be equally OK and might have wider applicability.