neovim

Personal neovim configuration files
git clone git://gtms.dev:neovim
Log | Files | Refs

commit cc4185c8ff0f2e67b2a2d50eb9f85cf2be65978c
parent f80761bdc0c48d669fb0e25ddb75b691736ecd8c
Author: Tomas Nemec <nemi@skaut.cz>
Date:   Tue, 20 Dec 2022 13:31:29 +0100

update

Diffstat:
Mftplugin/dart.lua | 2++
Mplugin/trun.lua | 18++++++++++++++----
Mtest/test.lua | 78++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++--
3 files changed, 92 insertions(+), 6 deletions(-)

diff --git a/ftplugin/dart.lua b/ftplugin/dart.lua @@ -5,6 +5,8 @@ vim.opt_local.isfname:append{ ':' } vim.opt_local.iskeyword:append{ '$' } vim.b.undo_ftplugin = 'setl com< cms< inex< isf<' +vim.cmd.iabbrev('STring', 'String') + local first_line = vim.filetype.getlines(0, 1) if string.match(first_line, '^#!.*dcli') then vim.bo.makeprg = [[dcli run %]] diff --git a/plugin/trun.lua b/plugin/trun.lua @@ -67,14 +67,24 @@ local function trun_to_qf(name) local root = packages_paths[package].root return root .. '/' .. path end) + line = string.gsub(line, '\'package:(.-)/(.-)\'', function(package, path) + local root = packages_paths[package].root + return root .. '/' .. path + end) end table.insert(lines, line) end - vim.fn.setqflist({}, ' ', { - lines = lines, - efm = [[%EErrors in %.%#,%Zline %l\, column %c of %f %m,%f:%l:%c: %t%*[^:]: %m.,%-G%.%#]], - }) + + local efm = { + [[%EErrors in %.%#,%Zline %l\, column %c of %f %m]], + [[%f:%l:%c: %t%*[^:]: %m.]], + [[%EOne or more fatal errors occured during compilation:,%Zline %l\, column %c of asset:%f: %m]], + [[%EError: %m,%Z - %.%# is from %f %.%#]], + [[%-G%.%#]], + } + + vim.fn.setqflist({}, ' ', { lines = lines, efm = table.concat(efm, ',') }) if #vim.fn.getqflist() > 0 then vim.cmd.copen() else diff --git a/test/test.lua b/test/test.lua @@ -42,11 +42,85 @@ Unable to read ng_table|example/app_component.sound.ddc.js, check your console o -- }}} efm = '%f:%l:%c: %t%*[^:]: %m.', }, + { + data = [[ +[INFO] Updating asset graph... +[INFO] Updating asset graph completed, took 1ms + +[INFO] Running build... +[SEVERE] ngdart on example/app_component.dart: +An error occurred compiling third_party/dart/ng_table/example/app_component.dart: +One or more fatal errors occured during compilation: +line 3, column 9 of asset:ng_table/example/app_component.html: Can't bind to 'mdTableFilter' since it isn't a known native property or known directive. Please fix typo or add to directives list. + ╷ +3 │ <th [mdTableFilter]="name"> + │ ^^^^^^^^^^^^^^^^^^^^^^ + ╵ +[SEVERE] ngdart on example/app_component.dart: + +type 'Null' is not a subtype of type 'FutureOr<String>' +[INFO] Running build completed, took 78ms + +[INFO] Caching finalized dependency graph... +[INFO] Caching finalized dependency graph completed, took 210ms + +[SEVERE] build_web_compilers:entrypoint on example/main.dart (cached): +Unable to find modules for some sources, this is usually the result of either a +bad import, a missing dependency in a package (or possibly a dev_dependency +needs to move to a real dependency), or a build failure (if importing a +generated file). + +Please check the following imports: + +`import 'app_component.template.dart';` from ng_table|example/main.dart at 2:1 + ]], + efm = [[%EOne or more fatal errors occured during compilation:,%Zline %l\, column %c of asset:%f: %m,%-G%.%#]], + }, + + { + data = [[ +StdOut: +Warning: The 'dart2js' entrypoint script is deprecated, please use 'dart compile js' instead. +org-dartlang-app:///packages/dpgw_ui/src/commons/tools/forward/pacs_forward/pacs_forward_external_facility_list_element.template.dart@51351+1: +Error: The getter 'A' isn't defined for the class 'PacsForwardExternalFacilityListElement'. + - 'PacsForwardExternalFacilityListElement' is from 'package:dpgw_ui/src/commons/tools/forward/pacs_forward/pacs_forward_external_facility_list_element.dart' ('org-dartlang-app:///packages/dpgw_ui/src/commons/tools/forward/pacs_forward/ +pacs_forward_external_facility_list_element.dart'). +org-dartlang-app:///packages/dpgw_ui/src/commons/tools/forward/pacs_forward/pacs_forward_external_facility_list_element.template.dart@51810+10: +Error: The getter 'connection' isn't defined for the class 'PacsForwardExternalFacilityListElement'. + - 'PacsForwardExternalFacilityListElement' is from 'package:dpgw_ui/src/commons/tools/forward/pacs_forward/pacs_forward_external_facility_list_element.dart' ('org-dartlang-app:///packages/dpgw_ui/src/commons/tools/forward/pacs_forward/ +pacs_forward_external_facility_list_element.dart'). +org-dartlang-app:///packages/dpgw_ui/src/commons/tools/forward/pacs_forward/pacs_forward_external_facility_list_element.template.dart@51997+1: +Error: The getter 'B' isn't defined for the class 'PacsForwardExternalFacilityListElement'. + - 'PacsForwardExternalFacilityListElement' is from 'package:dpgw_ui/src/commons/tools/forward/pacs_forward/pacs_forward_external_facility_list_element.dart' ('org-dartlang-app:///packages/dpgw_ui/src/commons/tools/forward/pacs_forward/ +pacs_forward_external_facility_list_element.dart'). +org-dartlang-app:///packages/dpgw_ui/src/commons/tools/forward/pacs_forward/pacs_forward_external_facility_list_element.template.dart@52456+10: +Error: The getter 'connection' isn't defined for the class 'PacsForwardExternalFacilityListElement'. + - 'PacsForwardExternalFacilityListElement' is from 'package:dpgw_ui/src/commons/tools/forward/pacs_forward/pacs_forward_external_facility_list_element.dart' ('org-dartlang-app:///packages/dpgw_ui/src/commons/tools/forward/pacs_forward/ +pacs_forward_external_facility_list_element.dart'). +org-dartlang-app:///packages/dpgw_ui/src/commons/tools/forward/pacs_forward/pacs_forward_external_facility_list_element.template.dart@52643+1: +Error: The getter 'C' isn't defined for the class 'PacsForwardExternalFacilityListElement'. + - 'PacsForwardExternalFacilityListElement' is from 'package:dpgw_ui/src/commons/tools/forward/pacs_forward/pacs_forward_external_facility_list_element.dart' ('org-dartlang-app:///packages/dpgw_ui/src/commons/tools/forward/pacs_forward/ +pacs_forward_external_facility_list_element.dart'). +org-dartlang-app:///packages/dpgw_ui/src/commons/tools/forward/pacs_forward/pacs_forward_external_facility_list_element.template.dart@53102+10: +Error: The getter 'connection' isn't defined for the class 'PacsForwardExternalFacilityListElement'. + - 'PacsForwardExternalFacilityListElement' is from 'package:dpgw_ui/src/commons/tools/forward/pacs_forward/pacs_forward_external_facility_list_element.dart' ('org-dartlang-app:///packages/dpgw_ui/src/commons/tools/forward/pacs_forward/ +pacs_forward_external_facility_list_element.dart'). +Error: Compilation failed. +]], + efm = [[%EError: %m,%Z - %.%# is from '%f' %.%#]], + }, } -local ACTIVE = 2 +local ACTIVE = 4 local err = data[ACTIVE].data -local efm = data[ACTIVE].efm +-- local efm = data[ACTIVE].efm +local efm = table.concat({ + [[%EErrors in %.%#,%Zline %l\, column %c of %f %m]], + [[%f:%l:%c: %t%*[^:]: %m.]], + [[%EOne or more fatal errors occured during compilation:,%Zline %l\, column %c of %f %m]], + [[%EError: %m,%Z - %.%# is from %f %.%#]], + [[%-G%.%#]], +}, ',') vim.fn.setqflist({}, 'r') local lines = {}