From 028172b01d46af1f8b1be1a599fe629d23c73a21 Mon Sep 17 00:00:00 2001 From: ochafik Date: Sun, 26 Mar 2023 08:34:28 +0100 Subject: [PATCH] Fix line skipping in markers processing --- src/actions.ts | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/src/actions.ts b/src/actions.ts index 46fc303..f9d9141 100644 --- a/src/actions.ts +++ b/src/actions.ts @@ -26,7 +26,10 @@ export const checkSyntax = try { const result = await job; // console.log(result); - res(processMergedOutputs(result.mergedOutputs, {shiftSourceLines: {[sourcePath]: 1}})); + res(processMergedOutputs(result.mergedOutputs, {shiftSourceLines: { + [sourcePath]: 1, + [sourcePath.split('/').slice(-1)[0]]: 1 + }})); } catch (e) { console.error(e); rej(e); @@ -77,7 +80,10 @@ export const render = console.log(result); const {logText, markers} = processMergedOutputs(result.mergedOutputs, { - shiftSourceLines: {[params.sourcePath]: prefixLines.length} + shiftSourceLines: { + [params.sourcePath]: prefixLines.length, + [params.sourcePath.split('/').slice(-1)[0]]: prefixLines.length + } }); if (result.error) {