diff --git a/dist/index.js b/dist/index.js index 42bf3a5..3dbde88 100644 --- a/dist/index.js +++ b/dist/index.js @@ -4342,7 +4342,7 @@ const external_child_process_namespaceObject = require("child_process"); var promise_deferred_dist = __nccwpck_require__(8156); ;// CONCATENATED MODULE: external "node:events" const external_node_events_namespaceObject = require("node:events"); -;// CONCATENATED MODULE: ./node_modules/.pnpm/simple-git@3.25.0/node_modules/simple-git/dist/esm/index.js +;// CONCATENATED MODULE: ./node_modules/.pnpm/simple-git@3.27.0/node_modules/simple-git/dist/esm/index.js var __defProp = Object.defineProperty; var __defProps = Object.defineProperties; var __getOwnPropDesc = Object.getOwnPropertyDescriptor; @@ -6327,15 +6327,17 @@ var init_parse_diff_summary = __esm({ nameStatusParser = [ new LineParser( /([ACDMRTUXB])([0-9]{0,3})\t(.[^\t]*)(\t(.[^\t]*))?$/, - (result, [status, _similarity, from, _to, to]) => { + (result, [status, similarity, from, _to, to]) => { result.changed++; result.files.push({ file: to != null ? to : from, changes: 0, - status: orVoid(isDiffNameStatus(status) && status), insertions: 0, deletions: 0, - binary: false + binary: false, + status: orVoid(isDiffNameStatus(status) && status), + from: orVoid(!!to && from !== to && from), + similarity: asNumber(similarity) }); } ) @@ -6364,15 +6366,12 @@ function createListLogSummaryParser(splitter = SPLITTER, fields = defaultFieldNa const parseDiffResult = getDiffParser(logFormat); return function(stdOut) { const all = toLinesWithContent( - stdOut, - true, + stdOut.trim(), + false, START_BOUNDARY ).map(function(item) { - const lineDetail = item.trim().split(COMMIT_BOUNDARY); - const listLogLine = lineBuilder( - lineDetail[0].trim().split(splitter), - fields - ); + const lineDetail = item.split(COMMIT_BOUNDARY); + const listLogLine = lineBuilder(lineDetail[0].split(splitter), fields); if (lineDetail.length > 1 && !!lineDetail[1].trim()) { listLogLine.diff = parseDiffResult(lineDetail[1]); } @@ -6994,16 +6993,16 @@ var fromPathRegex, FileStatusSummary; var init_FileStatusSummary = __esm({ "src/lib/responses/FileStatusSummary.ts"() { "use strict"; - fromPathRegex = /^(.+) -> (.+)$/; + fromPathRegex = /^(.+)\0(.+)$/; FileStatusSummary = class { constructor(path, index, working_dir) { this.path = path; this.index = index; this.working_dir = working_dir; - if ("R" === index + working_dir) { + if (index === "R" || working_dir === "R") { const detail = fromPathRegex.exec(path) || [null, path, path]; - this.from = detail[1] || ""; - this.path = detail[2] || ""; + this.from = detail[2] || ""; + this.path = detail[1] || ""; } } }; @@ -7041,7 +7040,7 @@ function splitLine(result, lineStr) { handler(result, path); } if (raw !== "##" && raw !== "!!") { - result.files.push(new FileStatusSummary(path.replace(/\0.+$/, ""), index, workingDir)); + result.files.push(new FileStatusSummary(path, index, workingDir)); } } }