This could be a useful script that could be used for many different workflows.īut, before I spend some time working it out, does anyone already have a script that does what's outlined above? I'd rather not go around reinventing wheels. I'll even try to get it to recognize 2.5H and strings like 2 hours 15 minutes 34 seconds. I can also include minutes in the script as well as seconds (although the seconds would be mostly useless, but it would help for usability in that people would expect it to be there). I'll try to include other options like 1H or 1 H or 1 Hour or 2 Hours or even Two Hours, but the latter one might be harder. When I get a bit of time, I'll try to write a bash script that will be able to convert times to seconds so that a user could write 1h and that would convert to 3600. Although, I might be missing something obvious. I'd like to be able to query caffienate to see if it's running, and, if it is, how much longer it will be on for. However, it seems to be lacking something like a status check. There are many more options for caffeinate that can be found here: So, if you want to run caffeinate in the background just type: Remember, that the Ctrl+C hotkey can be avoided by making the process go into the background by just adding the "&" character afterward. I like the little icon to let me know, but I might be able to part with it. If this hotkey could be disabled, I'd be happy to build a new workflow around this and abandon Caffeine and Should I Sleep all together. Found some documentation on it, and I don't like that it can be switched off so easily (Control + C).
0 Comments
Leave a Reply. |