Skip to content

Commit f0f15a3

Browse files
committed
Support '^' prefix to call printall_recurse
1 parent f28725d commit f0f15a3

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

lua.lua

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ elseif cmd=="--save" or cmd=="-s" then --luacheck: skip
5050
elseif cmd~=nil then --luacheck: skip
5151
-- Support some of the prefixes allowed by dfhack.interpreter
5252
local prefix
53-
if string.match(cmd, "^[~@!]") then
53+
if string.match(cmd, "^[~@!^]") then
5454
prefix = string.sub(cmd, 1, 1)
5555
cmd = 'return '..string.sub(cmd, 2)
5656
end
@@ -68,6 +68,8 @@ elseif cmd~=nil then --luacheck: skip
6868
printall(rv[2])
6969
elseif prefix == '@' then
7070
printall_ipairs(rv[2])
71+
elseif prefix == '^' then
72+
printall_recurse(rv[2])
7173
end
7274
end
7375
else

0 commit comments

Comments
 (0)