new command: batch GET
We need this to speed up the initial load of the driver.
This commit is contained in:
parent
7a1c556918
commit
4d81e495f8
9
live.lua
9
live.lua
|
@ -234,6 +234,15 @@ function live.run(buf)
|
|||
elseif cmd == 'GET' then
|
||||
local binding = buf:match('^%S+%s+(%S+)')
|
||||
live.send_to_driver(live.get_binding(binding))
|
||||
elseif cmd == 'GET*' then
|
||||
-- batch version of GET
|
||||
local result = {}
|
||||
for binding in buf:gmatch('%s+(%S+)') do
|
||||
print(binding)
|
||||
local val, _ = app.get_binding(binding)
|
||||
table.insert(result, val)
|
||||
end
|
||||
app.send(table.concat(result, '\n--fw: definition boundary--\n'))
|
||||
-- other commands go here
|
||||
else
|
||||
local binding = cmd
|
||||
|
|
Loading…
Reference in New Issue
Block a user