Awesome
<h1 align="center"> š NeoSwap.nvim </h1> <p align="center"> <a href="http://www.lua.org"> <img alt="Lua" src="https://img.shields.io/badge/Lua-blue.svg?style=for-the-badge&logo=lua" /> </a> <a href="https://neovim.io/"> <img alt="Neovim" src="https://img.shields.io/badge/NeoVim-%2357A143.svg?&style=for-the-badge&logo=neovim&logoColor=white" /> </a> </p>š¢ Introduction
NeoSwap simplifies word swapping in Neovim, making it easy to quickly rearrange words within your code.
āØ Features
- Swap words with ease in Neovim using NeoSwap's built-in pattern matching.
- Streamline your coding workflow with efficient word swapping.
š ļø Usage
To swap the position of adjacent words to the right of the cursor, use the NeoSwapNext
command:
:NeoSwapNext
To swap the position of adjacent words to the left of the cursor, use the NeoSwapNext
command:
:NeoSwapPrev
You can also create keybindings to swap words more conveniently:
vim.keymap.set("n", "<leader>s", "<cmd>NeoSwapNext<cr>", { noremap = true, silent = true })
vim.keymap.set("n", "<leader>S", "<cmd>NeoSwapPrev<cr>", { noremap = true, silent = true })
š¦ Installation
- Install via your favorite package manager.
{
"ecthelionvi/NeoSwap.nvim",
opts = {}
},
use "ecthelionvi/NeoSwap.nvim"
- Setup the plugin in your
init.lua
. This step is not needed with lazy.nvim ifopts
is set as above.
require("NeoSwap").setup()
š Acknowledgments
Special thanks to LostNeophyte for their contributions to the development of NeoSwap. Your help is greatly appreciated!