Skip to content

Instantly share code, notes, and snippets.

@DevKaiPereira
Forked from bashbunni/.zshrc
Created January 20, 2026 00:25
Show Gist options
  • Select an option

  • Save DevKaiPereira/a2e8a2be4e38fbdd274f9a007d7793ef to your computer and use it in GitHub Desktop.

Select an option

Save DevKaiPereira/a2e8a2be4e38fbdd274f9a007d7793ef to your computer and use it in GitHub Desktop.
CLI Pomodoro for Mac
# I'll be doing another one for Linux, but this one will give you
# a pop up notification and sound alert (using the built-in sounds for macOS)
# Requires https://github.com/caarlos0/timer to be installed
# Mac setup for pomo
alias work="timer 60m && terminal-notifier -message 'Pomodoro'\
-title 'Work Timer is up! Take a Break 😊'\
-appIcon '~/Pictures/pumpkin.png'\
-sound Crystal"
alias rest="timer 10m && terminal-notifier -message 'Pomodoro'\
-title 'Break is over! Get back to work 😬'\
-appIcon '~/Pictures/pumpkin.png'\
-sound Crystal"
# Use a pomodoro timer with the fish shell.
# This requires https://github.com/caarlos0/timer to be installed and https://github.com/charmbracelet/gum on PATH
function pom
set split $POMO_SPLIT
if ! test -n "$split"
set split $(gum choose "25/5" "50/10" "all done" --header "Choose a pomodoro split.")
end
switch $split
case '25/5'
set work "25m"
set break "5m"
case '50/10'
set work "50m"
set break "10m"
case 'all done'
return
end
timer $work && terminal-notifier -message 'Pomodoro'\
-title 'Work Timer is up! Take a Break 😊'\
-sound Crystal
gum confirm "Ready for a break?" && \
timer $break && terminal-notifier -message 'Pomodoro'\
-title 'Break is over! Get back to work 😬'\
-sound Crystal \
|| pom
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment