fix: Fixes readme.

This commit is contained in:
2025-11-21 13:29:19 -05:00
parent b70efd44c4
commit 47f5a32ce8
2 changed files with 105 additions and 1 deletions

View File

@@ -1,3 +1,28 @@
# shortenurl.nvim
Small neovim plugin to shorten urls, using shlink and the shorten-url scripts in my dotfiles.
This is a small neovim plugin that can convert urls to short urls, using the `shoren-url` bash script found in my
dotfiles repo.
## Usage
```lua
vim.pack.add({
{ src = "https://git.housh.dev/michael/shortenurl.nvm" },
})
```
### Create keybinds
```lua
vim.keymap.set({ 'n', 'v', 'x' }, '<leader>lc', function()
require('shortenurl').convertUrl()
end, { desc = "[L]ink [c]onvert to short url." })
vim.keymap.set('n', '<leader>ls', function()
require('shortenurl').prompt()
end, { desc = "[L]ink [s]horten, prompting for url." })
vim.keymap.set('n', '<leader>lv', function()
require('shortenurl').convertFromClipboard()
end, { desc = "[L]ink convert url from cliboard to short url." })
```