Skip to content

Commit

Permalink
feat: set timeout to 0 to disable donuts (#5)
Browse files Browse the repository at this point in the history
  • Loading branch information
NStefan002 committed May 30, 2024
1 parent 1ca9ac0 commit 5b48a96
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions lua/donut/donut_spawn.lua
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,9 @@ function DonutSpawn:start_timer()
0,
1000,
vim.schedule_wrap(function()
if vim.g.donut_config.timeout == 0 then
return
end
self.time_since_last_keypress = self.time_since_last_keypress + 1
if self.time_since_last_keypress > vim.g.donut_config.timeout and not self.active then
self:spawn_donuts()
Expand Down

0 comments on commit 5b48a96

Please sign in to comment.