This guide will walk you through setting up a Pomodoro timer script using Windows Subsystem for Linux (WSL) on your Windows 11 system.
WSL allows you to run a Linux distribution alongside your Windows installation. Follow these steps to set it up:
-
Open PowerShell as Administrator and run the following command to enable WSL:
wsl --install -
Restart your computer if prompted.
-
After rebooting, install a Linux distribution from the Microsoft Store (e.g., Ubuntu).
- WSL Installed: Ensure that WSL is installed and a Linux distribution (e.g., Ubuntu) is set up on your system.
- Clone the Repository: Clone this repository to your local machine.
git clone https://github.com/your-username/pomodoro-wsl.git
cd pomodoro-wsl-
Open your newly installed Linux distribution from the Start menu.
-
Step 2: Install Necessary Packages Install the required packages (
espeak,lolcat,golang,spd-say, andnotify-send).sudo apt update && sudo apt upgrade -y sudo apt install espeak lolcat golang spd-say libnotify-bin -y # Install timer from source git clone https://github.com/caarlos0/timer.git cd timer go build sudo mv timer /usr/local/bin/timer cd .. rm -rf timer
Source the Script : Source the script to load the aliases and functions.
Make the script executable:
# Navigate to the directory where pomodoro.sh is saved
cd /path/to/your/script
chmod +x pomodoro.shSource the script to use the aliases:
source pomodoro.shYou can now use the following commands:
doro 3 # Start with 3 loops of work and break sessions
doro # Start with the default number of loops (2 loops)
## Run the Aliasescp work 50 # Change work time to 50 minutes
cp break 15 # Change break time to 15 minutesNow you can run the aliases wo and br from your terminal:
wo # Start a work session
br # Start a break session