A Neovim plugin written (mostly) in Lua that implements the Pomodoro technique.
When a timer goes off, a menu is displayed to prompt you to take a break (or start the next pomodoro) with the option to stop the Pomodoro session.
When these prompts are displayed, you can also press b
to take a break (if applicable), p
to start the next pomodoro (if applicable), or q
to stop the Pomodoro session.
Install the plugin with your preferred package manager.
use {
'wthollingsworth/pomodoro.nvim',
requires = 'MunifTanjim/nui.nvim'
}
You can configure the length of the pomodoro, the length of a short break, the length of a long break, and the number of pomodoros that must be completed in order to take a longer break. The values shown below are the defaults.
use {
'wthollingsworth/pomodoro.nvim',
requires = 'MunifTanjim/nui.nvim',
config = function()
require('pomodoro').setup({
time_work = 25,
time_break_short = 5,
time_break_long = 20,
timers_to_long_break = 4
})
end
}
let g:pomodoro_time_work = 25
let g:pomodoro_time_break_short = 5
let g:pomodoro_time_break_long = 20
let g:pomodoro_timers_to_long_break = 4
Three Ex commands are provided.
Command | Description |
---|---|
:PomodoroStart | Starts the timer. |
:PomodoroStatus | Displays the status of the timer in the message area. |
:PomodoroStop | Stops the Pomodoro session. |
For hoob3rt/lualine.nvim, you can do something like:
require('lualine').setup({
sections = {
lualine_c = { 'filename', require('pomodoro').statusline }
}
})