Add example usage to Readme
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
IamTheFij 2024-10-21 16:24:09 -07:00
parent 0d2589043f
commit 195004a4f4

View File

@ -87,6 +87,30 @@ Set custom colors for the progress bar:
./gomodoro --color-left="#ff0000" --color-right="#00ff00" ./gomodoro --color-left="#ff0000" --color-right="#00ff00"
``` ```
## Some Pro Tips!
- Use the `--on-focus-start` and `--on-focus-end` options to run commands that help you get into the zone and wind down after a focus period or to control your environment (e.g., turning off notifications).
### My example usage
I used Shortcuts on my mac to control macOS Focus mode. I named them "Turn On Focus" and "Turn Off Focus". This allows my focus start and end commands to control my notifications for my computer and phone (since I have them synced).
I also use [Slack Status CLI](https://git.iamthefij.com/iamthefij/slack-status-cli) to set my Slack status to a snooze mode with a tomato emoji when I'm in focus mode and turn it off after.
```sh
gomodoro \
--fullscreen \
--color-left '#ecdfb1' \
--color-right '#c6e889 ' \
--on-focus-start "shortcuts run 'Turn On Focus'" \
--on-focus-start "say 'Time to focus'" \
--on-focus-start "slack-status -snooze -duration 1h -emoji :tomato: Focus" \
--on-focus-end "shortcuts run 'Turn Off Focus'" \
--on-focus-end "say 'Break time you slacker'" \
--on-focus-end "slack-status" \
--on-interval-end "say 'Interval done! Phew!'"
```
## License ## License
This project is licensed under the MIT License. See the [LICENSE](LICENSE) file for details. This project is licensed under the MIT License. See the [LICENSE](LICENSE) file for details.