commit dcc2920c444e7800a838ee1163250fb211ce0974
parent da67c3a3a7a8d4e13276d445d621c35ac6f79c2f
Author: Tomas Nemec <nemi@skaut.cz>
Date: Fri, 20 Jan 2023 10:53:41 +0100
update
Diffstat:
1 file changed, 7 insertions(+), 3 deletions(-)
diff --git a/plugin/trun.lua b/plugin/trun.lua
@@ -58,17 +58,21 @@ local function trun_to_qf(name)
if string.find(line, 'Starting Build') then
lines = {}
end
- -- TODO(tms) 16.12.22: translate
+ -- translate
if package_name and packages_paths then
local package_root = packages_paths[package_name].root
line = string.gsub(line, '^.-:%d+:%d+:',
package_root .. '/' .. '.dart_tool/build/generated/' .. package_name .. '/%0')
line = string.gsub(line, 'asset:(.-)/(.-):', function(package, path)
- local root = packages_paths[package].root
+ local root = packages_paths[package].lib
return root .. '/' .. path
end)
line = string.gsub(line, '\'package:(.-)/(.-)\'', function(package, path)
- local root = packages_paths[package].root
+ local root = packages_paths[package].lib
+ return root .. '/' .. path
+ end)
+ line = string.gsub(line, 'package:(.-)/(.-):', function(package, path)
+ local root = packages_paths[package].lib
return root .. '/' .. path
end)
end