Get work done when you need to, goof off when you don't.
Stay focused on work when you want, and goof off when you don't. Concentration is a simple Python 3 console utility to block distracting sites when you need to focus, while allowing you to easily take timed breaks. Concentration uses the /etc/hosts file as the mechanism to block sites, and works on Linux, Macintosh, and Windows.
pip3 install concentration
Or, if pip is already set to use Python 3
pip install concentration
Or, if you wanted concentration installed and ran in an isolated environment, consider using pipx:
pipx run concentration
To keep focused (blocking distracting sites):
sudo concentration improve
To take a small 5 minute timed break:
sudo concentration break
To take a long 60 minute timed break:
sudo concentration break -m 60
You can cancel breaks with
To disable blocking until you explicitly enable it again:
sudo concentration lose
You can add more files to the blocked list by putting them in the following files (new line delimited):
You can make sure sites are visible even if concentration is enabled by putting them in the following files (new line delimited):
Thanks and I hope you find concentration useful in your effort to get more done!
Release history Release notifications | RSS feed
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
|Filename, size||File type||Python version||Upload date||Hashes|
|Filename, size concentration-1.1.5-py3-none-any.whl (6.7 kB)||File type Wheel||Python version py3||Upload date||Hashes View|
|Filename, size concentration-1.1.5.tar.gz (6.1 kB)||File type Source||Python version None||Upload date||Hashes View|
Hashes for concentration-1.1.5-py3-none-any.whl