I'm looking for a graphical or command line program that provides me with the following workflow:
- Start a 25min session
- After 25min screen is automatically locked for 5min (or maybe just turned black?)
- Now I'm helped to take a break because I cannot do anything in front of the computer other than looking at a black or locked screen :)
- After 5min, the screen automatically returns and I can continue work
Is there a program that does exactly this?
TakeaBreak
TakeaBreak is now on launchpad
Recently (also) pushed for 18.04 / 18.10 / 19.04
Disclaimer: I am the author
Feel free to file bugs etc. here, or comment here. Thanks to orschiro for the nice question, and Rinzwind for the encouragement!
remaining break- seconds (using countdown- option)
Settings
EDIT
An integrated & modernized version for Ubuntu Budgie is now available:
This applet will most likely be available by default in Ubuntu Budgie 19.04, but can now be achieved here as an experimental one.
You may also want to consider Workrave. I found it easy to use and highly customizable. It also has some preatty nice stats about how you use the computer and how many breaks you take. Lastly, I believe it can also sync itself between many computers, which is useful if, for example, you work both on the laptop and on a school computer.
EDIT: It has many other features that I haven't mentioned, like suggesting some exercises for you to do while the screen is blocked. And it can take into account only the time you're using the computer, so it won't prompt you with a break when you come back from the toilet :)
EDIT 2:
Make sure you check out the "Reading" mode!
The above feature of only counting the time you've been actively using the computer can be seen as a bug if you're not doing much (no mouse, no keyboard events) because it will only prompt your break when you cumulate 1h of usage (or how much time you've set up). In these situations, enabling the "Reading" mode will make it prompt at the exact time, regardless of usage.
Crude, minimalist, command-line way:
That can also be turned into a desktop shortcut or turned into function in
.bashrc
Why 1500 and 300? because that's seconds, 1500 seconds /60 seconds per minute = 25 minutes.
Below is a script for a timer that allows setting variable session and break time, as well as methods of signalling the break.
Remember that any script on linux must be saved as a file and have executable permissions set with
chmod +x /path/to/script.sh
. Once that is done, you can bind the script to a shortcut as show in How do I bind .sh files to keyboard combination? or create a desktop shortcut as shown in How can I create launchers on my desktop?When you launch the script you should see a menu like this:
Here is another tool called Safe Eyes for the same purpose.
Features:
For more details: https://github.com/slgobinath/SafeEyes
I have used xwrits for many years for this purpose.
It defaults to a 5 minute break every 55 minutes, but according to the man page these times are customizable via the
breaktime
andtypetime
commandline options, respectively. You can also control whether it locks the screen using the+lock
option. So to set it for a 5 minute break every 25 minutes locking you out, you should run it like thisdrwright was the typing break component that used to be part of gnome: http://zeroset.mnim.org/2012/05/11/drwright-a-typing-break-application-for-gnome-and-unity-on-ubuntu-12-04/
and there is a ppa available (although i have not personally used post-12.04): https://launchpad.net/~drwright/+archive/ubuntu/stable