|
60 | 60 | -- Set macro to register (Escaped termcodes)
|
61 | 61 | local function set_macro_to_register(macro_content)
|
62 | 62 | if not macro_content then
|
63 |
| - print_error("Macro content is nil. Cannot set to register.") |
| 63 | + print_error("Macro content is empty. Cannot set to register.") |
64 | 64 | return
|
65 | 65 | end
|
66 | 66 |
|
@@ -120,7 +120,7 @@ function M.yank(register)
|
120 | 120 | register = register or vim.fn.input("Please specify a register to yank from: ")
|
121 | 121 | local register_content = vim.fn.getreg(register)
|
122 | 122 | if not register_content or register_content == "" then
|
123 |
| - print_error("Invalid or empty register content!") |
| 123 | + print_error("Register is empty or has invalid content!") |
124 | 124 | return
|
125 | 125 | end
|
126 | 126 |
|
|
132 | 132 | -- Run macros from inside a function (For keymaps)
|
133 | 133 | function M.run(macro)
|
134 | 134 | if not macro then
|
135 |
| - print_error("Macro is nil. Cannot run.") |
| 135 | + print_error("Macro is Empty. Cannot run.") |
136 | 136 | return
|
137 | 137 | end
|
138 | 138 | vim.cmd.normal(vim.api.nvim_replace_termcodes(macro, true, true, true))
|
@@ -208,15 +208,15 @@ function M.select_and_yank_macro()
|
208 | 208 |
|
209 | 209 | if yank_option == "1" then
|
210 | 210 | set_macro_to_register(macro_content)
|
211 |
| - print("Yanked to Clipboard (p to paste) " .. choice:match("^[^|]+")) |
| 211 | + print("Yanked to Clipboard (p to paste): " .. choice:match("^[^|]+")) |
212 | 212 | elseif yank_option == "2" then
|
213 | 213 | local target_register = vim.fn.input("Please specify a register to set the macro to: ")
|
214 | 214 | if not target_register or target_register == "" then
|
215 | 215 | print_error("Invalid or empty register specified.")
|
216 | 216 | return
|
217 | 217 | end
|
218 | 218 | set_decoded_macro_to_register(encoded_content, target_register)
|
219 |
| - print("Yanked Raw Macro " .. choice:match("^[^|]+") .. " into register `" .. target_register .. "`") |
| 219 | + print("Yanked Raw Macro: " .. choice:match("^[^|]+") .. " into register `" .. target_register .. "`") |
220 | 220 | else
|
221 | 221 | print_error("Invalid yank option selected.")
|
222 | 222 | end
|
|
0 commit comments