Cleanup command documentation comments

This commit is contained in:
Kenneth Benzie 2024-04-07 18:45:58 +01:00
parent 04b5e6e4fb
commit 93bea02a48

View File

@ -1,4 +1,4 @@
-- :RString Strip white psace from right of all lines, ranges supported -- :RString strip white psace from right of all lines, ranges supported
vim.api.nvim_create_user_command('RStrip', function(opts) vim.api.nvim_create_user_command('RStrip', function(opts)
local pos = vim.fn.getcurpos(vim.api.nvim_get_current_win()) local pos = vim.fn.getcurpos(vim.api.nvim_get_current_win())
local range = opts.line1 .. ',' .. opts.line2 local range = opts.line1 .. ',' .. opts.line2
@ -7,7 +7,7 @@ vim.api.nvim_create_user_command('RStrip', function(opts)
vim.fn.setpos('.', pos) vim.fn.setpos('.', pos)
end, { range = '%' }) end, { range = '%' })
-- :TabWidth <N> set the tab width for the current buffer -- :TabWidth set the tab width for the current buffer
vim.api.nvim_create_user_command('TabWidth', function(opts) vim.api.nvim_create_user_command('TabWidth', function(opts)
-- Set the tab width for the current filetype -- Set the tab width for the current filetype
-- FIXME: Doesn't seem to cover all bases in neovim when editorconfig is -- FIXME: Doesn't seem to cover all bases in neovim when editorconfig is
@ -103,8 +103,8 @@ end, {
-- TODO: :Mkdir -- TODO: :Mkdir
-- :Rg <STRING> grep for the string and fuzzy find the results, bang to enable -- :Rg grep for the given string and fuzzy find the results, bang to enable
-- regex in search term -- regex in given string
vim.api.nvim_create_user_command('Rg', function(opts) vim.api.nvim_create_user_command('Rg', function(opts)
local grep_opts = { search = opts.args } local grep_opts = { search = opts.args }
if opts.bang then if opts.bang then