Beeminder + HeyFocus.com integration
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
.gitignore
README.md
bee-focused.py
goals_example.json

README.md

bee-focused

"The Taskmaster"

Description

Requirements

Setup

Log into Beeminder, and then download auth_token.json at this url and place it in the bee-focused root folder:

https://www.beeminder.com/api/v1/auth_token.json

Copy goals_example.json to goals.json and edit to reflect which of your Beeminder goals you want to use to trigger focus time.

chmod +x bee-focused.py
./bee-focused.py

Add an entry to your crontab to run the script every few minutes:

  • Find the path to your local copy of Python 3: which python3
  • Open Crontab: export VISUAL=nano; crontab -e
  • Add this line: */5 * * * * /path/to/python3 /path/to/bee-focused/bee-focused.py >>/path/to/bee-focused/cron.log 2>&1
  • Save and exit

In order to allow you to enable Focus separately from this script, bee-focused never explicitly unfocuses. Instead, it starts 7-minute focus sessions and then lets the last one expire when you're caught up on your goals. For that reason, it's important that the script runs at least every seven minutes (I suggest every five) in order to insure that there isn't time between when one focus session expires and the next is initiated.

Information

  • Beeminder API docs
  • "lane (number): Where you are with respect to the yellow brick road (2 or more = above the road, 1 = top lane, -1 = bottom lane, -2 or less = below the road)."
  • Focus scripting docs