https://github.com/timseriakov/spamguard.nvim
https://github.com/timseriakov/spamguard.nvim
Last synced: 10 days ago
JSON representation
- Host: GitHub
- URL: https://github.com/timseriakov/spamguard.nvim
- Owner: timseriakov
- License: other
- Created: 2025-04-21T09:05:24.000Z (17 days ago)
- Default Branch: master
- Last Pushed: 2025-04-21T10:17:22.000Z (17 days ago)
- Last Synced: 2025-04-21T10:23:56.673Z (17 days ago)
- Language: Lua
- Size: 6.84 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- trackawesomelist - timseriakov/spamguard.nvim (⭐5) - Detects excessive key spamming (jjjj/kkkk) and suggests more efficient alternatives. (Recently Updated / [Apr 28, 2025](/content/2025/04/28/README.md))
- awesome-neovim-sorted - timseriakov/spamguard.nvim
README
# spamguard.nvim 🛡️
A minimal Neovim plugin that detects excessive key spamming (`jjjjjj`) and suggests more efficient alternatives.
## 📽️ Demo (neovide)

## ✨ Features
- Detects spam on keys like `j`, `k`, `h`, `l`, `w`
- Displays suggestions for more effective motion usage (e.g. `use 10j`)
- Tracks daily and weekly key usage
- Command `:SpamStats` to view usage stats
- Fully configurable thresholds and suggestions 🎯---
## 🚀 Installation
Using [lazy.nvim](https://github.com/folke/lazy.nvim):
```lua
return { "timseriakov/spamguard.nvim" }
```---
## ⚙️ Configuration
You can pass custom thresholds and suggestions for specific keys:
```lua
return {
"timseriakov/spamguard.nvim",
config = function()
require("spamguard").setup({
keys = {
j = { threshold = 6, suggestion = "use s or f instead of spamming jjjj 😎" },
k = { threshold = 6, suggestion = "try 10k instead of spamming kkkk 😎" },
h = { threshold = 8, suggestion = "use 10h or b / ge 😎" },
l = { threshold = 8, suggestion = "try w or e — it's faster! 😎" },
w = { threshold = 5, suggestion = "use s or f — more precise and quicker! 😎" },
},
})
end,
}
```If a key is not listed in your config, it will fall back to the default behavior.
---
## 📊 Commands
`:SpamStats` — Show usage stats:
- 📅 For today
- 🗓️ For the last 7 days---
## 🧠 Why?
This plugin encourages better navigation habits by gently reminding you to use more efficient motion commands instead of repeatedly mashing navigation keys.
---
## 📄 License
MIT © [Tim Seriakov](https://github.com/timseriakov)