@dylanpiercey/work 0.0.134 → 0.0.135
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/dist/_B1bgL2tH.js +2 -0
- package/dist/_B3qThpAM.js +2 -0
- package/dist/_BIxwPE98.js +2 -0
- package/dist/{_BBmEhpPH.js → _BJg54Xa1.js} +7 -3
- package/dist/{_D2Ne8oPk.js → _BZpXh6Js.js} +2 -2
- package/dist/{_C04hN9Ui.js → _Boofe5nI.js} +4 -4
- package/dist/{_wkybTEDR.js → _DwK89Lz-.js} +72 -20
- package/dist/{_DBPJnjxF.js → _Fhn3V9QC.js} +50 -50
- package/dist/index.mjs +164 -164
- package/dist/public/assets/{_C0TsHYWM2.js → _0fZEmB9p2.js} +1 -1
- package/dist/public/assets/_0fZEmB9p2.js.br +0 -0
- package/dist/public/assets/{_38lLOyV4.js → _68z4FCtL.js} +1 -1
- package/dist/public/assets/_68z4FCtL.js.br +0 -0
- package/dist/public/assets/{_57VaSNVh.js → _7ulm5F25.js} +1 -1
- package/dist/public/assets/_7ulm5F25.js.br +0 -0
- package/dist/public/assets/{_Nss91pW_2.js → _9ekMcw4E2.js} +1 -1
- package/dist/public/assets/_9ekMcw4E2.js.br +0 -0
- package/dist/public/assets/{_D3Hpj9Te.js → _B1NjOKqM.js} +1 -1
- package/dist/public/assets/_B1NjOKqM.js.br +0 -0
- package/dist/public/assets/{_C45W_Lp6.js → _B1dh4BjF.js} +1 -1
- package/dist/public/assets/_B1dh4BjF.js.br +0 -0
- package/dist/public/assets/{_CMnrd6fU.js → _B2TmPLZR.js} +1 -1
- package/dist/public/assets/_B2TmPLZR.js.br +0 -0
- package/dist/public/assets/{_BOmDUiov.js → _B2oJT0Iz.js} +1 -1
- package/dist/public/assets/_B2oJT0Iz.js.br +0 -0
- package/dist/public/assets/{_SlpmB-w5.js → _BCBCXuNF.js} +1 -1
- package/dist/public/assets/_BCBCXuNF.js.br +0 -0
- package/dist/public/assets/{_Bpy8lJQH.js → _BECiMBRI.js} +6 -6
- package/dist/public/assets/_BECiMBRI.js.br +0 -0
- package/dist/public/assets/{_CoA5CmM72.js → _BEE7mDcv2.js} +1 -1
- package/dist/public/assets/_BEE7mDcv2.js.br +0 -0
- package/dist/public/assets/{_UuRzi2Pg.js → _BHioPQAc.js} +1 -1
- package/dist/public/assets/_BHioPQAc.js.br +0 -0
- package/dist/public/assets/{_CqiVQVB42.js → _BLJqnkdL2.js} +1 -1
- package/dist/public/assets/_BLJqnkdL2.js.br +0 -0
- package/dist/public/assets/{_BAI6pIEH.js → _BRgSM65d.js} +1 -1
- package/dist/public/assets/_BRgSM65d.js.br +0 -0
- package/dist/public/assets/{_Dse6xAP22.js → _BTbmN-k-2.js} +1 -1
- package/dist/public/assets/_BTbmN-k-2.js.br +0 -0
- package/dist/public/assets/{_CUBLnmSA.js → _BfpaQCZS.js} +1 -1
- package/dist/public/assets/_BfpaQCZS.js.br +0 -0
- package/dist/public/assets/{_Yk-TslqA.js → _BhXU-Nbg.js} +1 -1
- package/dist/public/assets/_BhXU-Nbg.js.br +0 -0
- package/dist/public/assets/{_C5N9J9W_.js → _BiVy2gzm.js} +1 -1
- package/dist/public/assets/_BiVy2gzm.js.br +0 -0
- package/dist/public/assets/{_BdlhFWPk.js → _BndzfRf5.js} +1 -1
- package/dist/public/assets/_BndzfRf5.js.br +0 -0
- package/dist/public/assets/{_Ct4sne2O2.js → _Boj0LPAV2.js} +1 -1
- package/dist/public/assets/{_D2zeYViB.js → _BrWQpYKG.js} +1 -1
- package/dist/public/assets/_BrWQpYKG.js.br +0 -0
- package/dist/public/assets/{_9k941mBT2.js → _BrtXr1ji2.js} +1 -1
- package/dist/public/assets/_BrtXr1ji2.js.br +0 -0
- package/dist/public/assets/{_ghOVZPKq.js → _BuS3Vglx.js} +1 -1
- package/dist/public/assets/_BuS3Vglx.js.br +0 -0
- package/dist/public/assets/{_CZZwvo0u.js → _BxpVjKkc.js} +1 -1
- package/dist/public/assets/_BxpVjKkc.js.br +0 -0
- package/dist/public/assets/{_Ci6_nT4t2.js → _C001rM4U2.js} +1 -1
- package/dist/public/assets/_C001rM4U2.js.br +0 -0
- package/dist/public/assets/{_DFT7BTpC.js → _C0ZA5CMc.js} +1 -1
- package/dist/public/assets/_C0ZA5CMc.js.br +0 -0
- package/dist/public/assets/{_cBrUsk6q.js → _C1QAOE9L.js} +1 -1
- package/dist/public/assets/_C1QAOE9L.js.br +0 -0
- package/dist/public/assets/{_DWACLLAl.js → _C6MDqF6r.js} +5 -5
- package/dist/public/assets/_C6MDqF6r.js.br +0 -0
- package/dist/public/assets/{_C9FxJoow.js → _C6ws5wwF.js} +1 -1
- package/dist/public/assets/_C6ws5wwF.js.br +0 -0
- package/dist/public/assets/{_q9s2TQk5.js → _CAKHEQZH.js} +1 -1
- package/dist/public/assets/_CAKHEQZH.js.br +0 -0
- package/dist/public/assets/{_lhQ_uGs7.js → _CCPtn0et.js} +1 -1
- package/dist/public/assets/_CCPtn0et.js.br +0 -0
- package/dist/public/assets/{_CunZWZvv.js → _CEodf7tu.js} +1 -1
- package/dist/public/assets/_CEodf7tu.js.br +0 -0
- package/dist/public/assets/{_CPpT_bAp2.js → _CHEDeh4O2.js} +1 -1
- package/dist/public/assets/_CHEDeh4O2.js.br +0 -0
- package/dist/public/assets/{_B9J_gfIE.js → _CKHv8GUc.js} +1 -1
- package/dist/public/assets/_CKHv8GUc.js.br +0 -0
- package/dist/public/assets/{_DaN82C7i.js → _COhqAPLE.js} +1 -1
- package/dist/public/assets/_COhqAPLE.js.br +0 -0
- package/dist/public/assets/{_DlIwuzEd.js → _CauzJ22b.js} +1 -1
- package/dist/public/assets/_CauzJ22b.js.br +0 -0
- package/dist/public/assets/{_DR6v6KT22.js → _Cm1ANqbQ2.js} +1 -1
- package/dist/public/assets/_Cm1ANqbQ2.js.br +0 -0
- package/dist/public/assets/{_DQdzo5vx.js → _CsQiYtel.js} +1 -1
- package/dist/public/assets/_CsQiYtel.js.br +0 -0
- package/dist/public/assets/{_DU8uUGV12.js → _Cv7lWjV32.js} +1 -1
- package/dist/public/assets/_Cv7lWjV32.js.br +0 -0
- package/dist/public/assets/{_BhUQVKu8.js → _CvIyYSuF.js} +1 -1
- package/dist/public/assets/_CvIyYSuF.js.br +0 -0
- package/dist/public/assets/{_BsFBQnPe.js → _CwaR4-O6.js} +1 -1
- package/dist/public/assets/_CwaR4-O6.js.br +0 -0
- package/dist/public/assets/{_DubxV47f2.js → _CxxWbLuC2.js} +1 -1
- package/dist/public/assets/_CxxWbLuC2.js.br +0 -0
- package/dist/public/assets/{_mzG-3m6a.js → _CzbSiMaL.js} +1 -1
- package/dist/public/assets/_CzbSiMaL.js.br +0 -0
- package/dist/public/assets/{_sMtpt30w2.js → _Czvgy_oc2.js} +1 -1
- package/dist/public/assets/_Czvgy_oc2.js.br +0 -0
- package/dist/public/assets/{_BwsOUnJq2.js → _D3_3zitd2.js} +1 -1
- package/dist/public/assets/_D3_3zitd2.js.br +0 -0
- package/dist/public/assets/{_BXT4rVWU.js → _D7CWWH5a.js} +1 -1
- package/dist/public/assets/_D7CWWH5a.js.br +0 -0
- package/dist/public/assets/{_3M8rHd9q.js → _D9BL0gZh.js} +1 -1
- package/dist/public/assets/_D9BL0gZh.js.br +0 -0
- package/dist/public/assets/{_0Sd4iAaq.js → _DIEL2YtS.js} +1 -1
- package/dist/public/assets/_DIEL2YtS.js.br +0 -0
- package/dist/public/assets/{_B68ws5JM2.js → _DK5vdxh32.js} +1 -1
- package/dist/public/assets/_DK5vdxh32.js.br +0 -0
- package/dist/public/assets/{_BWm6t6g5.js → _DXVzDS8p.js} +1 -1
- package/dist/public/assets/_DXVzDS8p.js.br +0 -0
- package/dist/public/assets/{_NrBF2lTC.js → _DXsjW21V.js} +1 -1
- package/dist/public/assets/_DXsjW21V.js.br +0 -0
- package/dist/public/assets/{_d-TodGvp2.js → _Dbh4cPK_2.js} +1 -1
- package/dist/public/assets/_Dbh4cPK_2.js.br +0 -0
- package/dist/public/assets/{_C_bD7OU6.js → _DjkUqeYn.js} +1 -1
- package/dist/public/assets/_DjkUqeYn.js.br +0 -0
- package/dist/public/assets/{_BV1EiprI2.js → _DlikdYjR2.js} +1 -1
- package/dist/public/assets/_DlikdYjR2.js.br +0 -0
- package/dist/public/assets/{_CUmRJQ35.js → _DotQ9eyD.js} +1 -1
- package/dist/public/assets/_DotQ9eyD.js.br +0 -0
- package/dist/public/assets/{_CisgNUxd.js → _Dsh7sPtX.js} +1 -1
- package/dist/public/assets/_Dsh7sPtX.js.br +0 -0
- package/dist/public/assets/{_Ds61v8vi.js → _DszGB6Nm.js} +1 -1
- package/dist/public/assets/_DszGB6Nm.js.br +0 -0
- package/dist/public/assets/{_BCzjrlAy.js → _DtjFcpep.js} +1 -1
- package/dist/public/assets/_DtjFcpep.js.br +0 -0
- package/dist/public/assets/{_BOP03gps.js → _DwLDpDkb.js} +1 -1
- package/dist/public/assets/_DwLDpDkb.js.br +0 -0
- package/dist/public/assets/{_CIn4drK7.js → _DwnnREUT.js} +1 -1
- package/dist/public/assets/_DwnnREUT.js.br +0 -0
- package/dist/public/assets/{_DBUO8PvB.js → _DzvR3HtZ.js} +1 -1
- package/dist/public/assets/_DzvR3HtZ.js.br +0 -0
- package/dist/public/assets/{_DupM9eEV.js → _FFoEJg8c.js} +1 -1
- package/dist/public/assets/{_m0jpMRnx.js → _KlGqeoIr.js} +1 -1
- package/dist/public/assets/_KlGqeoIr.js.br +0 -0
- package/dist/public/assets/{_Cj36gP3r.js → _WknOXr2p.js} +1 -1
- package/dist/public/assets/_WknOXr2p.js.br +0 -0
- package/dist/public/assets/{_CjUGol_X.js → _XBtiwca3.js} +1 -1
- package/dist/public/assets/_XBtiwca3.js.br +0 -0
- package/dist/public/assets/{_DXSlYsr0.js → _b7W0qIUu.js} +1 -1
- package/dist/public/assets/_b7W0qIUu.js.br +0 -0
- package/dist/public/assets/{_C7yOUMH5.js → _hoypU4ON.js} +1 -1
- package/dist/public/assets/_hoypU4ON.js.br +0 -0
- package/dist/public/assets/{_nq_IIC6O2.js → _jJgk9rI72.js} +1 -1
- package/dist/public/assets/{_B8CJtOsm2.js → _jzzAY-_W2.js} +1 -1
- package/dist/public/assets/_jzzAY-_W2.js.br +0 -0
- package/dist/public/assets/{_Bjw4rVxX.js → _l8ryHBkA.js} +1 -1
- package/dist/public/assets/_l8ryHBkA.js.br +0 -0
- package/dist/public/assets/{_BR7X2c7n2.js → _q-MpIvSC2.js} +1 -1
- package/dist/public/assets/_q-MpIvSC2.js.br +0 -0
- package/dist/public/assets/{_DQqrsLS52.js → _tEOeZ26b2.js} +1 -1
- package/dist/public/assets/_tEOeZ26b2.js.br +0 -0
- package/dist/public/assets/{_BzyjsnUO2.js → _u8bPqpkk2.js} +1 -1
- package/dist/public/assets/_u8bPqpkk2.js.br +0 -0
- package/dist/public/assets/{_2XPzfLYp2.js → _x71nmEt92.js} +1 -1
- package/dist/public/assets/_x71nmEt92.js.br +0 -0
- package/dist/public/assets/{_CJZ6lGU-2.js → _zUM5lYgT2.js} +1 -1
- package/dist/public/assets/_zUM5lYgT2.js.br +0 -0
- package/dist/public/assets/{_KOmqCPbm.js → _zoKtmmeV.js} +1 -1
- package/dist/public/assets/_zoKtmmeV.js.br +0 -0
- package/dist/public/assets/{app-page-CMazjI1P.css → app-page-DL7rHeQL.css} +1 -1
- package/dist/public/assets/app-page-DL7rHeQL.css.br +0 -0
- package/dist/public/assets/{diff-view-BhaHll01.css → diff-view-CQTNRT5q.css} +1 -1
- package/dist/public/assets/diff-view-CQTNRT5q.css.br +0 -0
- package/dist/public/assets/new-KOmGuG9T.js +1 -0
- package/dist/public/assets/settings-KOmGuG9T.js +1 -0
- package/dist/public/assets/w-KOmGuG9T.js +1 -0
- package/dist/public/assets/w._-CQegKUC3.js +1 -0
- package/dist/public/assets/w._-KOmGuG9T.js +1 -0
- package/package.json +1 -1
- package/dist/_B-QvNFcB.js +0 -2
- package/dist/_BTtOB0g5.js +0 -2
- package/dist/_CmQFz3S6.js +0 -2
- package/dist/public/assets/_0Sd4iAaq.js.br +0 -0
- package/dist/public/assets/_2XPzfLYp2.js.br +0 -0
- package/dist/public/assets/_38lLOyV4.js.br +0 -0
- package/dist/public/assets/_3M8rHd9q.js.br +0 -0
- package/dist/public/assets/_57VaSNVh.js.br +0 -0
- package/dist/public/assets/_9k941mBT2.js.br +0 -0
- package/dist/public/assets/_B68ws5JM2.js.br +0 -0
- package/dist/public/assets/_B8CJtOsm2.js.br +0 -0
- package/dist/public/assets/_B9J_gfIE.js.br +0 -0
- package/dist/public/assets/_BAI6pIEH.js.br +0 -0
- package/dist/public/assets/_BCzjrlAy.js.br +0 -0
- package/dist/public/assets/_BOP03gps.js.br +0 -0
- package/dist/public/assets/_BOmDUiov.js.br +0 -0
- package/dist/public/assets/_BR7X2c7n2.js.br +0 -0
- package/dist/public/assets/_BV1EiprI2.js.br +0 -0
- package/dist/public/assets/_BWm6t6g5.js.br +0 -0
- package/dist/public/assets/_BXT4rVWU.js.br +0 -0
- package/dist/public/assets/_BdlhFWPk.js.br +0 -0
- package/dist/public/assets/_BhUQVKu8.js.br +0 -0
- package/dist/public/assets/_Bjw4rVxX.js.br +0 -0
- package/dist/public/assets/_Bpy8lJQH.js.br +0 -0
- package/dist/public/assets/_BsFBQnPe.js.br +0 -0
- package/dist/public/assets/_BwsOUnJq2.js.br +0 -0
- package/dist/public/assets/_BzyjsnUO2.js.br +0 -0
- package/dist/public/assets/_C0TsHYWM2.js.br +0 -0
- package/dist/public/assets/_C45W_Lp6.js.br +0 -0
- package/dist/public/assets/_C5N9J9W_.js.br +0 -0
- package/dist/public/assets/_C7yOUMH5.js.br +0 -0
- package/dist/public/assets/_C9FxJoow.js.br +0 -0
- package/dist/public/assets/_CIn4drK7.js.br +0 -0
- package/dist/public/assets/_CJZ6lGU-2.js.br +0 -0
- package/dist/public/assets/_CMnrd6fU.js.br +0 -0
- package/dist/public/assets/_CPpT_bAp2.js.br +0 -0
- package/dist/public/assets/_CUBLnmSA.js.br +0 -0
- package/dist/public/assets/_CUmRJQ35.js.br +0 -0
- package/dist/public/assets/_CZZwvo0u.js.br +0 -0
- package/dist/public/assets/_C_bD7OU6.js.br +0 -0
- package/dist/public/assets/_Ci6_nT4t2.js.br +0 -0
- package/dist/public/assets/_CisgNUxd.js.br +0 -0
- package/dist/public/assets/_Cj36gP3r.js.br +0 -0
- package/dist/public/assets/_CjUGol_X.js.br +0 -0
- package/dist/public/assets/_CoA5CmM72.js.br +0 -0
- package/dist/public/assets/_CqiVQVB42.js.br +0 -0
- package/dist/public/assets/_CunZWZvv.js.br +0 -0
- package/dist/public/assets/_D2zeYViB.js.br +0 -0
- package/dist/public/assets/_D3Hpj9Te.js.br +0 -0
- package/dist/public/assets/_DBUO8PvB.js.br +0 -0
- package/dist/public/assets/_DFT7BTpC.js.br +0 -0
- package/dist/public/assets/_DQdzo5vx.js.br +0 -0
- package/dist/public/assets/_DQqrsLS52.js.br +0 -0
- package/dist/public/assets/_DR6v6KT22.js.br +0 -0
- package/dist/public/assets/_DU8uUGV12.js.br +0 -0
- package/dist/public/assets/_DWACLLAl.js.br +0 -0
- package/dist/public/assets/_DXSlYsr0.js.br +0 -0
- package/dist/public/assets/_DaN82C7i.js.br +0 -0
- package/dist/public/assets/_DlIwuzEd.js.br +0 -0
- package/dist/public/assets/_Ds61v8vi.js.br +0 -0
- package/dist/public/assets/_Dse6xAP22.js.br +0 -0
- package/dist/public/assets/_DubxV47f2.js.br +0 -0
- package/dist/public/assets/_KOmqCPbm.js.br +0 -0
- package/dist/public/assets/_NrBF2lTC.js.br +0 -0
- package/dist/public/assets/_Nss91pW_2.js.br +0 -0
- package/dist/public/assets/_SlpmB-w5.js.br +0 -0
- package/dist/public/assets/_UuRzi2Pg.js.br +0 -0
- package/dist/public/assets/_Yk-TslqA.js.br +0 -0
- package/dist/public/assets/_cBrUsk6q.js.br +0 -0
- package/dist/public/assets/_d-TodGvp2.js.br +0 -0
- package/dist/public/assets/_ghOVZPKq.js.br +0 -0
- package/dist/public/assets/_lhQ_uGs7.js.br +0 -0
- package/dist/public/assets/_m0jpMRnx.js.br +0 -0
- package/dist/public/assets/_mzG-3m6a.js.br +0 -0
- package/dist/public/assets/_q9s2TQk5.js.br +0 -0
- package/dist/public/assets/_sMtpt30w2.js.br +0 -0
- package/dist/public/assets/app-page-CMazjI1P.css.br +0 -0
- package/dist/public/assets/diff-view-BhaHll01.css.br +0 -0
- package/dist/public/assets/new-DUxUh5q7.js +0 -1
- package/dist/public/assets/settings-DUxUh5q7.js +0 -1
- package/dist/public/assets/w-DUxUh5q7.js +0 -1
- package/dist/public/assets/w._-BpgzbM86.js +0 -1
- package/dist/public/assets/w._-DUxUh5q7.js +0 -1
|
@@ -39,11 +39,15 @@ fs.mkdirSync(config.dataDir, { recursive: true });
|
|
|
39
39
|
* user's default tmux. */
|
|
40
40
|
var TMUX_SOCKET = "work";
|
|
41
41
|
var execFileAsync = promisify(execFile);
|
|
42
|
-
async function run$1(cmd, args, cwd, env) {
|
|
42
|
+
async function run$1(cmd, args, cwd, env, opts = {}) {
|
|
43
43
|
const { stdout } = await execFileAsync(cmd, args, {
|
|
44
44
|
cwd,
|
|
45
45
|
env,
|
|
46
|
-
maxBuffer: 67108864
|
|
46
|
+
maxBuffer: 67108864,
|
|
47
|
+
...opts.timeoutMs && {
|
|
48
|
+
timeout: opts.timeoutMs,
|
|
49
|
+
killSignal: "SIGKILL"
|
|
50
|
+
}
|
|
47
51
|
});
|
|
48
52
|
return stdout.trim();
|
|
49
53
|
}
|
|
@@ -6569,7 +6573,7 @@ function publishChange(sessionId) {
|
|
|
6569
6573
|
const row = get("SELECT workspace_id FROM sessions WHERE id = ?", sessionId);
|
|
6570
6574
|
if (row?.workspace_id) {
|
|
6571
6575
|
const workspaceId = row.workspace_id;
|
|
6572
|
-
import("./
|
|
6576
|
+
import("./_B3qThpAM.js").then((m) => m.notifySessionsChanged(workspaceId));
|
|
6573
6577
|
return;
|
|
6574
6578
|
}
|
|
6575
6579
|
publish("sessions.changed");
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { U as subscriberCount, V as publish, W as subscriberJoins, dt as all, ft as db, g as sessionStates, l as listSessions } from "./
|
|
2
|
-
import { A as portsByWorkspace, J as hostToken, K as forgetToken, M as headOid, Q as ownsBranch, R as repoParent, V as DEFAULT_HOST, Y as joinRepo, Z as splitRepo, h as listWorkspaces, o as pushFailureFor, q as graphqlUrl, z as swr } from "./
|
|
1
|
+
import { U as subscriberCount, V as publish, W as subscriberJoins, dt as all, ft as db, g as sessionStates, l as listSessions } from "./_BJg54Xa1.js";
|
|
2
|
+
import { A as portsByWorkspace, J as hostToken, K as forgetToken, M as headOid, Q as ownsBranch, R as repoParent, V as DEFAULT_HOST, Y as joinRepo, Z as splitRepo, h as listWorkspaces, o as pushFailureFor, q as graphqlUrl, z as swr } from "./_DwK89Lz-.js";
|
|
3
3
|
import path from "node:path";
|
|
4
4
|
//#region src/server/github-api.ts
|
|
5
5
|
/** Run a GraphQL query against one host.
|
|
@@ -2173,8 +2173,8 @@ function theme() {
|
|
|
2173
2173
|
function setTheme(mode) {
|
|
2174
2174
|
set("theme", mode === "system" ? null : mode);
|
|
2175
2175
|
}
|
|
2176
|
-
var sectionCount = "
|
|
2177
|
-
var row = "
|
|
2176
|
+
var sectionCount = "_bq _H _I";
|
|
2177
|
+
var row = "_bB _bt";
|
|
2178
2178
|
var iconBtn = "_Z _j";
|
|
2179
2179
|
//#endregion
|
|
2180
2180
|
//#region src/tags/icons/icon-refresh.marko
|
|
@@ -2320,8 +2320,8 @@ var icon_sidebar_default = _template("kb", (input) => {
|
|
|
2320
2320
|
});
|
|
2321
2321
|
_serialize_if($scope0_reason, 0) && writeScope($scope0_id, { a: _existing_scope($childScope) });
|
|
2322
2322
|
});
|
|
2323
|
-
var findInput = "
|
|
2324
|
-
var findIconBtn = "
|
|
2323
|
+
var findInput = "_f8 _l";
|
|
2324
|
+
var findIconBtn = "_ga _j";
|
|
2325
2325
|
//#endregion
|
|
2326
2326
|
//#region src/tags/icons/icon-arrow-down.marko
|
|
2327
2327
|
var icon_arrow_down_default = _template("J", (input) => {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { $ as setSetting, V as publish, Y as getSetting, _t as git, bt as config, c as killWorkspaceSessions, dt as all, ft as db, gt as gh, i as disposeSessions, l as listSessions, nt as ghKnownHosts, ot as DEFAULT_GITHUB_HOST, p as panePids, pt as get, vt as run } from "./
|
|
1
|
+
import { $ as setSetting, V as publish, Y as getSetting, _t as git, bt as config, c as killWorkspaceSessions, dt as all, ft as db, gt as gh, i as disposeSessions, l as listSessions, nt as ghKnownHosts, ot as DEFAULT_GITHUB_HOST, p as panePids, pt as get, vt as run } from "./_BJg54Xa1.js";
|
|
2
2
|
import fs from "node:fs";
|
|
3
3
|
import path from "node:path";
|
|
4
4
|
import { AsyncLocalStorage } from "node:async_hooks";
|
|
@@ -598,6 +598,38 @@ var isDir = (file) => fs$1.stat(file).then((s) => s.isDirectory(), () => false);
|
|
|
598
598
|
//#endregion
|
|
599
599
|
//#region src/server/procs.ts
|
|
600
600
|
var darwin = process.platform === "darwin";
|
|
601
|
+
/** Upper bound on one process probe. lsof normally answers in well under a
|
|
602
|
+
* second; past this it is wedged behind something (endpoint-security
|
|
603
|
+
* vetting every stat, a hung mount) and the answer is worth less than the
|
|
604
|
+
* CPU it would keep burning. */
|
|
605
|
+
var PROBE_TIMEOUT_MS = 2e4;
|
|
606
|
+
var probe = (cmd, args) => run(cmd, args, void 0, void 0, { timeoutMs: PROBE_TIMEOUT_MS });
|
|
607
|
+
/** One sweep at a time, and a short reuse window. Every status compute
|
|
608
|
+
* wants the port table, and status is recomputed on every invalidation
|
|
609
|
+
* (PR refresh, push hook, client `?fresh`) — without this each of those
|
|
610
|
+
* spawned its own lsof pair while the previous ones were still running,
|
|
611
|
+
* and on a slow machine the sweeps piled up faster than they finished.
|
|
612
|
+
* Ports do not change in the time between two computes worth telling
|
|
613
|
+
* apart, so joining the in-flight sweep or reusing a seconds-old result
|
|
614
|
+
* is the right answer, not another process. */
|
|
615
|
+
function shared(fn, ttlMs) {
|
|
616
|
+
let inflight = null;
|
|
617
|
+
let last = null;
|
|
618
|
+
return () => {
|
|
619
|
+
if (last && Date.now() - last.at < ttlMs) return Promise.resolve(last.value);
|
|
620
|
+
if (!inflight) inflight = fn().then((value) => {
|
|
621
|
+
last = {
|
|
622
|
+
at: Date.now(),
|
|
623
|
+
value
|
|
624
|
+
};
|
|
625
|
+
return value;
|
|
626
|
+
}).finally(() => {
|
|
627
|
+
inflight = null;
|
|
628
|
+
});
|
|
629
|
+
return inflight;
|
|
630
|
+
};
|
|
631
|
+
}
|
|
632
|
+
var SWEEP_TTL_MS = 5e3;
|
|
601
633
|
/** Is `cwd` the workspace root or somewhere under it? The trailing slash is
|
|
602
634
|
* the whole point: a sibling `…/work-2` must not read as inside `…/work`. */
|
|
603
635
|
function inside(cwd, root) {
|
|
@@ -607,15 +639,8 @@ function inside(cwd, root) {
|
|
|
607
639
|
async function portsByWorkspace(paths) {
|
|
608
640
|
const result = /* @__PURE__ */ new Map();
|
|
609
641
|
const canonical = new Map([...paths].map(([wsId, p]) => [wsId, realPath(p)]));
|
|
610
|
-
const
|
|
611
|
-
|
|
612
|
-
const cwds = /* @__PURE__ */ new Map();
|
|
613
|
-
await Promise.all([...new Set(ports.map((p) => p.pid))].map(async (pid) => {
|
|
614
|
-
const cwd = await readCwd(pid);
|
|
615
|
-
if (cwd) cwds.set(pid, cwd);
|
|
616
|
-
}));
|
|
617
|
-
return [ports, cwds];
|
|
618
|
-
})();
|
|
642
|
+
const ports = await listeningPorts();
|
|
643
|
+
const cwds = await cwdsOf([...new Set(ports.map((p) => p.pid))]);
|
|
619
644
|
for (const info of ports) {
|
|
620
645
|
const cwd = cwds.get(info.pid);
|
|
621
646
|
if (!cwd) continue;
|
|
@@ -675,11 +700,12 @@ async function killWorkspaceProc(pid, wsPaths) {
|
|
|
675
700
|
}
|
|
676
701
|
/** Every listening TCP port with its owning pid/command: `ss` on Linux,
|
|
677
702
|
* `lsof` on macOS (no /proc, no ss there). */
|
|
678
|
-
|
|
703
|
+
var listeningPorts = shared(listeningPortsNow, SWEEP_TTL_MS);
|
|
704
|
+
async function listeningPortsNow() {
|
|
679
705
|
const seen = /* @__PURE__ */ new Set();
|
|
680
706
|
const ports = [];
|
|
681
707
|
if (darwin) {
|
|
682
|
-
const out = await
|
|
708
|
+
const out = await probe("/usr/sbin/lsof", [
|
|
683
709
|
"-nP",
|
|
684
710
|
"-iTCP",
|
|
685
711
|
"-sTCP:LISTEN",
|
|
@@ -701,7 +727,7 @@ async function listeningPorts() {
|
|
|
701
727
|
}
|
|
702
728
|
return ports;
|
|
703
729
|
}
|
|
704
|
-
const out = await
|
|
730
|
+
const out = await probe("ss", ["-tlnpH"]).catch(() => "");
|
|
705
731
|
for (const line of out.split("\n")) {
|
|
706
732
|
const port = Number(line.match(/:(\d+)\s/)?.[1]);
|
|
707
733
|
const pid = Number(line.match(/pid=(\d+)/)?.[1]);
|
|
@@ -717,10 +743,11 @@ async function listeningPorts() {
|
|
|
717
743
|
return ports;
|
|
718
744
|
}
|
|
719
745
|
/** Every process's cwd: /proc scan on Linux, one `lsof` sweep on macOS. */
|
|
720
|
-
|
|
746
|
+
var processCwds = shared(processCwdsNow, SWEEP_TTL_MS);
|
|
747
|
+
async function processCwdsNow() {
|
|
721
748
|
const cwds = /* @__PURE__ */ new Map();
|
|
722
749
|
if (darwin) {
|
|
723
|
-
const out = await
|
|
750
|
+
const out = await probe("/usr/sbin/lsof", [
|
|
724
751
|
"-a",
|
|
725
752
|
"-d",
|
|
726
753
|
"cwd",
|
|
@@ -741,7 +768,7 @@ async function processCwds() {
|
|
|
741
768
|
}
|
|
742
769
|
/** A process's argv (best-effort; empty when it died or is unreadable). */
|
|
743
770
|
async function procArgs(pid) {
|
|
744
|
-
if (darwin) return (await
|
|
771
|
+
if (darwin) return (await probe("ps", [
|
|
745
772
|
"-p",
|
|
746
773
|
String(pid),
|
|
747
774
|
"-o",
|
|
@@ -753,9 +780,34 @@ async function procArgs(pid) {
|
|
|
753
780
|
return [];
|
|
754
781
|
}
|
|
755
782
|
}
|
|
783
|
+
/** cwd of each given pid. macOS: one lsof over the pid list (a spawn per
|
|
784
|
+
* pid costs more past two or three); Linux: readlink each. */
|
|
785
|
+
async function cwdsOf(pids) {
|
|
786
|
+
const cwds = /* @__PURE__ */ new Map();
|
|
787
|
+
if (!pids.length) return cwds;
|
|
788
|
+
if (darwin) {
|
|
789
|
+
const out = await probe("/usr/sbin/lsof", [
|
|
790
|
+
"-a",
|
|
791
|
+
"-d",
|
|
792
|
+
"cwd",
|
|
793
|
+
"-p",
|
|
794
|
+
pids.join(","),
|
|
795
|
+
"-Fpn"
|
|
796
|
+
]).catch((err) => err?.stdout ?? "");
|
|
797
|
+
let pid = 0;
|
|
798
|
+
for (const line of out.split("\n")) if (line.startsWith("p")) pid = Number(line.slice(1));
|
|
799
|
+
else if (line.startsWith("n") && pid) cwds.set(pid, line.slice(1));
|
|
800
|
+
return cwds;
|
|
801
|
+
}
|
|
802
|
+
await Promise.all(pids.map(async (pid) => {
|
|
803
|
+
const cwd = await readCwd(pid);
|
|
804
|
+
if (cwd) cwds.set(pid, cwd);
|
|
805
|
+
}));
|
|
806
|
+
return cwds;
|
|
807
|
+
}
|
|
756
808
|
async function readCwd(pid) {
|
|
757
809
|
if (darwin) {
|
|
758
|
-
const line = (await
|
|
810
|
+
const line = (await probe("/usr/sbin/lsof", [
|
|
759
811
|
"-a",
|
|
760
812
|
"-d",
|
|
761
813
|
"cwd",
|
|
@@ -1005,7 +1057,7 @@ async function materializeWorkspace(id) {
|
|
|
1005
1057
|
repo.default_branch = defaultBranch;
|
|
1006
1058
|
db.prepare("UPDATE repos SET base_branch = ?, default_branch = ? WHERE workspace_id = ? AND full_name = ?").run(repo.base_branch, defaultBranch, id, repo.full_name);
|
|
1007
1059
|
}
|
|
1008
|
-
(await import("./
|
|
1060
|
+
(await import("./_B1bgL2tH.js")).muteAutoPush(repo.full_name, ws.branch);
|
|
1009
1061
|
await addWorkspaceWorktree(bare, path.join(ws.path, repo.worktree), ws.branch, repo.base_branch);
|
|
1010
1062
|
added.push(repo);
|
|
1011
1063
|
});
|
|
@@ -1640,7 +1692,7 @@ async function noteRemoteRef(fullName, branch, oid) {
|
|
|
1640
1692
|
if (await revParse(barePath(fullName), `refs/heads/${branch}`) !== oid) return;
|
|
1641
1693
|
rememberPushed(k, oid);
|
|
1642
1694
|
if (failures.delete(k)) {
|
|
1643
|
-
const { pokeStatusWatch } = await import("./
|
|
1695
|
+
const { pokeStatusWatch } = await import("./_BIxwPE98.js");
|
|
1644
1696
|
pokeStatusWatch();
|
|
1645
1697
|
}
|
|
1646
1698
|
}
|
|
@@ -1705,7 +1757,7 @@ async function pushOnce(fullName, branch, bases) {
|
|
|
1705
1757
|
}
|
|
1706
1758
|
async function fail(k, why) {
|
|
1707
1759
|
failures.set(k, why);
|
|
1708
|
-
const { pokeStatusWatch } = await import("./
|
|
1760
|
+
const { pokeStatusWatch } = await import("./_BIxwPE98.js");
|
|
1709
1761
|
pokeStatusWatch();
|
|
1710
1762
|
return why;
|
|
1711
1763
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { $ as _attr_style, At as _subscribe, Ct as _scope_reason, D as toast_default, Dt as _serialize_guard, Et as _sep, G as _attr_class, H as tone, I as iconBtnLg, J as _attr_input_value, K as _attr_details_or_dialog_open, L as iconBtnRow, O as icon_xmark_default, Ot as _serialize_if, Q as _attr_select_value, R as iconBtnXs, Rt as writeScope, St as _scope_id, Tt as _script, W as _attr, X as _attr_option_value, _ as diffScope, a as fuzzy, b as setDiffPos, bt as _resume, c as icon_arrow_up_default, ct as _el_resume, d as icon_refresh_default, dt as _existing_scope, g as diffPos, gt as _html, h as diffFilter, i as icon_sidebar_default, it as _content_resume, j as repoLabel, jt as _template, k as icon_base_default, kt as _set_serialize_reason, l as icon_chevron_right_default, lt as _escape, n as findIconBtn, ot as _el, pt as _for_of, r as findInput, s as icon_search_default, st as _el_read_error, t as icon_arrow_down_default, u as icon_back_default, v as diffTreeOpen, vt as _if, wt as _scope_with_id, x as setDiffScope, xt as _resume_branch, yt as _peek_scope_id } from "./
|
|
1
|
+
import { $ as _attr_style, At as _subscribe, Ct as _scope_reason, D as toast_default, Dt as _serialize_guard, Et as _sep, G as _attr_class, H as tone, I as iconBtnLg, J as _attr_input_value, K as _attr_details_or_dialog_open, L as iconBtnRow, O as icon_xmark_default, Ot as _serialize_if, Q as _attr_select_value, R as iconBtnXs, Rt as writeScope, St as _scope_id, Tt as _script, W as _attr, X as _attr_option_value, _ as diffScope, a as fuzzy, b as setDiffPos, bt as _resume, c as icon_arrow_up_default, ct as _el_resume, d as icon_refresh_default, dt as _existing_scope, g as diffPos, gt as _html, h as diffFilter, i as icon_sidebar_default, it as _content_resume, j as repoLabel, jt as _template, k as icon_base_default, kt as _set_serialize_reason, l as icon_chevron_right_default, lt as _escape, n as findIconBtn, ot as _el, pt as _for_of, r as findInput, s as icon_search_default, st as _el_read_error, t as icon_arrow_down_default, u as icon_back_default, v as diffTreeOpen, vt as _if, wt as _scope_with_id, x as setDiffScope, xt as _resume_branch, yt as _peek_scope_id } from "./_Boofe5nI.js";
|
|
2
2
|
//#region src/client/router.ts
|
|
3
3
|
function urlFor(r) {
|
|
4
4
|
if (r.view === "settings") return "/settings";
|
|
@@ -242,7 +242,7 @@ function treeDirs(files) {
|
|
|
242
242
|
};
|
|
243
243
|
return build(root, "", "", -1);
|
|
244
244
|
}
|
|
245
|
-
var treeToggle = "
|
|
245
|
+
var treeToggle = "_e0 _Z _j";
|
|
246
246
|
//#endregion
|
|
247
247
|
//#region src/tags/diff-send.marko
|
|
248
248
|
var diff_send_default = _template("j", (input) => {
|
|
@@ -252,7 +252,7 @@ var diff_send_default = _template("j", (input) => {
|
|
|
252
252
|
let sendTarget = null;
|
|
253
253
|
const sessions = input.sessions || [];
|
|
254
254
|
const sendPick = sessions.some((s) => s.id === sendTarget) ? sendTarget : sessions[0]?.id ?? null;
|
|
255
|
-
_html(`<span${_attr_class("
|
|
255
|
+
_html(`<span${_attr_class("_gi")}><button type=button${_attr_class("_o")} title="Copy comments as markdown">Copy${_el_resume($scope0_id, "c")}</button>${_el_resume($scope0_id, "b")}`);
|
|
256
256
|
_if(() => {
|
|
257
257
|
if (sessions.length === 1) {
|
|
258
258
|
const $scope1_id = _scope_id();
|
|
@@ -262,11 +262,11 @@ var diff_send_default = _template("j", (input) => {
|
|
|
262
262
|
return 0;
|
|
263
263
|
} else if (sessions.length) {
|
|
264
264
|
const $scope2_id = _scope_id();
|
|
265
|
-
_html(`<span${_attr_class("
|
|
265
|
+
_html(`<span${_attr_class("_gj")}><button type=button${_attr_class(["_p", "_gk"])}${_attr("disabled", sending)}>Send to${_el_resume($scope2_id, "c")}</button>${_el_resume($scope2_id, "b")}`);
|
|
266
266
|
_attr_select_value($scope2_id, "d", sendTarget, _resume((_new_sendTarget) => {
|
|
267
267
|
sendTarget = _new_sendTarget;
|
|
268
268
|
}, "j0", $scope2_id), () => {
|
|
269
|
-
_html(`<select${_attr_class("
|
|
269
|
+
_html(`<select${_attr_class("_gl")} aria-label="Send comments to session"${_attr("disabled", sending)}>`);
|
|
270
270
|
_for_of(sessions, (s) => {
|
|
271
271
|
const $scope3_id = _scope_id();
|
|
272
272
|
_html(`<option${_attr_option_value(s.id)}>${_escape(s.title || s.agent)}${_el_resume($scope3_id, "b", $sg__input_sessions)}</option>${_el_resume($scope3_id, "a", $sg__input_sessions)}`);
|
|
@@ -1848,9 +1848,9 @@ var diff_find_default = _template("i", (input) => {
|
|
|
1848
1848
|
el.select();
|
|
1849
1849
|
}, 0);
|
|
1850
1850
|
}, "i5", $scope0_id);
|
|
1851
|
-
_html(`<div${_attr_class(["
|
|
1851
|
+
_html(`<div${_attr_class(["_f7", !open && "_f6"])} aria-hidden=${open ? "false" : "true"}><input${_attr_input_value($scope0_id, "b", query || "", _resume(function(v) {
|
|
1852
1852
|
type(v);
|
|
1853
|
-
}, "i0", $scope0_id))}${_attr_class(findInput)} type=search enterkeyhint=search autocomplete=off tabindex=${open ? "0" : "-1"} placeholder="Find in review" aria-label="Find in review">${_el_resume($scope0_id, "b")}<span${_attr_class("
|
|
1853
|
+
}, "i0", $scope0_id))}${_attr_class(findInput)} type=search enterkeyhint=search autocomplete=off tabindex=${open ? "0" : "-1"} placeholder="Find in review" aria-label="Find in review">${_el_resume($scope0_id, "b")}<span${_attr_class("_f_")}>${open && (query || "").trim() ? hits.length ? `${_escape(`${at + 1}`)}/${_escape(`${hits.length}`)}` : "0/0" : ""}${_el_resume($scope0_id, "d")}</span><button type=button${_attr_class(findIconBtn)} title="Previous match"${_attr("disabled", !hits.length || !open)} tabindex=${open ? "0" : "-1"}>`);
|
|
1854
1854
|
icon_arrow_up_default({ size: 14 });
|
|
1855
1855
|
_html(`</button>${_el_resume($scope0_id, "e")}<button type=button${_attr_class(findIconBtn)} title="Next match"${_attr("disabled", !hits.length || !open)} tabindex=${open ? "0" : "-1"}>`);
|
|
1856
1856
|
icon_arrow_down_default({ size: 14 });
|
|
@@ -2026,7 +2026,7 @@ var diff_file_default = _template("h", (input) => {
|
|
|
2026
2026
|
_scope_reason();
|
|
2027
2027
|
const $scope0_id = _scope_id();
|
|
2028
2028
|
_el($scope0_id, "h0");
|
|
2029
|
-
_html(`<div${_attr_class(["
|
|
2029
|
+
_html(`<div${_attr_class(["_h1", input.class])}></div>${_el_resume($scope0_id, "a")}`);
|
|
2030
2030
|
_script($scope0_id, "h1");
|
|
2031
2031
|
writeScope($scope0_id, {
|
|
2032
2032
|
e: input.file,
|
|
@@ -2434,7 +2434,7 @@ var review_section_default = _template("w", (input) => {
|
|
|
2434
2434
|
});
|
|
2435
2435
|
_resume_branch($scope0_id);
|
|
2436
2436
|
});
|
|
2437
|
-
var fileFilter = "
|
|
2437
|
+
var fileFilter = "_h3 _l";
|
|
2438
2438
|
//#endregion
|
|
2439
2439
|
//#region src/tags/file-filter.marko
|
|
2440
2440
|
var file_filter_default = _template("n", (input) => {
|
|
@@ -2464,7 +2464,7 @@ var file_filter_default = _template("n", (input) => {
|
|
|
2464
2464
|
pending = v;
|
|
2465
2465
|
box.timer = setTimeout(flush, 150);
|
|
2466
2466
|
}, "n2", $scope0_id);
|
|
2467
|
-
_html(`<div${_attr_class("
|
|
2467
|
+
_html(`<div${_attr_class("_h2")}><input${_attr_input_value($scope0_id, "b", draft, _resume(function(v) {
|
|
2468
2468
|
type(v);
|
|
2469
2469
|
}, "n0", $scope0_id))}${_attr_class(fileFilter)} type=search placeholder="Filter files…" aria-label="Filter files">${_el_resume($scope0_id, "b")}</div>`);
|
|
2470
2470
|
_script($scope0_id, "n3");
|
|
@@ -2497,7 +2497,7 @@ var $content = (input) => {
|
|
|
2497
2497
|
_for_of(dir.dirs, (child) => {
|
|
2498
2498
|
const $scope1_id = _scope_id();
|
|
2499
2499
|
const shut = input.collapsed.has(input.collapsedKey(child.path));
|
|
2500
|
-
_html(`<div${_attr_class("
|
|
2500
|
+
_html(`<div${_attr_class("_gu")}><button type=button${_attr_class(["_gv", { ["_gm"]: shut }])}${_attr("title", child.path)}${_attr_style(`--depth:${child.depth}`)}><span${_attr_class("_gC")}>`);
|
|
2501
2501
|
_if(() => {
|
|
2502
2502
|
if (shut) {
|
|
2503
2503
|
const $scope4_id = _scope_id();
|
|
@@ -2511,7 +2511,7 @@ var $content = (input) => {
|
|
|
2511
2511
|
return 1;
|
|
2512
2512
|
}
|
|
2513
2513
|
}, $scope1_id, "c", $sg__input, $sg__input, $sg__input, "</span>", 1);
|
|
2514
|
-
_html(`<span${_attr_class("
|
|
2514
|
+
_html(`<span${_attr_class("_gw")}>${_escape(child.label)}${_el_resume($scope1_id, "e", $sg__input_dir)}/</span></button>${_el_resume($scope1_id, "b")}`);
|
|
2515
2515
|
_if(() => {
|
|
2516
2516
|
if (!shut) {
|
|
2517
2517
|
const $scope2_id = _scope_id();
|
|
@@ -2558,11 +2558,11 @@ var $content = (input) => {
|
|
|
2558
2558
|
}, "path", $scope0_id, "a", $sg__input, $sg__input_dir, $sg__input_dir, 0, 1);
|
|
2559
2559
|
_for_of(dir.files, ({ file, name }) => {
|
|
2560
2560
|
const $scope3_id = _scope_id();
|
|
2561
|
-
_html(`<a${_attr("href", input.hrefFor(file.key))}${_attr_class(["
|
|
2561
|
+
_html(`<a${_attr("href", input.hrefFor(file.key))}${_attr_class(["_gy", { ["_gx"]: input.collapsedFiles?.has(file.key) }])}${input.collapsedFiles?.has(file.key) ? _attr("title", `${file.path} (folded — click to open)`) : _attr("title", file.path)}${_attr_style(`--depth:${dir.depth + 1}`)}><span${_attr_class("_gD")}${_attr("data-status", file.status)}>${_escape(file.status)}${_el_resume($scope3_id, "c", $sg__input_dir)}</span>${_el_resume($scope3_id, "b", $sg__input_dir)}<span${_attr_class("_gz")}>${_escape(name)}${_el_resume($scope3_id, "e", $sg__input_dir)}</span>`);
|
|
2562
2562
|
_if(() => {
|
|
2563
2563
|
if (input.newKeys.has(file.key)) {
|
|
2564
2564
|
const $scope6_id = _scope_id();
|
|
2565
|
-
_html(`<span${_attr_class(["_y", "
|
|
2565
|
+
_html(`<span${_attr_class(["_y", "_gA"])} title="Changed since your last visit"></span>`);
|
|
2566
2566
|
_serialize_if($scope0_reason, 1) && writeScope($scope6_id, {});
|
|
2567
2567
|
return 0;
|
|
2568
2568
|
}
|
|
@@ -2570,7 +2570,7 @@ var $content = (input) => {
|
|
|
2570
2570
|
_if(() => {
|
|
2571
2571
|
if (input.commentKeys.has(file.key)) {
|
|
2572
2572
|
const $scope7_id = _scope_id();
|
|
2573
|
-
_html(`<span${_attr_class("
|
|
2573
|
+
_html(`<span${_attr_class("_gB")}>`);
|
|
2574
2574
|
icon_comment_default({ size: 12 });
|
|
2575
2575
|
_html("</span>");
|
|
2576
2576
|
_serialize_if($scope0_reason, 0) && writeScope($scope7_id, {});
|
|
@@ -2628,7 +2628,7 @@ var diff_tree_default = _template("l", (input) => {
|
|
|
2628
2628
|
scope: input.scope ?? null,
|
|
2629
2629
|
file: key
|
|
2630
2630
|
}), "l0", $scope0_id);
|
|
2631
|
-
_html(`<aside${_attr_class(["
|
|
2631
|
+
_html(`<aside${_attr_class(["_gn", { ["_gm"]: input.open === false }])}><div${_attr_class("_go")}>`);
|
|
2632
2632
|
_set_serialize_reason(2);
|
|
2633
2633
|
const $childScope = _peek_scope_id();
|
|
2634
2634
|
file_filter_default({
|
|
@@ -2637,18 +2637,18 @@ var diff_tree_default = _template("l", (input) => {
|
|
|
2637
2637
|
filter = _new_filter;
|
|
2638
2638
|
}, "l1", $scope0_id)
|
|
2639
2639
|
});
|
|
2640
|
-
_html(`</div><div${_attr_class("
|
|
2640
|
+
_html(`</div><div${_attr_class("_gp")}>`);
|
|
2641
2641
|
_if(() => {
|
|
2642
2642
|
if (!input.sections.length && filter) {
|
|
2643
2643
|
const $scope3_id = _scope_id();
|
|
2644
|
-
_html(`<p${_attr_class("
|
|
2644
|
+
_html(`<p${_attr_class("_gq")}>No files match.</p>`);
|
|
2645
2645
|
writeScope($scope3_id, {});
|
|
2646
2646
|
return 0;
|
|
2647
2647
|
}
|
|
2648
2648
|
}, $scope0_id, "e", 1, 1, 1, 0, 1);
|
|
2649
2649
|
_for_of(input.sections, (section) => {
|
|
2650
2650
|
const $scope1_id = _scope_id();
|
|
2651
|
-
_html(`<div${_attr_class("
|
|
2651
|
+
_html(`<div${_attr_class("_gr")}><button type=button${_attr_class(["_gs", { ["_gm"]: collapsedRepos.has(section.id) }])}><span${_attr_class("_gC")}>`);
|
|
2652
2652
|
_if(() => {
|
|
2653
2653
|
if (collapsedRepos.has(section.id)) {
|
|
2654
2654
|
const $scope4_id = _scope_id();
|
|
@@ -2662,12 +2662,12 @@ var diff_tree_default = _template("l", (input) => {
|
|
|
2662
2662
|
return 1;
|
|
2663
2663
|
}
|
|
2664
2664
|
}, $scope1_id, "c", 1, 1, 1, "</span>", 1);
|
|
2665
|
-
_html(`<span${_attr_class("
|
|
2665
|
+
_html(`<span${_attr_class("_gw")}>${_escape(section.label)}${_el_resume($scope1_id, "e", $sg__input_sections)}</span></button>${_el_resume($scope1_id, "b")}`);
|
|
2666
2666
|
_if(() => {
|
|
2667
2667
|
if (!collapsedRepos.has(section.id) || openedRepos.has(section.id)) {
|
|
2668
2668
|
const $scope2_id = _scope_id();
|
|
2669
2669
|
const root = treeDirs(section.files);
|
|
2670
|
-
_html(`<div${_attr_class("
|
|
2670
|
+
_html(`<div${_attr_class("_gt")}${_attr("hidden", collapsedRepos.has(section.id))}>`);
|
|
2671
2671
|
_set_serialize_reason(1);
|
|
2672
2672
|
const $childScope2 = _peek_scope_id();
|
|
2673
2673
|
diff_tree_dir_default({
|
|
@@ -2792,9 +2792,9 @@ var diff_file_sheet_default = _template("g", (input) => {
|
|
|
2792
2792
|
_if(() => {
|
|
2793
2793
|
if (open) {
|
|
2794
2794
|
const $scope1_id = _scope_id();
|
|
2795
|
-
_html(`<div${_attr_class("
|
|
2795
|
+
_html(`<div${_attr_class("_hd")}></div>${_el_resume($scope1_id, "a")}<div${_attr_class("_he")} role=dialog aria-label="Jump to file"><div${_attr_class("_hf")}><strong${_attr_class("_hc")}>Files</strong><span${_attr_class("_hg")}>${_escape(input.files.length)}${_el_resume($scope1_id, "f", $sg__input_files_length)}${_sep($sg__input_total__OR__input_files_length)}${input.files.length !== total ? ` / ${_escape(`${total}`)}` : ""}${_el_resume($scope1_id, "g", $sg__input_total__OR__input_files_length)}</span><button type=button${_attr_class([iconBtnLg, "_hb"])} title=Close aria-label=Close>`);
|
|
2796
2796
|
icon_xmark_default({ size: 16 });
|
|
2797
|
-
_html(`</button>${_el_resume($scope1_id, "h")}</div><div${_attr_class("
|
|
2797
|
+
_html(`</button>${_el_resume($scope1_id, "h")}</div><div${_attr_class("_ho")}>`);
|
|
2798
2798
|
_set_serialize_reason(2);
|
|
2799
2799
|
const $childScope = _peek_scope_id();
|
|
2800
2800
|
file_filter_default({
|
|
@@ -2803,28 +2803,28 @@ var diff_file_sheet_default = _template("g", (input) => {
|
|
|
2803
2803
|
filter = _new_filter;
|
|
2804
2804
|
}, "g1", $scope1_id)
|
|
2805
2805
|
});
|
|
2806
|
-
_html(`</div><div${_attr_class("
|
|
2806
|
+
_html(`</div><div${_attr_class("_hh")}>`);
|
|
2807
2807
|
_for_of(groups, (group) => {
|
|
2808
2808
|
const $scope2_id = _scope_id();
|
|
2809
|
-
_html(`<div${_attr_class("
|
|
2809
|
+
_html(`<div${_attr_class("_hi")}><div${_attr_class("_hj")}>${_escape(group.repo)}${_el_resume($scope2_id, "c", $sg__input_files)}</div>`);
|
|
2810
2810
|
_for_of(group.dirs, ({ dir, files }) => {
|
|
2811
2811
|
const $scope3_id = _scope_id();
|
|
2812
|
-
_html(`<div${_attr_class("
|
|
2812
|
+
_html(`<div${_attr_class("_hk")}>`);
|
|
2813
2813
|
_if(() => {
|
|
2814
2814
|
if (dir) {
|
|
2815
2815
|
const $scope5_id = _scope_id();
|
|
2816
|
-
_html(`<div${_attr_class("
|
|
2816
|
+
_html(`<div${_attr_class("_hm")}${_attr("title", dir)}><bdi>${_escape(dir)}${_el_resume($scope5_id, "b", $sg__input_files)}/</bdi></div>${_el_resume($scope5_id, "a", $sg__input_files)}`);
|
|
2817
2817
|
$si__input_files && writeScope($scope5_id, { _: _scope_with_id($scope3_id) });
|
|
2818
2818
|
return 0;
|
|
2819
2819
|
}
|
|
2820
2820
|
}, $scope3_id, "b", $sg__input_files, $sg__input_files, $sg__input_files, 0, 1);
|
|
2821
2821
|
_for_of(files, ({ file, name }) => {
|
|
2822
2822
|
const $scope4_id = _scope_id();
|
|
2823
|
-
_html(`<a${_attr("href", hrefFor(file.key))}${_attr_class(["
|
|
2823
|
+
_html(`<a${_attr("href", hrefFor(file.key))}${_attr_class(["_hl", "_w"])}><span${_attr_class("_hs")}${_attr("data-status", file.status)}>${_escape(file.status)}${_el_resume($scope4_id, "c", $sg__input_files)}</span>${_el_resume($scope4_id, "b", $sg__input_files)}<span${_attr_class("_hn")}><bdi>${_escape(name)}${_el_resume($scope4_id, "e", $sg__input_files)}</bdi></span>`);
|
|
2824
2824
|
_if(() => {
|
|
2825
2825
|
if (newKeys.has(file.key)) {
|
|
2826
2826
|
const $scope6_id = _scope_id();
|
|
2827
|
-
_html(`<span${_attr_class(["_y", "
|
|
2827
|
+
_html(`<span${_attr_class(["_y", "_hq"])} title="Changed since your last visit"></span>`);
|
|
2828
2828
|
_serialize_if($scope0_reason, 1) && writeScope($scope6_id, {});
|
|
2829
2829
|
return 0;
|
|
2830
2830
|
}
|
|
@@ -2834,7 +2834,7 @@ var diff_file_sheet_default = _template("g", (input) => {
|
|
|
2834
2834
|
const $scope7_id = _scope_id();
|
|
2835
2835
|
icon_comment_default({
|
|
2836
2836
|
size: 12,
|
|
2837
|
-
class: "
|
|
2837
|
+
class: "_hr"
|
|
2838
2838
|
});
|
|
2839
2839
|
_serialize_if($scope0_reason, 0) && writeScope($scope7_id, {});
|
|
2840
2840
|
return 0;
|
|
@@ -2859,7 +2859,7 @@ var diff_file_sheet_default = _template("g", (input) => {
|
|
|
2859
2859
|
_if(() => {
|
|
2860
2860
|
if (!input.files.length) {
|
|
2861
2861
|
const $scope8_id = _scope_id();
|
|
2862
|
-
_html(`<p${_attr_class("
|
|
2862
|
+
_html(`<p${_attr_class("_hp")}>No files match.</p>`);
|
|
2863
2863
|
$si__input_files_length && writeScope($scope8_id, {});
|
|
2864
2864
|
return 0;
|
|
2865
2865
|
}
|
|
@@ -3399,22 +3399,22 @@ var diff_view_default = _template("m", (input) => {
|
|
|
3399
3399
|
collapsedRepos = /* @__PURE__ */ new Set([...collapsedRepos, id]);
|
|
3400
3400
|
}
|
|
3401
3401
|
}, "m35", $scope0_id);
|
|
3402
|
-
_html(`<div${_attr_class("
|
|
3402
|
+
_html(`<div${_attr_class("_eX")}><div${_attr_class("_e2")}><div${_attr_class("_e3")}><div${_attr_class(["_fc", { ["_fb"]: !comments.length }])}>`);
|
|
3403
3403
|
_if(() => {
|
|
3404
3404
|
if (input.onExit) {
|
|
3405
3405
|
const $scope1_id = _scope_id();
|
|
3406
|
-
_html(`<a${_attr("href", `/w/${input.workspaceId}`)}${_attr_class([iconBtnRow, "
|
|
3406
|
+
_html(`<a${_attr("href", `/w/${input.workspaceId}`)}${_attr_class([iconBtnRow, "_e4"])} title="Back to terminal (Esc)">`);
|
|
3407
3407
|
icon_back_default({ size: 14 });
|
|
3408
3408
|
_html(`</a>${_el_resume($scope1_id, "a", _serialize_guard($scope0_reason, 1))}`);
|
|
3409
3409
|
_serialize_if($scope0_reason, 0) && writeScope($scope1_id, { _: _serialize_if($scope0_reason, 1) && _scope_with_id($scope0_id) });
|
|
3410
3410
|
return 0;
|
|
3411
3411
|
}
|
|
3412
3412
|
}, $scope0_id, "e", _serialize_guard($scope0_reason, 0), _serialize_guard($scope0_reason, 4), 1, 0, 1);
|
|
3413
|
-
_html(`<h1${_attr_class("
|
|
3413
|
+
_html(`<h1${_attr_class("_e7")}>Review</h1>`);
|
|
3414
3414
|
_if(() => {
|
|
3415
3415
|
if (comments.length) {
|
|
3416
3416
|
const $scope5_id = _scope_id();
|
|
3417
|
-
_html(`<span${_attr_class("
|
|
3417
|
+
_html(`<span${_attr_class("_e6")}>${_escape(comments.length)}${_el_resume($scope5_id, "b")} comment<!>${comments.length === 1 ? "" : "s"}${_el_resume($scope5_id, "c")}</span>`);
|
|
3418
3418
|
writeScope($scope5_id, {});
|
|
3419
3419
|
return 0;
|
|
3420
3420
|
}
|
|
@@ -3422,7 +3422,7 @@ var diff_view_default = _template("m", (input) => {
|
|
|
3422
3422
|
_if(() => {
|
|
3423
3423
|
if (comments.length) {
|
|
3424
3424
|
const $scope2_id = _scope_id();
|
|
3425
|
-
_html(`<span${_attr_class("
|
|
3425
|
+
_html(`<span${_attr_class("_e5")}>`);
|
|
3426
3426
|
_set_serialize_reason(_serialize_guard($scope0_reason, 5));
|
|
3427
3427
|
const $childScope = _peek_scope_id();
|
|
3428
3428
|
diff_send_default({
|
|
@@ -3435,14 +3435,14 @@ var diff_view_default = _template("m", (input) => {
|
|
|
3435
3435
|
return 0;
|
|
3436
3436
|
}
|
|
3437
3437
|
}, $scope0_id, "h", 1, 1, 1, 0, 1);
|
|
3438
|
-
_html(`</div>${_el_resume($scope0_id, "d")}<div${_attr_class("
|
|
3438
|
+
_html(`</div>${_el_resume($scope0_id, "d")}<div${_attr_class("_e1")}>`);
|
|
3439
3439
|
_if(() => {
|
|
3440
3440
|
if (hasFiles) {
|
|
3441
3441
|
const $scope12_id = _scope_id();
|
|
3442
3442
|
_html(`<button${_attr_class([
|
|
3443
3443
|
treeToggle,
|
|
3444
|
-
"
|
|
3445
|
-
{ ["
|
|
3444
|
+
"_eZ",
|
|
3445
|
+
{ ["_eY"]: treeOpen }
|
|
3446
3446
|
])} title=${treeOpen ? "\"Hide file tree\"" : "\"Show file tree\""}>`);
|
|
3447
3447
|
icon_sidebar_default({ size: 14 });
|
|
3448
3448
|
_html(`</button>${_el_resume($scope12_id, "a")}`);
|
|
@@ -3451,7 +3451,7 @@ var diff_view_default = _template("m", (input) => {
|
|
|
3451
3451
|
return 0;
|
|
3452
3452
|
}
|
|
3453
3453
|
}, $scope0_id, "j", 1, 1, 1, 0, 1);
|
|
3454
|
-
_html(`<button${_attr_class([iconBtnRow, "
|
|
3454
|
+
_html(`<button${_attr_class([iconBtnRow, "_eZ"])} title="Refresh diff"${_attr("disabled", loading)}>`);
|
|
3455
3455
|
_set_serialize_reason(1);
|
|
3456
3456
|
const $childScope2 = _peek_scope_id();
|
|
3457
3457
|
icon_refresh_default({
|
|
@@ -3462,19 +3462,19 @@ var diff_view_default = _template("m", (input) => {
|
|
|
3462
3462
|
_if(() => {
|
|
3463
3463
|
if (hasFiles) {
|
|
3464
3464
|
const $scope13_id = _scope_id();
|
|
3465
|
-
_html(`<button${_attr_class(["_o", "
|
|
3465
|
+
_html(`<button${_attr_class(["_o", "_fl"])} title="Jump to file">Files (<!>${_escape(shownFiles.length)}${_el_resume($scope13_id, "b")})</button>${_el_resume($scope13_id, "a")}`);
|
|
3466
3466
|
_script($scope13_id, "m55");
|
|
3467
3467
|
writeScope($scope13_id, {});
|
|
3468
3468
|
return 0;
|
|
3469
3469
|
}
|
|
3470
3470
|
}, $scope0_id, "m", 1, 1, 1, 0, 1);
|
|
3471
|
-
_html(`<span${_attr_class(["_m", "
|
|
3471
|
+
_html(`<span${_attr_class(["_m", "_fd"])}>`);
|
|
3472
3472
|
_attr_select_value($scope0_id, "o", scope, _resume(function(v) {
|
|
3473
3473
|
setScope(v);
|
|
3474
3474
|
}, "m0", $scope0_id), () => {
|
|
3475
|
-
_html(`<select${_attr_class(["_n", "
|
|
3475
|
+
_html(`<select${_attr_class(["_n", "_fe"])} aria-label="Review scope"${_attr("disabled", loading)}><option${_attr_option_value("committed")}>Committed</option><option${_attr_option_value("working")}>Working tree</option><option${_attr_option_value("dirty")}>Uncommitted</option></select>`);
|
|
3476
3476
|
});
|
|
3477
|
-
_html(`${_el_resume($scope0_id, "o")}</span><div${_attr_class(["
|
|
3477
|
+
_html(`${_el_resume($scope0_id, "o")}</span><div${_attr_class(["_e_", { ["_e9"]: !findOpen }])}>`);
|
|
3478
3478
|
_set_serialize_reason(2);
|
|
3479
3479
|
const $childScope3 = _peek_scope_id();
|
|
3480
3480
|
diff_find_default({
|
|
@@ -3495,8 +3495,8 @@ var diff_view_default = _template("m", (input) => {
|
|
|
3495
3495
|
const $scope14_id = _scope_id();
|
|
3496
3496
|
_html(`<button${_attr_class([
|
|
3497
3497
|
iconBtnRow,
|
|
3498
|
-
"
|
|
3499
|
-
"
|
|
3498
|
+
"_e8",
|
|
3499
|
+
"_eZ"
|
|
3500
3500
|
])} title="Find in review (⌘/Ctrl+F)" aria-label="Find in review"${_attr("hidden", findOpen)}>`);
|
|
3501
3501
|
icon_search_default({ size: 14 });
|
|
3502
3502
|
_html(`</button>${_el_resume($scope14_id, "a")}`);
|
|
@@ -3505,7 +3505,7 @@ var diff_view_default = _template("m", (input) => {
|
|
|
3505
3505
|
return 0;
|
|
3506
3506
|
}
|
|
3507
3507
|
}, $scope0_id, "r", 1, 1, 1, 0, 1);
|
|
3508
|
-
_html(`</div></div><div${_attr_class("
|
|
3508
|
+
_html(`</div></div><div${_attr_class("_fa")} data-diff-main>`);
|
|
3509
3509
|
_if(() => {
|
|
3510
3510
|
if (error) {
|
|
3511
3511
|
const $scope6_id = _scope_id();
|
|
@@ -3528,7 +3528,7 @@ var diff_view_default = _template("m", (input) => {
|
|
|
3528
3528
|
_if(() => {
|
|
3529
3529
|
if (!repos && loading) {
|
|
3530
3530
|
const $scope15_id = _scope_id();
|
|
3531
|
-
_html(`<div${_attr_class("
|
|
3531
|
+
_html(`<div${_attr_class("_fg")} aria-hidden=true><div${_attr_class(["_fh", "_fi"])}></div><div${_attr_class(["_fh", "_fj"])}></div><div${_attr_class(["_fh", "_fk"])}></div><div${_attr_class(["_fh", "_fj"])}></div><div${_attr_class(["_fh", "_fk"])}></div></div>`);
|
|
3532
3532
|
writeScope($scope15_id, {});
|
|
3533
3533
|
return 0;
|
|
3534
3534
|
}
|
|
@@ -3559,12 +3559,12 @@ var diff_view_default = _template("m", (input) => {
|
|
|
3559
3559
|
_if(() => {
|
|
3560
3560
|
if (repos && !allFiles.length) {
|
|
3561
3561
|
const $scope11_id = _scope_id();
|
|
3562
|
-
_html(`<p${_attr_class("
|
|
3562
|
+
_html(`<p${_attr_class("_bA")}>${repoList.some((r) => r.unborn) ? "No commits yet." : scope === "dirty" ? "Nothing uncommitted." : repoList.some((r) => r.pr) ? "No file changes on these PRs." : "No changes vs base."}${_el_resume($scope11_id, "b")}</p>`);
|
|
3563
3563
|
writeScope($scope11_id, {});
|
|
3564
3564
|
return 0;
|
|
3565
3565
|
} else if (repos && !shownFiles.length && !findState.hit) {
|
|
3566
3566
|
const $scope8_id = _scope_id();
|
|
3567
|
-
_html(`<p${_attr_class("
|
|
3567
|
+
_html(`<p${_attr_class("_bA")}>${findState.query.trim() ? "No matches in review." : onlyNew && !fileFilter ? "Nothing changed since your last visit." : `No files match "${_escape(`${fileFilter}`)}".`}${_el_resume($scope8_id, "b")}</p>`);
|
|
3568
3568
|
writeScope($scope8_id, {});
|
|
3569
3569
|
return 1;
|
|
3570
3570
|
}
|