diff --git a/README.md b/README.md index 23a0f9c..66d2081 100644 --- a/README.md +++ b/README.md @@ -46,7 +46,7 @@ ```lua use { 'JuanZoran/Trans.nvim' - run = 'install.sh', + run = 'bash ./install.sh', requires = 'kharji/sqlite.lua', -- 如果你不需要任何配置的话, 可以直接按照下面的方式启动 config = require'Trans'.setup{} @@ -114,7 +114,7 @@ require'Trans'.setup{ > 示例中展示, 将`mm`映射成快捷键 ```lua -- normal-mode -vim.keymap.set('n', 'mm', 'TranslateCurosorWord') +vim.keymap.set('n', 'mm', 'TranslateCursorWord') -- visual-mode vim.keymap.set('v', 'mm', 'TranslateSelectWord') diff --git a/lua/Trans/setup.lua b/lua/Trans/setup.lua index 3a2e4ee..35e5379 100644 --- a/lua/Trans/setup.lua +++ b/lua/Trans/setup.lua @@ -2,7 +2,7 @@ local db = require("Trans").db -- local conf = require("Trans").conf -vim.api.nvim_create_user_command('TranslateCurosorWord', require("Trans.display").query_cursor, {}) +vim.api.nvim_create_user_command('TranslateCursorWord', require("Trans.display").query_cursor, {}) vim.api.nvim_create_user_command('TranslateSelectWord', require("Trans.display").query_select, {})