local-lua-debugger-vscode
local-lua-debugger-vscode copied to clipboard
TIC-80 support
Your debugger is awesome, but unfortunately, it is not compatible with tic-80 because there is no access to global os:
TIC-80 tiny computer
version 1.0.1770-dev Pro (60e63de)
https://tic80.com (C) 2017-2021
loading cart...
>./run/debugger.lua:1: attempt to index a nil value (global 'os')
>
Maybe you have some idea how to fix it?
if you use os only for os.execute, maybe you can replace it with something like this:
local function execute(command)
local f = io.popen(command)
local l = f:read("*a")
f:close()
return l
end
print(execute("echo $USER"))
... oh, never mind, io is also not available 😢
os is used specifically for os.getenv to read settings passed from the vscode extension. It might be possible to refactor things to not require this. But, not having io is a dealbreaker. That's required for communicating over stdio or pipes. Without that, I don't think there's any way for the debugger to work.