Allow a callback after every command
[screen-lua.git] / src / scripts / cmdcallback.lua
blobcc5d2a377c1f1c96b09380fc2e9262318859ae21
1 --[[ For now, this sample function will simply record all the commands executed ]]--
2 function command_executed(name, args)
3 local f = io.open('/tmp/debug/ll', 'a')
4 f:write("Command executed: " .. name)
6 for i, c in pairs(args) do
7 f:write(" " .. c)
8 end
10 f:write("\n")
11 f:close()
12 end