-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Open
Description
In my .config/micro/ I have two files:
init.lua:
function addTextAtTop(buffer, text)
buffer:Start() -- Move cursor to the beginning of the file
buffer:Insert(text) -- Insert the specified text
end
and in my bindings.json I have:
{
"Ctrl-t": "lua:addTextAtTop(buffer, "Your text here\n")"
}
I want to be able to insert Your text here\n at the top of the current buffer, by pressing Ctrl-t
But when create a file with Micro I get:
Lua Error: addTextAtTop(buffer does not exist
What am I not doing correctly? I am a noob when it comes to Micro.
Thanks for your help,
Jerry
Metadata
Metadata
Assignees
Labels
No labels