A command line tool to kill processes.
It's purpose is to focus for a given period of time, blocking all distracting apps specified.
The first time running you will be asked to create a configuration file,
First you'll be asked to provide an interval between process killing times in seconds. It's bound in a u8 that corresponds to a bit less than five minutes. A thirty second interval is normally fine.
Then you will be asked to asked for a period of time to focus in minutes. This value is bound by 65280. This corresponds to 45 days and a bit, but I doubt you need to focus for that long.
At this point you'll be asked for a "password" this password will be asked before some of the actions. The idea being that if the password is long enough you might think twice before pausing, editing or quitting.
Finally you will be asked for the list of processes to kill. Because this list is a list of process names, it can be a little tricky. That's why there is a helper included with this program, the annotator.
An example of the final configuration file is:
killtime: 30 worktime: 30 password: a processes: - firefox-bin - vlc.bin ```
It is possible to have a work time that is smaller than the kill time, it makes sense when you want to run once the killing part, and then quit.
Run the program like this
focus -a
then start your application. This can fail in three ways.
The first way can be circumvented by not running the user check using
focus -A
If that doesn't work in KDE systems control-esc
might help you with the system
activity tool. Probably other DEs have some similar tools, such as the task
manager in windows systems.
In *nix systems other option is to try and identify your process running ps
-e
while it's running the application to identify.
A better way to do basically the same is to follow this instructions
$ ps -e > file1
$ ps -e > file2
$ diff file1 file2
The application accepts the following command line arguments
-a, a, --annotator
: annotator mode, a guide to find processes names-A, A
: annotator mode, a guide to find processes names,
without filtering for user,-f, f, --file [FILE]
:use the config from FILE. FILE can be an
absolute or relative path-s, s, --silent
: no interactions allowed during the focus period-h, h, --help
: show this helpPossible interactions are:
e
: edit the configp
: pauseq
: quit earlyr
: see remaining timea
: add some time to current run (but not to config)You can edit parts or your config. Your available options are:
k
: edit the time that passes between process killingsw
: edit the work timep
: edit the passworde
: edit the processesc
: check the config\q
: stop editing