@agimon-ai/po-git 0.0.0-alpha.214 → 0.0.0-alpha.216
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/dist/apiContracts.cjs +15 -7
- package/dist/apiContracts.cjs.map +1 -1
- package/dist/apiContracts.d.mts.map +1 -1
- package/dist/apiContracts.mjs +15 -7
- package/dist/apiContracts.mjs.map +1 -1
- package/dist/extensions/native.mjs +281 -144
- package/dist/extensions/native.mjs.map +1 -1
- package/dist/extensions/server.cjs +26 -6
- package/dist/extensions/server.cjs.map +1 -1
- package/dist/extensions/server.mjs +26 -6
- package/dist/extensions/server.mjs.map +1 -1
- package/dist/extensions/web.mjs +738 -299
- package/dist/extensions/web.mjs.map +1 -1
- package/dist/{gitDependencies-D8bKxZSc.cjs → gitDependencies-1HXuMSGk.cjs} +16 -8
- package/dist/gitDependencies-1HXuMSGk.cjs.map +1 -0
- package/dist/{gitDependencies-Delu4xip.mjs → gitDependencies-NPktI6YK.mjs} +16 -8
- package/dist/gitDependencies-NPktI6YK.mjs.map +1 -0
- package/dist/index.cjs +1 -1
- package/dist/index.mjs +1 -1
- package/dist/po-runtime-identity.json +1 -1
- package/locales/vi.json +30 -13
- package/locales/zh-CN.json +30 -13
- package/package.json +12 -12
- package/dist/gitDependencies-D8bKxZSc.cjs.map +0 -1
- package/dist/gitDependencies-Delu4xip.mjs.map +0 -1
|
@@ -2,7 +2,7 @@ Object.defineProperties(exports, {
|
|
|
2
2
|
__esModule: { value: true },
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
|
-
const require_gitDependencies = require("../gitDependencies-
|
|
5
|
+
const require_gitDependencies = require("../gitDependencies-1HXuMSGk.cjs");
|
|
6
6
|
let _agimon_ai_po_core_platform = require("@agimon-ai/po-core/platform");
|
|
7
7
|
let _agimon_ai_po_sparo = require("@agimon-ai/po-sparo");
|
|
8
8
|
let _agimon_ai_po_core_serverPlugin = require("@agimon-ai/po-core/serverPlugin");
|
|
@@ -1420,7 +1420,17 @@ function createBranchDiff() {
|
|
|
1420
1420
|
"--git-path",
|
|
1421
1421
|
"rebase-apply"
|
|
1422
1422
|
]);
|
|
1423
|
-
|
|
1423
|
+
let rebase;
|
|
1424
|
+
for (const gitPath of [rebaseMerge, rebaseApply]) {
|
|
1425
|
+
if (gitPath === void 0 || rebase !== void 0) continue;
|
|
1426
|
+
const directory = node_path.default.resolve(root, gitPath);
|
|
1427
|
+
if (!await node_fs_promises.default.access(directory).then(() => true, () => false)) continue;
|
|
1428
|
+
const headName = await node_fs_promises.default.readFile(node_path.default.join(directory, "head-name"), "utf8").then((text) => text.trim().replace(/^refs\/heads\//u, ""), () => "");
|
|
1429
|
+
rebase = {
|
|
1430
|
+
conflicts,
|
|
1431
|
+
...headName === "" || headName === "detached HEAD" ? {} : { branch: headName }
|
|
1432
|
+
};
|
|
1433
|
+
}
|
|
1424
1434
|
const upstreamRef = branch === void 0 ? void 0 : await upstreamOf(root, branch);
|
|
1425
1435
|
let upstream;
|
|
1426
1436
|
if (upstreamRef !== void 0) {
|
|
@@ -1448,7 +1458,7 @@ function createBranchDiff() {
|
|
|
1448
1458
|
...base.ref === void 0 ? {} : { base: base.ref },
|
|
1449
1459
|
...truncated ? { truncated: true } : {},
|
|
1450
1460
|
...upstream === void 0 ? {} : { upstream },
|
|
1451
|
-
...
|
|
1461
|
+
...rebase === void 0 ? {} : { rebase }
|
|
1452
1462
|
},
|
|
1453
1463
|
summary: {
|
|
1454
1464
|
repository: true,
|
|
@@ -2594,13 +2604,23 @@ const PENDING = {
|
|
|
2594
2604
|
rebase: "rebasing…",
|
|
2595
2605
|
"abort-rebase": "aborting the rebase…"
|
|
2596
2606
|
};
|
|
2597
|
-
/**
|
|
2607
|
+
/**
|
|
2608
|
+
* The error target a failure maps to: a rejected plain push asks for a confirmed lease force, and an
|
|
2609
|
+
* auth or dirty-tree refusal names its code so the bar can offer the matching recovery.
|
|
2610
|
+
*/
|
|
2598
2611
|
function errorTargetFor$1(command, error) {
|
|
2599
|
-
|
|
2612
|
+
const code = error instanceof require_gitDependencies.PoGitExpectedError && (error.code === "auth_failed" || error.code === "worktree_dirty") ? { code: error.code } : {};
|
|
2613
|
+
if (command.action !== "push") return {
|
|
2614
|
+
action: command.action,
|
|
2615
|
+
...code
|
|
2616
|
+
};
|
|
2600
2617
|
return error instanceof require_gitDependencies.PoGitExpectedError && error.code === "push_needs_force" && command.force !== true ? {
|
|
2601
2618
|
action: "push",
|
|
2602
2619
|
forceRequired: true
|
|
2603
|
-
} : {
|
|
2620
|
+
} : {
|
|
2621
|
+
action: "push",
|
|
2622
|
+
...code
|
|
2623
|
+
};
|
|
2604
2624
|
}
|
|
2605
2625
|
function failureText$1(error) {
|
|
2606
2626
|
if (error instanceof require_gitDependencies.PoGitExpectedError) return error.message.replace(/^\[[a-z_]+\] /u, "").replace("\nRecovery: ", " ");
|