nolzu 0.0.1 → 0.1.0
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/LICENSE +105 -0
- package/README.md +24 -7
- package/build/client/_app/immutable/assets/0.SPD4wYkc.css +1 -0
- package/build/client/_app/immutable/assets/1.BRilEoOO.css +1 -0
- package/build/client/_app/immutable/assets/10.DwLiBGDj.css +1 -0
- package/build/client/_app/immutable/assets/11.D_TtWT3D.css +1 -0
- package/build/client/_app/immutable/assets/12.CSVGmtUY.css +1 -0
- package/build/client/_app/immutable/assets/13.qTa7IHbg.css +1 -0
- package/build/client/_app/immutable/assets/19.CbCFXKb8.css +1 -0
- package/build/client/_app/immutable/assets/2.CfHhgI77.css +1 -0
- package/build/client/_app/immutable/assets/20.C5CSZhyT.css +1 -0
- package/build/client/_app/immutable/assets/21.BBpYkZcc.css +1 -0
- package/build/client/_app/immutable/assets/22.C9RgY9kl.css +1 -0
- package/build/client/_app/immutable/assets/23.B6Dp9RJO.css +1 -0
- package/build/client/_app/immutable/assets/24.C7g2abUW.css +1 -0
- package/build/client/_app/immutable/assets/26.DTMI6ROV.css +1 -0
- package/build/client/_app/immutable/assets/27.AxXMpDkB.css +1 -0
- package/build/client/_app/immutable/assets/28.939ac-98.css +1 -0
- package/build/client/_app/immutable/assets/3.3lqex1t-.css +1 -0
- package/build/client/_app/immutable/assets/4.C52MzO_d.css +1 -0
- package/build/client/_app/immutable/assets/5.CsfJAwvS.css +1 -0
- package/build/client/_app/immutable/assets/8.ByspUp-s.css +1 -0
- package/build/client/_app/immutable/assets/9.BCSFZmce.css +1 -0
- package/build/client/_app/immutable/assets/Banner.DDqfpWLD.css +1 -0
- package/build/client/_app/immutable/assets/BoardOff.mpX08-Be.css +1 -0
- package/build/client/_app/immutable/assets/Button.BlwsEgUc.css +1 -0
- package/build/client/_app/immutable/assets/Chip.qAAa6_e5.css +1 -0
- package/build/client/_app/immutable/assets/Dialog.D5Ln60a8.css +1 -0
- package/build/client/_app/immutable/assets/FeaturePanels.DZ_Mth5M.css +1 -0
- package/build/client/_app/immutable/assets/FolderBrowser.DBmRWDCH.css +1 -0
- package/build/client/_app/immutable/assets/Geist-Variable.Bj2R_7yk.woff2 +0 -0
- package/build/client/_app/immutable/assets/GeistMono-Variable.Dispecij.woff2 +0 -0
- package/build/client/_app/immutable/assets/HelpTip.DF6T9nns.css +1 -0
- package/build/client/_app/immutable/assets/InfoBox.CpavOykF.css +1 -0
- package/build/client/_app/immutable/assets/KeyCaps.D2t-lY-8.css +1 -0
- package/build/client/_app/immutable/assets/LogLine.Bu4feLn5.css +1 -0
- package/build/client/_app/immutable/assets/Markdown.DI6AtWAc.css +1 -0
- package/build/client/_app/immutable/assets/ModelPicker.DQzj7Nj8.css +1 -0
- package/build/client/_app/immutable/assets/OptionButtons.BYiyOXOE.css +1 -0
- package/build/client/_app/immutable/assets/PeekPanel.DzMdHoqg.css +1 -0
- package/build/client/_app/immutable/assets/ScoutPage.CVIiLy5c.css +1 -0
- package/build/client/_app/immutable/assets/SetupSteps.B6pZP1Bk.css +1 -0
- package/build/client/_app/immutable/assets/Skeleton.BC-1_U5d.css +1 -0
- package/build/client/_app/immutable/assets/SlotsMeter.Dq7GGYlD.css +1 -0
- package/build/client/_app/immutable/assets/StartConfirm.DxNN2AOb.css +1 -0
- package/build/client/_app/immutable/assets/StatePill.CGWFVUUg.css +1 -0
- package/build/client/_app/immutable/assets/Streamed.DpZ6wgO2.css +1 -0
- package/build/client/_app/immutable/assets/card-pulls.C5uGMuAh.css +1 -0
- package/build/client/_app/immutable/assets/next-step.CKg1w06J.css +1 -0
- package/build/client/_app/immutable/chunks/-B5EclhK.js +1 -0
- package/build/client/_app/immutable/chunks/-Q3zApAy.js +1 -0
- package/build/client/_app/immutable/chunks/6-hwN_Ik.js +3 -0
- package/build/client/_app/immutable/chunks/B16UF4PA.js +11 -0
- package/build/client/_app/immutable/chunks/B1V3h1VF.js +1 -0
- package/build/client/_app/immutable/chunks/B2d2Mkuz.js +68 -0
- package/build/client/_app/immutable/chunks/B2yzhiEa.js +1 -0
- package/build/client/_app/immutable/chunks/B5zDDQUU.js +2 -0
- package/build/client/_app/immutable/chunks/B8DHSiWf.js +1 -0
- package/build/client/_app/immutable/chunks/B8z33EzI.js +1 -0
- package/build/client/_app/immutable/chunks/BCRkrH6c.js +1 -0
- package/build/client/_app/immutable/chunks/BCScjOxu.js +1 -0
- package/build/client/_app/immutable/chunks/BMUQtCEC.js +1 -0
- package/build/client/_app/immutable/chunks/BNnfkvZM.js +1 -0
- package/build/client/_app/immutable/chunks/BelWyZaW.js +1 -0
- package/build/client/_app/immutable/chunks/BhZpqODT.js +1 -0
- package/build/client/_app/immutable/chunks/Bjy-W4x2.js +81 -0
- package/build/client/_app/immutable/chunks/BmafI-Bs.js +1 -0
- package/build/client/_app/immutable/chunks/BvRk9kiK.js +0 -0
- package/build/client/_app/immutable/chunks/C4i6bdQg.js +1 -0
- package/build/client/_app/immutable/chunks/C8u5TyIB.js +1 -0
- package/build/client/_app/immutable/chunks/CFs2xhoy.js +1 -0
- package/build/client/_app/immutable/chunks/CIm2DioU.js +1 -0
- package/build/client/_app/immutable/chunks/CONqGBXC.js +1 -0
- package/build/client/_app/immutable/chunks/CSOz40qO.js +1 -0
- package/build/client/_app/immutable/chunks/CXxuD1ef.js +3 -0
- package/build/client/_app/immutable/chunks/CarrGsZA.js +2 -0
- package/build/client/_app/immutable/chunks/CdrmTD44.js +1 -0
- package/build/client/_app/immutable/chunks/CfJRH9gh.js +2 -0
- package/build/client/_app/immutable/chunks/Ci7C9Cki.js +1 -0
- package/build/client/_app/immutable/chunks/CkOTL1vK.js +1 -0
- package/build/client/_app/immutable/chunks/CngTtGc_.js +1 -0
- package/build/client/_app/immutable/chunks/Cp3A1zR8.js +1 -0
- package/build/client/_app/immutable/chunks/CwtMnwNL.js +3 -0
- package/build/client/_app/immutable/chunks/Cy7f_oXg.js +1 -0
- package/build/client/_app/immutable/chunks/D-wwLm5t.js +1 -0
- package/build/client/_app/immutable/chunks/D2imbgaf.js +1 -0
- package/build/client/_app/immutable/chunks/D32mip60.js +1 -0
- package/build/client/_app/immutable/chunks/D46Vk19W.js +1 -0
- package/build/client/_app/immutable/chunks/DCUUgo-6.js +1 -0
- package/build/client/_app/immutable/chunks/DFjnjJjy.js +1 -0
- package/build/client/_app/immutable/chunks/DHMbSbMg.js +1 -0
- package/build/client/_app/immutable/chunks/DJOFx2wx.js +1 -0
- package/build/client/_app/immutable/chunks/DV4tvxHp.js +3 -0
- package/build/client/_app/immutable/chunks/DXk_5YEw.js +1 -0
- package/build/client/_app/immutable/chunks/DjgnRLJt.js +1 -0
- package/build/client/_app/immutable/chunks/DlWlQ_vP.js +1 -0
- package/build/client/_app/immutable/chunks/DpIAei2y.js +2 -0
- package/build/client/_app/immutable/chunks/Dt-HX3Vu.js +1 -0
- package/build/client/_app/immutable/chunks/DuSthUWX.js +1 -0
- package/build/client/_app/immutable/chunks/Ecfl8TOn.js +2 -0
- package/build/client/_app/immutable/chunks/ITHE99Aa.js +1 -0
- package/build/client/_app/immutable/chunks/Khdge0KS.js +1 -0
- package/build/client/_app/immutable/chunks/LMEKNlm0.js +1 -0
- package/build/client/_app/immutable/chunks/OnIeaiuO.js +1 -0
- package/build/client/_app/immutable/chunks/VFQLu55q.js +1 -0
- package/build/client/_app/immutable/chunks/ZsUxKnQw.js +1 -0
- package/build/client/_app/immutable/chunks/aWP8DVhV.js +1 -0
- package/build/client/_app/immutable/chunks/bB04Xp1f.js +1 -0
- package/build/client/_app/immutable/chunks/eylBqhv8.js +3 -0
- package/build/client/_app/immutable/chunks/hx0ssLL_.js +2 -0
- package/build/client/_app/immutable/chunks/mumDj17t.js +1 -0
- package/build/client/_app/immutable/chunks/pZYp3_TE.js +1 -0
- package/build/client/_app/immutable/chunks/tImwjqWn.js +1 -0
- package/build/client/_app/immutable/chunks/uBIymjUX.js +1 -0
- package/build/client/_app/immutable/chunks/xihTtKlq.js +1 -0
- package/build/client/_app/immutable/entry/app.DVZ1wE36.js +2 -0
- package/build/client/_app/immutable/entry/start.DluCc61B.js +1 -0
- package/build/client/_app/immutable/nodes/0.CwNFevXf.js +1 -0
- package/build/client/_app/immutable/nodes/1.BR6FYiC-.js +1 -0
- package/build/client/_app/immutable/nodes/10.wNwBFtom.js +2 -0
- package/build/client/_app/immutable/nodes/11.DpoIbMNF.js +2 -0
- package/build/client/_app/immutable/nodes/12.CWdUJ8l3.js +2 -0
- package/build/client/_app/immutable/nodes/13.CZ2uTvNS.js +1 -0
- package/build/client/_app/immutable/nodes/14.CzgyXuvL.js +1 -0
- package/build/client/_app/immutable/nodes/15.CzgyXuvL.js +1 -0
- package/build/client/_app/immutable/nodes/16.odL9eB2N.js +1 -0
- package/build/client/_app/immutable/nodes/17.B-RnUeVU.js +1 -0
- package/build/client/_app/immutable/nodes/18.BLYKxyq2.js +1 -0
- package/build/client/_app/immutable/nodes/19.CgyFfPqF.js +3 -0
- package/build/client/_app/immutable/nodes/2.CCWT41Qr.js +1 -0
- package/build/client/_app/immutable/nodes/20.BBk5-krg.js +1 -0
- package/build/client/_app/immutable/nodes/21.CJoU3s1A.js +2 -0
- package/build/client/_app/immutable/nodes/22.CoRvPh8m.js +1 -0
- package/build/client/_app/immutable/nodes/23.zXO3NjnM.js +3 -0
- package/build/client/_app/immutable/nodes/24.CmO27TED.js +1 -0
- package/build/client/_app/immutable/nodes/26.TVKNr_xX.js +18 -0
- package/build/client/_app/immutable/nodes/27.RojtGU_o.js +1 -0
- package/build/client/_app/immutable/nodes/28.CVTdeeSI.js +2 -0
- package/build/client/_app/immutable/nodes/3.Cgib7Vi6.js +1 -0
- package/build/client/_app/immutable/nodes/4.CnMwOCec.js +1 -0
- package/build/client/_app/immutable/nodes/5.-NqYtQj_.js +1 -0
- package/build/client/_app/immutable/nodes/6.D5xk-UBM.js +1 -0
- package/build/client/_app/immutable/nodes/7.IL4b-DII.js +1 -0
- package/build/client/_app/immutable/nodes/8.DJrguHjO.js +11 -0
- package/build/client/_app/immutable/nodes/9.DTUSzWiK.js +1 -0
- package/build/client/_app/version.json +1 -0
- package/build/client/favicon.svg +7 -0
- package/build/env.js +70 -0
- package/build/handler.js +26 -0
- package/build/index.js +149 -0
- package/build/server/chunks/chunks/Banner.js-D4mtxUfF.js +17 -0
- package/build/server/chunks/chunks/BoardOff.js-Dg5-LoR3.js +1627 -0
- package/build/server/chunks/chunks/Button.js-Buh9rnpu.js +43 -0
- package/build/server/chunks/chunks/Chip.js-xZ7vFkHx.js +12 -0
- package/build/server/chunks/chunks/Dialog.js-CGpwdpM-.js +60 -0
- package/build/server/chunks/chunks/FeaturePanels.js-B2sKozgF.js +84 -0
- package/build/server/chunks/chunks/FolderBrowser.js-DUHFhDaX.js +28 -0
- package/build/server/chunks/chunks/HelpTip.js-CzemvmjC.js +19 -0
- package/build/server/chunks/chunks/InfoBox.js-BJiVzZgw.js +10 -0
- package/build/server/chunks/chunks/KeyCaps.js-BMI2Hrh2.js +37 -0
- package/build/server/chunks/chunks/LogLine.js-2b7uX__H.js +35 -0
- package/build/server/chunks/chunks/Markdown.js-Clud88KU.js +4233 -0
- package/build/server/chunks/chunks/ModelPicker.js-FuBgyKIA.js +141 -0
- package/build/server/chunks/chunks/OptionButtons.js-LQKrAwUX.js +28 -0
- package/build/server/chunks/chunks/PeekPanel.js-aZ-r_v3N.js +375 -0
- package/build/server/chunks/chunks/ScoutPage.js-2DcNia96.js +733 -0
- package/build/server/chunks/chunks/SetupSteps.js-D7TAF7xa.js +66 -0
- package/build/server/chunks/chunks/Skeleton.js-diCP2sd5.js +30 -0
- package/build/server/chunks/chunks/SlotsMeter.js-BV_sAGf5.js +18 -0
- package/build/server/chunks/chunks/StartConfirm.js-CzEdFtbO.js +124 -0
- package/build/server/chunks/chunks/StatePill.js-CM7-HXNM.js +27 -0
- package/build/server/chunks/chunks/Streamed.js-_NgwNMMs.js +43 -0
- package/build/server/chunks/chunks/_page.server.js-BaGoctEY.js +1419 -0
- package/build/server/chunks/chunks/activity.js-CSoPUQLq.js +84 -0
- package/build/server/chunks/chunks/add-repo.js-DtHEobfm.js +305 -0
- package/build/server/chunks/chunks/app-header.js-CCflgeEQ.js +13 -0
- package/build/server/chunks/chunks/app.js-CuPn8jtk.js +12 -0
- package/build/server/chunks/chunks/bin.js-Cyb2cYLc.js +58 -0
- package/build/server/chunks/chunks/board-keys.js-CW3qw-MC.js +32 -0
- package/build/server/chunks/chunks/board-page.js-D0tdsE9J.js +860 -0
- package/build/server/chunks/chunks/board.js-BxL3CjB1.js +203 -0
- package/build/server/chunks/chunks/browser-test.js-DJEpOoVz.js +170 -0
- package/build/server/chunks/chunks/card-pulls.js-d_uGmBB3.js +229 -0
- package/build/server/chunks/chunks/card-repos.js-QaMCxiyV.js +59 -0
- package/build/server/chunks/chunks/chain-store.js-D42m8DUo.js +91 -0
- package/build/server/chunks/chunks/chain.js-CJFRywIC.js +52 -0
- package/build/server/chunks/chunks/changes.js-D8ITRMgU.js +513 -0
- package/build/server/chunks/chunks/checkout.js-Ys5L_gA4.js +319 -0
- package/build/server/chunks/chunks/client.js-B7jIMDuS.js +68 -0
- package/build/server/chunks/chunks/clipboard.js-qXskOBim.js +12 -0
- package/build/server/chunks/chunks/cloud-status.js-hy-9zUVX.js +95 -0
- package/build/server/chunks/chunks/coach.js-BhNB14rV.js +296 -0
- package/build/server/chunks/chunks/comments.js-1nWJQptB.js +311 -0
- package/build/server/chunks/chunks/commit-message.js-CMcNZUZw.js +8 -0
- package/build/server/chunks/chunks/create-card.js-DKtprMG6.js +498 -0
- package/build/server/chunks/chunks/db.js-pqoVpAzG.js +80 -0
- package/build/server/chunks/chunks/diff-comments.js-BSCuay_U.js +95 -0
- package/build/server/chunks/chunks/discussion.js-rJ5OMfvX.js +355 -0
- package/build/server/chunks/chunks/display.js-Bf-vGQ7Q.js +61 -0
- package/build/server/chunks/chunks/elapsed.js-DikkNhaD.js +27 -0
- package/build/server/chunks/chunks/engine.js-DS5zUwsE.js +115 -0
- package/build/server/chunks/chunks/env.js-l0sNRNKZ.js +2 -0
- package/build/server/chunks/chunks/estimate.js-BHTYVTaQ.js +2484 -0
- package/build/server/chunks/chunks/evidence-timeline.js-Dk0dTZIy.js +253 -0
- package/build/server/chunks/chunks/evidence.js-CT3tWdbB.js +257 -0
- package/build/server/chunks/chunks/exports.js-Hn-WQRMB.js +150 -0
- package/build/server/chunks/chunks/features.svelte.js-DNsFmFZb.js +10 -0
- package/build/server/chunks/chunks/files.js-V46lE0-6.js +46 -0
- package/build/server/chunks/chunks/filter.js-CsmCtJMd.js +11 -0
- package/build/server/chunks/chunks/forms.js-03E8qnFz.js +35 -0
- package/build/server/chunks/chunks/gate.js-Cbqo8Yy0.js +82 -0
- package/build/server/chunks/chunks/getting-started.js-DKbHofN5.js +55 -0
- package/build/server/chunks/chunks/git.js-l43vBHqs.js +16 -0
- package/build/server/chunks/chunks/home-path.js-BXgrl3TP.js +11 -0
- package/build/server/chunks/chunks/hub-link.js-B5kjLyyd.js +1532 -0
- package/build/server/chunks/chunks/internal.js-DaSBO6jY.js +1239 -0
- package/build/server/chunks/chunks/internal2.js-D6AKyUgY.js +27 -0
- package/build/server/chunks/chunks/knowledge-page.js-D2ALB3v9.js +292 -0
- package/build/server/chunks/chunks/knowledge-revert.js-2eyN9Lcb.js +109 -0
- package/build/server/chunks/chunks/knowledge.js--eAgdzNx.js +394 -0
- package/build/server/chunks/chunks/last-board.js-BemeiK3t.js +23 -0
- package/build/server/chunks/chunks/log.js-R2zUph6T.js +228 -0
- package/build/server/chunks/chunks/loop.js-D3guWKLp.js +4038 -0
- package/build/server/chunks/chunks/loop2.js-B_Qd2m4y.js +67 -0
- package/build/server/chunks/chunks/navigation.js-DQJMz-SM.js +2 -0
- package/build/server/chunks/chunks/new-project.js-DNcr9JpB.js +305 -0
- package/build/server/chunks/chunks/next-step.js-B8Kl0Iv9.js +522 -0
- package/build/server/chunks/chunks/node.js-Bz2jT5wt.js +3381 -0
- package/build/server/chunks/chunks/now-live.svelte.js-hIaDgjJ3.js +13 -0
- package/build/server/chunks/chunks/now-snapshot.js-zGKLIzox.js +207 -0
- package/build/server/chunks/chunks/now.js-Dfm-o0Ha.js +765 -0
- package/build/server/chunks/chunks/onboard.js-LBqPOxyU.js +1525 -0
- package/build/server/chunks/chunks/ordinal.js-Bm_9QEBD.js +12 -0
- package/build/server/chunks/chunks/overview.js-C32iHkXD.js +1108 -0
- package/build/server/chunks/chunks/page-keys.svelte.js-D8vXA_8Z.js +14 -0
- package/build/server/chunks/chunks/patch.js-Bl7vwsUj.js +62 -0
- package/build/server/chunks/chunks/paths.js-DVRjNYFW.js +19 -0
- package/build/server/chunks/chunks/peek.js-D9sSjT9t.js +95 -0
- package/build/server/chunks/chunks/plan.js-DFq5ntMM.js +143 -0
- package/build/server/chunks/chunks/project-files-notice.js-CcqcBgUP.js +19 -0
- package/build/server/chunks/chunks/project-files.js-DTC4jUxy.js +52 -0
- package/build/server/chunks/chunks/project-folder.js-CoKgPiM0.js +22 -0
- package/build/server/chunks/chunks/projects.js-bw2V11od.js +989 -0
- package/build/server/chunks/chunks/prs.js-CLfImauu.js +118 -0
- package/build/server/chunks/chunks/publish.js-D2vWpIJU.js +195 -0
- package/build/server/chunks/chunks/pull-list.js-BCIBJdyz.js +691 -0
- package/build/server/chunks/chunks/qa-ask.svelte.js-8Hf1JWW2.js +47 -0
- package/build/server/chunks/chunks/qa-setup.js-DFOEcNxH.js +1241 -0
- package/build/server/chunks/chunks/quiet.js-1GKY40Ay.js +104 -0
- package/build/server/chunks/chunks/rail.js-BePBwOqZ.js +135 -0
- package/build/server/chunks/chunks/review.js-MPqnq9Gy.js +98 -0
- package/build/server/chunks/chunks/routing.js-B8s1QwSP.js +265 -0
- package/build/server/chunks/chunks/run-log.js-CnN2jOcg.js +94 -0
- package/build/server/chunks/chunks/run.js-COSejjLl.js +34 -0
- package/build/server/chunks/chunks/scout-findings.js-CqJti10a.js +940 -0
- package/build/server/chunks/chunks/scout.js-Bm7wQLX2.js +62 -0
- package/build/server/chunks/chunks/sentinels.js-BXvpnzr3.js +13 -0
- package/build/server/chunks/chunks/server.js-BR0D07DR.js +3803 -0
- package/build/server/chunks/chunks/settings-sections.js-V70W7BkZ.js +103 -0
- package/build/server/chunks/chunks/shared.js-BgfCUZUJ.js +776 -0
- package/build/server/chunks/chunks/sign-in.js-O-pBhi19.js +14 -0
- package/build/server/chunks/chunks/snapshot.js-BekzL_He.js +38 -0
- package/build/server/chunks/chunks/spend.js-BabnR69T.js +63 -0
- package/build/server/chunks/chunks/src.js-Cm8RAH_q.js +609 -0
- package/build/server/chunks/chunks/src2.js-CV8tsClO.js +1186 -0
- package/build/server/chunks/chunks/src3.js-h9tTEbVb.js +11222 -0
- package/build/server/chunks/chunks/stack.js-CMWXhMZS.js +13 -0
- package/build/server/chunks/chunks/standup.js-D-qBnMx4.js +103 -0
- package/build/server/chunks/chunks/state.js-BTDrgu7s.js +71 -0
- package/build/server/chunks/chunks/stream.js-D6r6iqjD.js +66 -0
- package/build/server/chunks/chunks/terms.js-DPZztSEn.js +88 -0
- package/build/server/chunks/chunks/ticket-system.js-Dj9R3XJw.js +147 -0
- package/build/server/chunks/chunks/ticket.js-6sj-2ZEM.js +110 -0
- package/build/server/chunks/chunks/timesheet.js-DfhIokoE.js +212 -0
- package/build/server/chunks/chunks/timesheet2.js-Cu95ddl3.js +84 -0
- package/build/server/chunks/chunks/to-workspace.js-DiOJP59J.js +308 -0
- package/build/server/chunks/chunks/toast-stack.svelte.js-CXIg3_KT.js +10 -0
- package/build/server/chunks/chunks/uneval.js-VnZcgzZr.js +488 -0
- package/build/server/chunks/chunks/utils.js-DQTBh7_6.js +1006 -0
- package/build/server/chunks/chunks/when-said.js-0F9asAma.js +35 -0
- package/build/server/chunks/chunks/workspace.js-BBdJRon9.js +212 -0
- package/build/server/chunks/entries/endpoints/api/board/_server.ts.js-BlYC_lpV.js +69 -0
- package/build/server/chunks/entries/endpoints/api/board/minimize/_server.ts.js-Wddt9YPR.js +68 -0
- package/build/server/chunks/entries/endpoints/api/board/move/_server.ts.js-BwZpCKx0.js +68 -0
- package/build/server/chunks/entries/endpoints/api/board/promote/_server.ts.js-Cw6kvkMq.js +68 -0
- package/build/server/chunks/entries/endpoints/api/board/pulls/_server.ts.js-DFhpbiMo.js +71 -0
- package/build/server/chunks/entries/endpoints/api/board/stop/_server.ts.js-D5eylDMw.js +68 -0
- package/build/server/chunks/entries/endpoints/api/card/_key_/answer/_server.ts.js-CG8xh52y.js +68 -0
- package/build/server/chunks/entries/endpoints/api/card/_key_/branch/_server.ts.js-a5_P9voA.js +40 -0
- package/build/server/chunks/entries/endpoints/api/card/_key_/chain/_server.ts.js-tJvQy6RK.js +70 -0
- package/build/server/chunks/entries/endpoints/api/card/_key_/checkouts/_server.ts.js-B2_gx6vF.js +41 -0
- package/build/server/chunks/entries/endpoints/api/card/_key_/choice/_server.ts.js-pmAdIQkK.js +34 -0
- package/build/server/chunks/entries/endpoints/api/card/_key_/comments/_id_/_server.ts.js-C5NxGWw3.js +68 -0
- package/build/server/chunks/entries/endpoints/api/card/_key_/comments/_server.ts.js-0rw7UNv8.js +64 -0
- package/build/server/chunks/entries/endpoints/api/card/_key_/commit/_server.ts.js-_yXWCOlQ.js +68 -0
- package/build/server/chunks/entries/endpoints/api/card/_key_/commit-diff/_server.ts.js-CRPV3z-g.js +61 -0
- package/build/server/chunks/entries/endpoints/api/card/_key_/commit-message/_server.ts.js-CO9mD3u6.js +82 -0
- package/build/server/chunks/entries/endpoints/api/card/_key_/context/_server.ts.js-7kzrigFz.js +42 -0
- package/build/server/chunks/entries/endpoints/api/card/_key_/delete/_server.ts.js-DH0nO9wG.js +516 -0
- package/build/server/chunks/entries/endpoints/api/card/_key_/file/_server.ts.js-D80SvJDi.js +35 -0
- package/build/server/chunks/entries/endpoints/api/card/_key_/files/_...path_/_server.ts.js-GxFjb2H0.js +34 -0
- package/build/server/chunks/entries/endpoints/api/card/_key_/fix/_server.ts.js-B-HAB050.js +68 -0
- package/build/server/chunks/entries/endpoints/api/card/_key_/knowledge/_server.ts.js-D4fN-j7X.js +81 -0
- package/build/server/chunks/entries/endpoints/api/card/_key_/link/_other_/_server.ts.js-C00pQDCu.js +42 -0
- package/build/server/chunks/entries/endpoints/api/card/_key_/log/_server.ts.js-BXW_tG-I.js +32 -0
- package/build/server/chunks/entries/endpoints/api/card/_key_/log/raw/_server.ts.js-pT8StZGR.js +32 -0
- package/build/server/chunks/entries/endpoints/api/card/_key_/message/_server.ts.js-ZMno2Hu6.js +68 -0
- package/build/server/chunks/entries/endpoints/api/card/_key_/models/_server.ts.js-DEZVpqO3.js +73 -0
- package/build/server/chunks/entries/endpoints/api/card/_key_/patch/_server.ts.js-BxfLi-Zs.js +61 -0
- package/build/server/chunks/entries/endpoints/api/card/_key_/peek/_server.ts.js-CsTKWIP_.js +169 -0
- package/build/server/chunks/entries/endpoints/api/card/_key_/pr/_server.ts.js-CsOeAXkf.js +53 -0
- package/build/server/chunks/entries/endpoints/api/card/_key_/pr/comments/_server.ts.js-DZ2XHOhF.js +71 -0
- package/build/server/chunks/entries/endpoints/api/card/_key_/pr/discuss/_server.ts.js-CO8eM0e8.js +72 -0
- package/build/server/chunks/entries/endpoints/api/card/_key_/pr/discussions/_server.ts.js-Lp7l0Yqv.js +71 -0
- package/build/server/chunks/entries/endpoints/api/card/_key_/pr/fix/_server.ts.js-CeIhjpQ4.js +68 -0
- package/build/server/chunks/entries/endpoints/api/card/_key_/pr/fix-all/_server.ts.js-D-DKoCpQ.js +68 -0
- package/build/server/chunks/entries/endpoints/api/card/_key_/pr/links/_server.ts.js-B_q3jUP3.js +72 -0
- package/build/server/chunks/entries/endpoints/api/card/_key_/pr/qa/_server.ts.js-BulVcJY9.js +68 -0
- package/build/server/chunks/entries/endpoints/api/card/_key_/pr/seen/_server.ts.js-Z06A6MS1.js +71 -0
- package/build/server/chunks/entries/endpoints/api/card/_key_/pr/triage/_server.ts.js-qADU4URF.js +68 -0
- package/build/server/chunks/entries/endpoints/api/card/_key_/pull/_server.ts.js-CHnTH9WK.js +58 -0
- package/build/server/chunks/entries/endpoints/api/card/_key_/push/_server.ts.js-BPdPwPo2.js +83 -0
- package/build/server/chunks/entries/endpoints/api/card/_key_/repos/_server.ts.js-Bjqa3Uoo.js +73 -0
- package/build/server/chunks/entries/endpoints/api/card/_key_/research/_server.ts.js-DzQjoHOZ.js +138 -0
- package/build/server/chunks/entries/endpoints/api/card/_key_/retry/_server.ts.js-CAodrXqd.js +68 -0
- package/build/server/chunks/entries/endpoints/api/card/_key_/send-back/_server.ts.js-CmJSnvTx.js +68 -0
- package/build/server/chunks/entries/endpoints/api/card/_key_/stack/_server.ts.js-DjI8S94J.js +82 -0
- package/build/server/chunks/entries/endpoints/api/card/_key_/tasks/_server.ts.js-BzX_nNJk.js +71 -0
- package/build/server/chunks/entries/endpoints/api/card/_key_/thread/_server.ts.js-Dn36Guxk.js +33 -0
- package/build/server/chunks/entries/endpoints/api/cards/_server.ts.js-DPMOBsvp.js +77 -0
- package/build/server/chunks/entries/endpoints/api/cards/context/_server.ts.js-D6y-g2O-.js +52 -0
- package/build/server/chunks/entries/endpoints/api/cards/next/_server.ts.js-C2se67rf.js +55 -0
- package/build/server/chunks/entries/endpoints/api/chain/_server.ts.js-DKO5Q8GV.js +70 -0
- package/build/server/chunks/entries/endpoints/api/clones/_server.ts.js-Bgcc_Beg.js +56 -0
- package/build/server/chunks/entries/endpoints/api/current-project/_server.ts.js-DZCtSlXs.js +81 -0
- package/build/server/chunks/entries/endpoints/api/evidence/timesheet/_server.ts.js-xJwzSrcl.js +32 -0
- package/build/server/chunks/entries/endpoints/api/folders/_server.ts.js-BdcE7k8S.js +83 -0
- package/build/server/chunks/entries/endpoints/api/gh/_server.ts.js-CGvM8fn7.js +66 -0
- package/build/server/chunks/entries/endpoints/api/gh/name/_server.ts.js-CHh3tAu7.js +36 -0
- package/build/server/chunks/entries/endpoints/api/health/_server.ts.js-DLUfrHo6.js +22 -0
- package/build/server/chunks/entries/endpoints/api/login-item/_server.ts.js-Cya7S7W6.js +77 -0
- package/build/server/chunks/entries/endpoints/api/notes/_server.ts.js-DaUFVqSM.js +26 -0
- package/build/server/chunks/entries/endpoints/api/notifications/_server.ts.js-DK6NFnII.js +76 -0
- package/build/server/chunks/entries/endpoints/api/now/_server.ts.js-xW0jeJdy.js +83 -0
- package/build/server/chunks/entries/endpoints/api/package/entry/_server.ts.js-DQyZanpo.js +35 -0
- package/build/server/chunks/entries/endpoints/api/projects/_server.ts.js-CzXJTj_l.js +58 -0
- package/build/server/chunks/entries/endpoints/api/qa-setup/_server.ts.js-DujrYbEP.js +76 -0
- package/build/server/chunks/entries/endpoints/api/remove-check/_server.ts.js-1KAi9LDi.js +58 -0
- package/build/server/chunks/entries/endpoints/api/setup/_server.ts.js-D0MKtjR7.js +69 -0
- package/build/server/chunks/entries/endpoints/api/tickets/jira/_server.ts.js-Z2LdOr5l.js +39 -0
- package/build/server/chunks/entries/endpoints/api/tickets/read/_server.ts.js-BziHtc8Y.js +68 -0
- package/build/server/chunks/entries/endpoints/api/tools/_server.ts.js-oyvq8i1y.js +30 -0
- package/build/server/chunks/entries/endpoints/api/workspace/_server.ts.js-CMGBL5cX.js +58 -0
- package/build/server/chunks/entries/endpoints/api/workspace/commit/_server.ts.js-BZQQJ1YG.js +66 -0
- package/build/server/chunks/entries/endpoints/api/workspace/patch/_server.ts.js-xrjgHECx.js +64 -0
- package/build/server/chunks/entries/endpoints/api/workspace/push/_server.ts.js-CTdia7Uz.js +66 -0
- package/build/server/chunks/entries/hooks.server.js-B0jE-ELC.js +211 -0
- package/build/server/chunks/entries/pages/_error.svelte.js-DPcKI5sX.js +25 -0
- package/build/server/chunks/entries/pages/_layout.server.ts.js-Jj3i2Th9.js +134 -0
- package/build/server/chunks/entries/pages/_layout.svelte.js-Cu3ghN80.js +1251 -0
- package/build/server/chunks/entries/pages/_page.svelte.js-DEYydBCm.js +662 -0
- package/build/server/chunks/entries/pages/accept/_page.server.ts.js-BF7MrA5s.js +29 -0
- package/build/server/chunks/entries/pages/accept/_page.svelte.js-8yPsedd-.js +54 -0
- package/build/server/chunks/entries/pages/b/_board_/_page.svelte.js-S9acLF3f.js +68 -0
- package/build/server/chunks/entries/pages/b/_board_/_page.ts.js-BcKdG_Tp.js +21 -0
- package/build/server/chunks/entries/pages/b/research/_page.svelte.js-FW6Hw9g5.js +68 -0
- package/build/server/chunks/entries/pages/b/research/_page.ts.js-Ds2AjFFK.js +13 -0
- package/build/server/chunks/entries/pages/evidence/_page.server.ts.js-uwu2X7bA.js +1382 -0
- package/build/server/chunks/entries/pages/evidence/_page.svelte.js-DBCjiT59.js +594 -0
- package/build/server/chunks/entries/pages/f/_...path_/_page.svelte.js-DxwJaJzh.js +58 -0
- package/build/server/chunks/entries/pages/knowledge/_page.server.ts.js-BAUvFEcM.js +80 -0
- package/build/server/chunks/entries/pages/knowledge/_page.svelte.js-D9117gHM.js +732 -0
- package/build/server/chunks/entries/pages/new/_page.server.ts.js-BNCQQpyw.js +110 -0
- package/build/server/chunks/entries/pages/new/_page.svelte.js-Ben8-N_h.js +503 -0
- package/build/server/chunks/entries/pages/new/idea/_page.server.ts.js-jssA29y3.js +46 -0
- package/build/server/chunks/entries/pages/new/idea/_page.svelte.js-XoKspqAc.js +210 -0
- package/build/server/chunks/entries/pages/new/task/_page.server.ts.js-CmZgfvyt.js +66 -0
- package/build/server/chunks/entries/pages/new/task/_page.svelte.js-BKpERKvm.js +169 -0
- package/build/server/chunks/entries/pages/onboard/_page.server.ts.js-pmc_pXvs.js +12 -0
- package/build/server/chunks/entries/pages/onboard/_page.svelte.js-C7LNK-ba.js +5 -0
- package/build/server/chunks/entries/pages/projects/_page.server.ts.js-BEhLRfJ_.js +12 -0
- package/build/server/chunks/entries/pages/projects/_page.svelte.js-OraOjsyb.js +5 -0
- package/build/server/chunks/entries/pages/scout/_page.server.ts.js-hQYnMHwY.js +10 -0
- package/build/server/chunks/entries/pages/scout/_page.svelte.js-7q4d044Z.js +40 -0
- package/build/server/chunks/entries/pages/scout/f/_id_/_page.server.ts.js-BN4TnSpB.js +22 -0
- package/build/server/chunks/entries/pages/scout/f/_id_/_page.svelte.js-GzpLhARi.js +40 -0
- package/build/server/chunks/entries/pages/settings/_layout.server.ts.js-B5LgqMMT.js +12 -0
- package/build/server/chunks/entries/pages/settings/_layout.svelte.js-CSCpV6qA.js +81 -0
- package/build/server/chunks/entries/pages/settings/_page.svelte.js-DNpsNFo0.js +25 -0
- package/build/server/chunks/entries/pages/settings/_section_/_page.server.ts.js-nRDEV3i_.js +348 -0
- package/build/server/chunks/entries/pages/settings/_section_/_page.svelte.js-BihUf-nY.js +1052 -0
- package/build/server/chunks/entries/pages/settings/integrations/_page.server.ts.js-BTuRpg8m.js +58 -0
- package/build/server/chunks/entries/pages/settings/integrations/_page.svelte.js-C8i8ZmZR.js +161 -0
- package/build/server/chunks/entries/pages/settings/mcp/_page.server.ts.js-TFISfO1a.js +925 -0
- package/build/server/chunks/entries/pages/settings/mcp/_page.svelte.js-D1X0TNOm.js +433 -0
- package/build/server/chunks/entries/pages/settings/phases/_page.server.ts.js-CgK7MTZf.js +48 -0
- package/build/server/chunks/entries/pages/settings/phases/_page.svelte.js-u-sTQ-ue.js +80 -0
- package/build/server/chunks/entries/pages/settings/project/_page.server.ts.js-CCnk9WbO.js +363 -0
- package/build/server/chunks/entries/pages/settings/project/_page.svelte.js-MxvNqYlQ.js +1269 -0
- package/build/server/chunks/entries/pages/settings/wall/_page.server.ts.js-Bt5siY_N.js +12 -0
- package/build/server/chunks/entries/pages/settings/wall/_page.svelte.js-CMR4zSAt.js +43 -0
- package/build/server/chunks/entries/pages/t/_key_/_layout.server.ts.js-W6YPvOCA.js +124 -0
- package/build/server/chunks/entries/pages/t/_key_/_layout.svelte.js-CK0PiWsz.js +543 -0
- package/build/server/chunks/entries/pages/t/_key_/_page.server.ts.js-CdB7v0WX.js +15 -0
- package/build/server/chunks/entries/pages/t/_key_/_tab_/_page.server.ts.js-Bksaje8R.js +75 -0
- package/build/server/chunks/entries/pages/t/_key_/_tab_/_page.svelte.js-9OQ2eQxu.js +4607 -0
- package/build/server/chunks/entries/pages/team/_page.svelte.js-BdUSXC04.js +18 -0
- package/build/server/chunks/entries/pages/team/_page.ts.js-DfhJmoZI.js +20 -0
- package/build/server/chunks/entries/pages/workspace/_page.svelte.js-DLaWe23r.js +579 -0
- package/build/server/chunks/handler-Dlwmumt5.js +1735 -0
- package/build/server/chunks/index.js-BX0fZD5G.js +3701 -0
- package/build/server/chunks/manifest.js-B2Of6Dj7.js +761 -0
- package/build/server/chunks/nodes/0.js-DSzhdY0D.js +87 -0
- package/build/server/chunks/nodes/1.js-j4osL1br.js +9 -0
- package/build/server/chunks/nodes/10.js-jkvevEFY.js +75 -0
- package/build/server/chunks/nodes/11.js-plyiDP2n.js +72 -0
- package/build/server/chunks/nodes/12.js-DwtvDAyM.js +78 -0
- package/build/server/chunks/nodes/13.js-BpxwqFh4.js +72 -0
- package/build/server/chunks/nodes/14.js-B5iNIKGy.js +15 -0
- package/build/server/chunks/nodes/15.js-CXCAqUsG.js +15 -0
- package/build/server/chunks/nodes/16.js-oxkLEH0n.js +76 -0
- package/build/server/chunks/nodes/17.js-B-ZJEo9K.js +76 -0
- package/build/server/chunks/nodes/18.js-C0OUCEux.js +9 -0
- package/build/server/chunks/nodes/19.js-M8EAQJdW.js +76 -0
- package/build/server/chunks/nodes/2.js-ZedduK-3.js +33 -0
- package/build/server/chunks/nodes/20.js-BHvsLNjD.js +72 -0
- package/build/server/chunks/nodes/21.js-eOaW4si1.js +76 -0
- package/build/server/chunks/nodes/22.js-CbJ6tQSs.js +38 -0
- package/build/server/chunks/nodes/23.js-DXk8ejlx.js +81 -0
- package/build/server/chunks/nodes/24.js-C4qGJc4X.js +33 -0
- package/build/server/chunks/nodes/25.js-Cal8uT5V.js +21 -0
- package/build/server/chunks/nodes/26.js-Cp5jBcrN.js +80 -0
- package/build/server/chunks/nodes/27.js-Do55o_cb.js +17 -0
- package/build/server/chunks/nodes/28.js-SNz3QVix.js +9 -0
- package/build/server/chunks/nodes/3.js-DyivQ5dN.js +75 -0
- package/build/server/chunks/nodes/4.js-BGgTTQFR.js +9 -0
- package/build/server/chunks/nodes/5.js-DQYA2BBI.js +31 -0
- package/build/server/chunks/nodes/6.js-BVTi2KFL.js +24 -0
- package/build/server/chunks/nodes/7.js-CnprIn3p.js +12 -0
- package/build/server/chunks/nodes/8.js-Bdicn369.js +50 -0
- package/build/server/chunks/nodes/9.js-DVclPGXf.js +9 -0
- package/build/shims.js +33 -0
- package/dist/THIRD-PARTY-NOTICES.md +659 -0
- package/dist/detect-BmI_gskA.js +585 -0
- package/dist/fonts/OFL.txt +92 -0
- package/dist/nolzu.js +48 -0
- package/dist/package-vezZOzhD.js +181 -0
- package/dist/shared/finish.md +110 -0
- package/dist/shared/knowledge.md +72 -0
- package/dist/shared/verdict.md +42 -0
- package/dist/skills/.gitkeep +0 -0
- package/dist/skills/nolzu-architecture/SKILL.md +140 -0
- package/dist/skills/nolzu-architecture/finish.md +110 -0
- package/dist/skills/nolzu-assess/SKILL.md +99 -0
- package/dist/skills/nolzu-assess/finish.md +110 -0
- package/dist/skills/nolzu-design/SKILL.md +115 -0
- package/dist/skills/nolzu-design/finish.md +110 -0
- package/dist/skills/nolzu-feedback/SKILL.md +107 -0
- package/dist/skills/nolzu-feedback/finish.md +110 -0
- package/dist/skills/nolzu-implement/SKILL.md +138 -0
- package/dist/skills/nolzu-implement/finish.md +110 -0
- package/dist/skills/nolzu-investigate/SKILL.md +139 -0
- package/dist/skills/nolzu-investigate/finish.md +110 -0
- package/dist/skills/nolzu-learn-repo/SKILL.md +115 -0
- package/dist/skills/nolzu-learn-repo/finish.md +110 -0
- package/dist/skills/nolzu-learn-repo/knowledge.md +72 -0
- package/dist/skills/nolzu-optimize/SKILL.md +82 -0
- package/dist/skills/nolzu-optimize/finish.md +110 -0
- package/dist/skills/nolzu-optimize/knowledge.md +72 -0
- package/dist/skills/nolzu-orient/SKILL.md +115 -0
- package/dist/skills/nolzu-orient/finish.md +110 -0
- package/dist/skills/nolzu-orient/knowledge.md +72 -0
- package/dist/skills/nolzu-plan/SKILL.md +165 -0
- package/dist/skills/nolzu-plan/finish.md +110 -0
- package/dist/skills/nolzu-pr-review/SKILL.md +150 -0
- package/dist/skills/nolzu-pr-review/finish.md +110 -0
- package/dist/skills/nolzu-qa/SKILL.md +177 -0
- package/dist/skills/nolzu-qa/finish.md +110 -0
- package/dist/skills/nolzu-qa/verdict.md +42 -0
- package/dist/skills/nolzu-refine/SKILL.md +145 -0
- package/dist/skills/nolzu-refine/finish.md +110 -0
- package/dist/skills/nolzu-research/SKILL.md +140 -0
- package/dist/skills/nolzu-research/finish.md +110 -0
- package/dist/skills/nolzu-wrapup/SKILL.md +126 -0
- package/dist/skills/nolzu-wrapup/finish.md +110 -0
- package/dist/skills/nolzu-wrapup/knowledge.md +72 -0
- package/dist/src-BG8LaXLS.js +723 -0
- package/dist/src-DPfcvRqs.js +4 -0
- package/dist/start-ItZOcBtM.js +362 -0
- package/package.json +49 -9
- package/bin/nolzu.js +0 -8
|
@@ -0,0 +1,691 @@
|
|
|
1
|
+
import { e as projectRepos, h as boardFor, f as canMove } from './estimate.js-BHTYVTaQ.js';
|
|
2
|
+
import { g as getSetting, a9 as saveCardPull, U as bumpVersion, b as reposOfCard, w as writeSetting, aa as markDiscussion, ab as markDiscussionsSeen, d as boardOfCard, K as cardPullRows, ac as storeDiscussions, ad as cardDiscussions, a6 as createCard, a7 as setCardRepos, J as cardRepos, ae as recordMove, af as detachCardPull } from './node.js-Bz2jT5wt.js';
|
|
3
|
+
import { y as pullRequestRef } from './src.js-Cm8RAH_q.js';
|
|
4
|
+
import { D as tabsFor } from './src2.js-CV8tsClO.js';
|
|
5
|
+
import { a as gitEnv, aq as findBranchPulls, g as git, j as isPlainName, t as checkoutPath, ar as branchPullsQuery, ak as ghRunner, as as readPullDiscussions, at as listOpenPulls, am as getPull, al as issueKey } from './src3.js-h9tTEbVb.js';
|
|
6
|
+
import { c as cardCheckouts, d as cardBranch } from './checkout.js-Ys5L_gA4.js';
|
|
7
|
+
import { r as remoteRepo, R as READ_TIMEOUT_MS } from './create-card.js-DKtprMG6.js';
|
|
8
|
+
|
|
9
|
+
//#region src/lib/pull-list.ts
|
|
10
|
+
var WAITS_ON_AUTHOR = "awaiting-author";
|
|
11
|
+
var APPROVED = "approved";
|
|
12
|
+
/**
|
|
13
|
+
* Where a card that waits on the author goes after a read, or null when it stays.
|
|
14
|
+
*
|
|
15
|
+
* The person's own approval takes it to Approved, and it counts only when it was given on the head
|
|
16
|
+
* the pull request has now. The commit says the approval saw the code, so a push after it is code
|
|
17
|
+
* nobody approved. Approving often comes before the drag to Awaiting author, from My review, so the
|
|
18
|
+
* approval may be older than that move. Once the card has left Approved, though (`left`, the newest
|
|
19
|
+
* move out of it), the approval has to be newer than that move: an approval from before it is the one
|
|
20
|
+
* the person already took the card back from, so the card stays where they put it. Anything else
|
|
21
|
+
* takes the push rule: Incoming when the head moved since the last round, or no move. `decision` is
|
|
22
|
+
* not asked, because GitHub says APPROVED there once anybody's approvals meet the rule.
|
|
23
|
+
*/
|
|
24
|
+
function onward(found, moved, first, left) {
|
|
25
|
+
const review = found.ownReview;
|
|
26
|
+
if (review?.state === "APPROVED" && review.oid !== null && review.oid === found.headSha && (left === null || review.at !== null && Date.parse(review.at) > Date.parse(left))) return APPROVED;
|
|
27
|
+
return moved ? first : null;
|
|
28
|
+
}
|
|
29
|
+
/**
|
|
30
|
+
* The PR reviews board reads the open pull requests of a repository.
|
|
31
|
+
*
|
|
32
|
+
* A pull request that is new and asks for the person's review, or a team's they are in, gets a card on
|
|
33
|
+
* the first column. Others get none: on a team's repository most open pull requests are someone
|
|
34
|
+
* else's to review, and Add pull request takes one by its number. One that has a card gets its author,
|
|
35
|
+
* decision, head commit, commit count and draft flag written again. A card that waits on the author
|
|
36
|
+
* and whose head moved since its last review round goes back to Incoming, because the push is what
|
|
37
|
+
* it waited for, and one the person approved themselves goes on to Approved (`onward`). Either move
|
|
38
|
+
* is `auto` and starts nothing: the next round is still a person's drop on Agent pre-review. A card
|
|
39
|
+
* with no saved round head never moves back, because nothing says what its review read. A card
|
|
40
|
+
* anywhere else stays where a person put it, and the push is what its "1 new commit" and the sentence
|
|
41
|
+
* say. A card whose pull request left the open list is read once more by number, because gone from
|
|
42
|
+
* the list is not proof of closed, and is marked closed or merged when GitHub says so. The card stays:
|
|
43
|
+
* a review written on it is still worth reading.
|
|
44
|
+
*
|
|
45
|
+
* The list is read before anything is written, and an answer the reader cannot read throws, so a
|
|
46
|
+
* failed read leaves the board as it was rather than drawing an empty repository.
|
|
47
|
+
*
|
|
48
|
+
* Until one read has finished under that rule (`pullsAskOnly`), a read also removes the cards an older
|
|
49
|
+
* read added for every open pull request: on the first column, never moved, never run, with no text
|
|
50
|
+
* of the person's, and not asking for their review now. They are not recorded as deleted, so a later
|
|
51
|
+
* review request still brings the pull request back.
|
|
52
|
+
*/
|
|
53
|
+
async function refreshPulls(db, run, repo, signal) {
|
|
54
|
+
const list = await listOpenPulls(run, repo, signal);
|
|
55
|
+
const full = (number) => issueKey(repo.owner, repo.repo, number);
|
|
56
|
+
const listed = new Set(list.pulls.map((found) => full(found.number)));
|
|
57
|
+
const mine = db.prepare("SELECT key, source_ref AS ref, pr_state AS state FROM cards WHERE board = 'prreview' AND source = 'github-pr'").all().filter((card) => card.ref?.startsWith(`${repo.owner.toLowerCase()}/${repo.repo.toLowerCase()}#`));
|
|
58
|
+
const left = await Promise.all(mine.filter((card) => (card.state ?? "open") === "open" && card.ref !== null && !listed.has(card.ref)).map(async (card) => ({
|
|
59
|
+
card,
|
|
60
|
+
found: await getPull(run, {
|
|
61
|
+
...repo,
|
|
62
|
+
number: Number(card.ref?.split("#")[1])
|
|
63
|
+
}, signal)
|
|
64
|
+
})));
|
|
65
|
+
const board = boardFor("prreview", getSetting(db, "deliveryFlow"));
|
|
66
|
+
const first = board.stages[0]?.id ?? "incoming";
|
|
67
|
+
const added = [];
|
|
68
|
+
const closed = [];
|
|
69
|
+
const merged = [];
|
|
70
|
+
const pushed = [];
|
|
71
|
+
const back = [];
|
|
72
|
+
const approved = [];
|
|
73
|
+
const clashes = [];
|
|
74
|
+
const swept = [];
|
|
75
|
+
const leftApproved = (key) => db.prepare("SELECT at FROM card_events WHERE card_key = ? AND from_stage = ? ORDER BY id DESC LIMIT 1").get(key, APPROVED)?.at ?? null;
|
|
76
|
+
db.exec("BEGIN IMMEDIATE");
|
|
77
|
+
try {
|
|
78
|
+
for (const found of list.pulls) {
|
|
79
|
+
const ref = full(found.number);
|
|
80
|
+
const taken = db.prepare("SELECT source_ref AS ref, pr_head_sha AS reviewed, stage, state FROM cards WHERE key = ?").get(found.key);
|
|
81
|
+
const pull = {
|
|
82
|
+
author: found.author,
|
|
83
|
+
decision: found.decision,
|
|
84
|
+
headCommittedAt: found.headCommittedAt,
|
|
85
|
+
draft: found.draft,
|
|
86
|
+
...found.headSha === void 0 ? {} : { headSha: found.headSha },
|
|
87
|
+
...found.commits === void 0 ? {} : { commits: found.commits }
|
|
88
|
+
};
|
|
89
|
+
if (taken === void 0 && !list.asked.has(found.number)) continue;
|
|
90
|
+
if (taken === void 0 && db.prepare("SELECT 1 FROM deleted_tickets WHERE source_ref = ?").get(ref) !== void 0) continue;
|
|
91
|
+
if (taken === void 0) {
|
|
92
|
+
createCard(db, {
|
|
93
|
+
key: found.key,
|
|
94
|
+
board: "prreview",
|
|
95
|
+
stage: first,
|
|
96
|
+
title: found.title,
|
|
97
|
+
summary: found.body === "" ? null : found.body,
|
|
98
|
+
source: "github-pr",
|
|
99
|
+
sourceRef: ref,
|
|
100
|
+
pull
|
|
101
|
+
});
|
|
102
|
+
db.prepare("UPDATE cards SET pr_state = 'open' WHERE key = ?").run(found.key);
|
|
103
|
+
if (repo.path !== void 0) setCardRepos(db, found.key, [repo.path], "person");
|
|
104
|
+
added.push(found.key);
|
|
105
|
+
} else if (taken.ref === ref) {
|
|
106
|
+
if (repo.path !== void 0 && cardRepos(db, found.key) === null) setCardRepos(db, found.key, [repo.path], "person");
|
|
107
|
+
db.prepare("UPDATE cards SET pr_author = ?, pr_decision = ?, pr_head_at = ?, pr_draft = ?, pr_seen_sha = ?, pr_seen_commits = ?, pr_state = 'open' WHERE key = ?").run(pull.author, pull.decision, pull.headCommittedAt, pull.draft ? 1 : 0, found.headSha ?? null, found.commits ?? null, found.key);
|
|
108
|
+
const moved = found.headSha !== void 0 && taken.reviewed !== null && found.headSha !== taken.reviewed;
|
|
109
|
+
const target = taken.stage === WAITS_ON_AUTHOR ? onward(found, moved, first, leftApproved(found.key)) : null;
|
|
110
|
+
const to = target !== null && canMove(board, taken, target) ? target : null;
|
|
111
|
+
if (to !== null) {
|
|
112
|
+
recordMove(db, found.key, taken.stage, to, "auto", null);
|
|
113
|
+
db.prepare("UPDATE cards SET stage = ? WHERE key = ?").run(to, found.key);
|
|
114
|
+
(to === APPROVED ? approved : back).push(found.key);
|
|
115
|
+
} else if (moved) pushed.push(found.key);
|
|
116
|
+
} else clashes.push(`${found.key} on the board is ${taken.ref ?? "a card of its own"}, so ${ref} was left off.`);
|
|
117
|
+
}
|
|
118
|
+
if (!getSetting(db, "pullsAskOnly")) {
|
|
119
|
+
const untouched = db.prepare("SELECT 1 FROM cards c WHERE c.key = ? AND c.stage = ? AND c.state = 'idle' AND coalesce(c.extra_context, '') = '' AND NOT EXISTS (SELECT 1 FROM card_events WHERE card_key = c.key) AND NOT EXISTS (SELECT 1 FROM runs WHERE card_key = c.key)");
|
|
120
|
+
for (const card of mine) {
|
|
121
|
+
if (card.ref === null || !listed.has(card.ref) || list.asked.has(Number(card.ref.split("#")[1])) || untouched.get(card.key, first) === void 0) continue;
|
|
122
|
+
db.prepare("DELETE FROM notifications WHERE card_key = ?").run(card.key);
|
|
123
|
+
db.prepare("DELETE FROM cards WHERE key = ?").run(card.key);
|
|
124
|
+
swept.push(card.key);
|
|
125
|
+
}
|
|
126
|
+
}
|
|
127
|
+
for (const { card, found } of left) {
|
|
128
|
+
if (found.pull === null || found.pull.state === "open") continue;
|
|
129
|
+
db.prepare("UPDATE cards SET pr_state = ? WHERE key = ?").run(found.pull.state, card.key);
|
|
130
|
+
closed.push(card.key);
|
|
131
|
+
if (found.pull.state === "merged") merged.push(card.key);
|
|
132
|
+
}
|
|
133
|
+
bumpVersion(db);
|
|
134
|
+
db.exec("COMMIT");
|
|
135
|
+
} catch (error) {
|
|
136
|
+
if (db.isTransaction) db.exec("ROLLBACK");
|
|
137
|
+
throw error;
|
|
138
|
+
}
|
|
139
|
+
const name = `${repo.owner}/${repo.repo}`;
|
|
140
|
+
return {
|
|
141
|
+
added,
|
|
142
|
+
closed,
|
|
143
|
+
said: [
|
|
144
|
+
list.pulls.length === 0 ? `${name} has no open pull request.` : `${name} has ${list.pulls.length === 1 ? "1 open pull request" : `${list.pulls.length} open pull requests`}, ${list.asked.size} asking for your review, ${added.length} new on the board.`,
|
|
145
|
+
...swept.length === 0 ? [] : [`Removed ${swept.length === 1 ? "1 card" : `${swept.length} cards`} an older read added for pull requests that do not ask for your review.`],
|
|
146
|
+
...closed.length === merged.length ? [] : [`Closed since the last read: ${closed.filter((key) => !merged.includes(key)).join(", ")}.`],
|
|
147
|
+
...merged.length === 0 ? [] : [`Merged since the last read: ${merged.join(", ")}.`],
|
|
148
|
+
...back.map((key) => `${key} has new commits and went back to ${board.stages[0]?.label ?? first}.`),
|
|
149
|
+
...approved.map((key) => `${key} is approved by you and moved to ${board.stages.find((stage) => stage.id === APPROVED)?.label ?? APPROVED}.`),
|
|
150
|
+
...pushed.length === 0 ? [] : [`New commits since the last review round: ${pushed.join(", ")}.`],
|
|
151
|
+
...list.more ? ["The board read the oldest 100. The rest are on GitHub."] : [],
|
|
152
|
+
...clashes
|
|
153
|
+
].join(" ")
|
|
154
|
+
};
|
|
155
|
+
}
|
|
156
|
+
var answer = (status, body) => new Response(JSON.stringify(body), {
|
|
157
|
+
status,
|
|
158
|
+
headers: { "content-type": "application/json" }
|
|
159
|
+
});
|
|
160
|
+
async function postPullRefresh(db, told, run = ghRunner()) {
|
|
161
|
+
const repos = projectRepos({
|
|
162
|
+
repos: getSetting(db, "repos"),
|
|
163
|
+
baseBranch: getSetting(db, "baseBranch")
|
|
164
|
+
});
|
|
165
|
+
const origins = (await Promise.all(repos.map(async (one) => ({
|
|
166
|
+
origin: await remoteRepo(db, one.path),
|
|
167
|
+
path: one.path
|
|
168
|
+
})))).flatMap(({ origin, path }) => origin === null ? [] : [{
|
|
169
|
+
...origin,
|
|
170
|
+
path
|
|
171
|
+
}]);
|
|
172
|
+
const unique = [...new Map(origins.map((one) => [`${one.owner}/${one.repo}`.toLowerCase(), one])).values()];
|
|
173
|
+
if (unique.length === 0) return answer(409, { message: "No repository of this project has a GitHub remote, so the board has no repository to read pull requests from. Add a card by its pull request number instead." });
|
|
174
|
+
const done = {
|
|
175
|
+
added: [],
|
|
176
|
+
closed: [],
|
|
177
|
+
said: ""
|
|
178
|
+
};
|
|
179
|
+
const said = [];
|
|
180
|
+
const failed = [];
|
|
181
|
+
for (const repo of unique) try {
|
|
182
|
+
const one = await refreshPulls(db, run, repo, AbortSignal.timeout(READ_TIMEOUT_MS));
|
|
183
|
+
done.added.push(...one.added);
|
|
184
|
+
done.closed.push(...one.closed);
|
|
185
|
+
said.push(one.said);
|
|
186
|
+
} catch (error) {
|
|
187
|
+
failed.push(error.message);
|
|
188
|
+
}
|
|
189
|
+
if (said.length === 0) return answer(409, { message: failed.join(" ") });
|
|
190
|
+
if (failed.length === 0) {
|
|
191
|
+
writeSetting(db, "pullsReadAt", (/* @__PURE__ */ new Date()).toISOString());
|
|
192
|
+
writeSetting(db, "pullsAskOnly", true);
|
|
193
|
+
}
|
|
194
|
+
told();
|
|
195
|
+
return answer(200, {
|
|
196
|
+
...done,
|
|
197
|
+
said: [...said, ...failed].join(" ")
|
|
198
|
+
});
|
|
199
|
+
}
|
|
200
|
+
/**
|
|
201
|
+
* What a Delivery card's pull requests add up to, one per repository, or null when none was found.
|
|
202
|
+
*
|
|
203
|
+
* Open while any one is open, merged once every one is merged, and closed when none is open and one
|
|
204
|
+
* closed without a merge. The rest of the line describes the open ones while there are any, because
|
|
205
|
+
* those are what the person waits on. The decision is the weakest of them, so an approval in one
|
|
206
|
+
* repository never hides a request for changes in another.
|
|
207
|
+
*/
|
|
208
|
+
function cardPull(found) {
|
|
209
|
+
if (found.length === 0) return null;
|
|
210
|
+
const open = found.filter((pull) => pull.state === "open");
|
|
211
|
+
const pool = open.length > 0 ? open : found;
|
|
212
|
+
const decision = pool.some((pull) => pull.decision === "CHANGES_REQUESTED") ? "CHANGES_REQUESTED" : pool.every((pull) => pull.decision === "APPROVED") ? "APPROVED" : "REVIEW_REQUIRED";
|
|
213
|
+
return {
|
|
214
|
+
state: open.length > 0 ? "open" : found.every((pull) => pull.state === "merged") ? "merged" : "closed",
|
|
215
|
+
author: pool[0]?.author ?? null,
|
|
216
|
+
decision,
|
|
217
|
+
headCommittedAt: pool.flatMap((pull) => pull.headCommittedAt === null ? [] : [pull.headCommittedAt]).sort().at(-1) ?? null,
|
|
218
|
+
draft: pool.some((pull) => pull.draft)
|
|
219
|
+
};
|
|
220
|
+
}
|
|
221
|
+
/**
|
|
222
|
+
* What GitHub is asked for one card's pull requests: each card repository with a GitHub `origin`, by
|
|
223
|
+
* the card's branch. Throws the sentence for a card that names no repositories yet.
|
|
224
|
+
*/
|
|
225
|
+
async function branchAsks(db, project, key, env) {
|
|
226
|
+
const repos = reposOfCard(db, key);
|
|
227
|
+
if (repos === null) throw new Error(`Nothing says which repositories ${key} changes yet. Pick them on its Settings tab.`);
|
|
228
|
+
const checkouts = isPlainName(key) ? repos.map((repo) => checkoutPath(project, key, repo)) : [];
|
|
229
|
+
const mine = [];
|
|
230
|
+
for (const [index, repo] of repos.entries()) {
|
|
231
|
+
const origin = await remoteRepo(db, repo);
|
|
232
|
+
if (origin === null) continue;
|
|
233
|
+
const own = checkouts[index];
|
|
234
|
+
const ask = {
|
|
235
|
+
...origin,
|
|
236
|
+
branch: await cardBranch(db, key, own === void 0 ? checkouts : [own, ...checkouts], env)
|
|
237
|
+
};
|
|
238
|
+
branchPullsQuery([ask]);
|
|
239
|
+
mine.push(ask);
|
|
240
|
+
}
|
|
241
|
+
return mine;
|
|
242
|
+
}
|
|
243
|
+
/**
|
|
244
|
+
* PR watch looks up the pull request of each Delivery card that waits on one: every card on PR watch,
|
|
245
|
+
* and a card further on while its pull request is open or not looked up yet. Nobody gave Nolzu a
|
|
246
|
+
* number for it, so each of the card's repositories with a GitHub `origin` is asked for the pull
|
|
247
|
+
* request whose head is the card's branch.
|
|
248
|
+
*
|
|
249
|
+
* The card's `pr_` columns are written the way the PR reviews board writes its own, so the board, the
|
|
250
|
+
* Review tab and the board sync read them with no rule of their own. The card never moves: the person
|
|
251
|
+
* drags it on to Wrap-up. A card with any repository GitHub did not answer for is left as it was, and
|
|
252
|
+
* so is one with no pull request found, because gone is not proof of anything.
|
|
253
|
+
*/
|
|
254
|
+
async function refreshDeliveryPulls(db, run, signal) {
|
|
255
|
+
const project = getSetting(db, "projectPath");
|
|
256
|
+
if (project === null) return {
|
|
257
|
+
said: "No project folder is set, so there is no repository to look up pull requests in.",
|
|
258
|
+
read: []
|
|
259
|
+
};
|
|
260
|
+
const stages = boardFor("delivery", getSetting(db, "deliveryFlow")).stages;
|
|
261
|
+
const later = stages.slice(stages.findIndex((stage) => stage.id === "pr-watch") + 1);
|
|
262
|
+
const waits = (card) => card.stage === "pr-watch" || later.some((stage) => stage.id === card.stage && (card.state === "open" || card.state === null && stage.role !== "archive"));
|
|
263
|
+
const due = db.prepare("SELECT key, stage, pr_state AS state FROM cards WHERE board = 'delivery' ORDER BY key").all().filter(waits);
|
|
264
|
+
if (due.length === 0) return {
|
|
265
|
+
said: "No card in the Pull request column or later waits on a pull request, so nothing was looked up.",
|
|
266
|
+
read: []
|
|
267
|
+
};
|
|
268
|
+
const env = gitEnv(process.env);
|
|
269
|
+
const asks = [];
|
|
270
|
+
const looked = [];
|
|
271
|
+
const notes = [];
|
|
272
|
+
for (const card of due) try {
|
|
273
|
+
const mine = await branchAsks(db, project, card.key, env);
|
|
274
|
+
if (mine.length === 0) notes.push(`${card.key} has no repository with a GitHub origin, so its pull request was not looked up.`);
|
|
275
|
+
else looked.push({
|
|
276
|
+
key: card.key,
|
|
277
|
+
asks: mine.map((ask) => asks.push(ask) - 1)
|
|
278
|
+
});
|
|
279
|
+
} catch (error) {
|
|
280
|
+
notes.push(`${card.key} was not looked up. ${error.message}`);
|
|
281
|
+
}
|
|
282
|
+
const found = asks.length === 0 ? [] : await findBranchPulls(run, asks, signal);
|
|
283
|
+
const writes = [];
|
|
284
|
+
const named = {
|
|
285
|
+
open: [],
|
|
286
|
+
merged: [],
|
|
287
|
+
closed: [],
|
|
288
|
+
none: []
|
|
289
|
+
};
|
|
290
|
+
for (const card of looked) {
|
|
291
|
+
const unread = card.asks.filter((at) => found[at]?.read !== true).map((at) => `${asks[at]?.owner}/${asks[at]?.repo}`);
|
|
292
|
+
if (unread.length > 0) {
|
|
293
|
+
notes.push(`GitHub did not answer for ${unread.join(" and ")}, so ${card.key} was left as it was. A repository may be gone, or this login cannot open it.`);
|
|
294
|
+
continue;
|
|
295
|
+
}
|
|
296
|
+
const pull = cardPull(card.asks.flatMap((at) => found[at]?.pull ?? []));
|
|
297
|
+
if (pull === null) {
|
|
298
|
+
named.none.push(card.key);
|
|
299
|
+
continue;
|
|
300
|
+
}
|
|
301
|
+
named[pull.state].push(card.key);
|
|
302
|
+
writes.push({
|
|
303
|
+
key: card.key,
|
|
304
|
+
pull
|
|
305
|
+
});
|
|
306
|
+
}
|
|
307
|
+
if (writes.length > 0) {
|
|
308
|
+
db.exec("BEGIN IMMEDIATE");
|
|
309
|
+
try {
|
|
310
|
+
const write = db.prepare("UPDATE cards SET pr_author = ?, pr_decision = ?, pr_head_at = ?, pr_draft = ?, pr_state = ? WHERE key = ? AND board = 'delivery'");
|
|
311
|
+
for (const { key, pull } of writes) write.run(pull.author, pull.decision, pull.headCommittedAt, pull.draft ? 1 : 0, pull.state, key);
|
|
312
|
+
bumpVersion(db);
|
|
313
|
+
db.exec("COMMIT");
|
|
314
|
+
} catch (error) {
|
|
315
|
+
if (db.isTransaction) db.exec("ROLLBACK");
|
|
316
|
+
throw error;
|
|
317
|
+
}
|
|
318
|
+
}
|
|
319
|
+
const list = (keys, words) => keys.length === 0 ? [] : [`${words}${keys.join(", ")}.`];
|
|
320
|
+
return {
|
|
321
|
+
said: [
|
|
322
|
+
...looked.length === 0 ? [] : [`Looked up the pull requests of ${looked.length === 1 ? "1 card" : `${looked.length} cards`} in the Pull request column or later.`],
|
|
323
|
+
...list(named.open, "Open: "),
|
|
324
|
+
...list(named.merged, "Merged: "),
|
|
325
|
+
...list(named.closed, "Closed without a merge: "),
|
|
326
|
+
...list(named.none, "No pull request found for "),
|
|
327
|
+
...notes
|
|
328
|
+
].join(" "),
|
|
329
|
+
read: writes.map((write) => write.key)
|
|
330
|
+
};
|
|
331
|
+
}
|
|
332
|
+
var WATCHED = [
|
|
333
|
+
"review",
|
|
334
|
+
"pr-watch",
|
|
335
|
+
"wrapup"
|
|
336
|
+
];
|
|
337
|
+
/** The Delivery cards from Review to Wrap-up that have no pull request linked yet, by key. */
|
|
338
|
+
function unlinkedCards(db) {
|
|
339
|
+
return db.prepare(`SELECT key FROM cards WHERE board = 'delivery' AND stage IN (${WATCHED.map(() => "?").join(", ")}) AND key NOT IN (SELECT card_key FROM card_pulls) ORDER BY key`).all(...WATCHED).map((one) => one.key);
|
|
340
|
+
}
|
|
341
|
+
async function branchPushed(db, key, env) {
|
|
342
|
+
for (const one of cardCheckouts(db, key)) if ((await git([
|
|
343
|
+
"rev-parse",
|
|
344
|
+
"--verify",
|
|
345
|
+
"--quiet",
|
|
346
|
+
"@{upstream}"
|
|
347
|
+
], {
|
|
348
|
+
cwd: one.path,
|
|
349
|
+
env
|
|
350
|
+
})).code === 0) return true;
|
|
351
|
+
return false;
|
|
352
|
+
}
|
|
353
|
+
/**
|
|
354
|
+
* Finds the open pull request of each card's pushed branch, without a press, and links it as found by
|
|
355
|
+
* the branch, with the `pr_` columns Read pull requests writes. One gh document asks for every card, and
|
|
356
|
+
* a card whose branch is not pushed is not asked for. Only an open pull request is linked. A gh that is
|
|
357
|
+
* missing or logged out throws before anything is written, and the caller stays quiet about it.
|
|
358
|
+
*/
|
|
359
|
+
async function linkOpenPulls(db, keys, run, signal) {
|
|
360
|
+
const project = getSetting(db, "projectPath");
|
|
361
|
+
if (project === null) return [];
|
|
362
|
+
const env = gitEnv(process.env);
|
|
363
|
+
const asks = [];
|
|
364
|
+
const cards = [];
|
|
365
|
+
for (const key of keys) try {
|
|
366
|
+
if (!await branchPushed(db, key, env)) continue;
|
|
367
|
+
const mine = await branchAsks(db, project, key, env);
|
|
368
|
+
if (mine.length > 0) cards.push({
|
|
369
|
+
key,
|
|
370
|
+
asks: mine.map((ask) => asks.push(ask) - 1)
|
|
371
|
+
});
|
|
372
|
+
} catch {}
|
|
373
|
+
if (asks.length === 0) return [];
|
|
374
|
+
const found = await findBranchPulls(run, asks, signal);
|
|
375
|
+
const linked = [];
|
|
376
|
+
for (const card of cards) {
|
|
377
|
+
const open = card.asks.flatMap((at) => {
|
|
378
|
+
const one = found[at];
|
|
379
|
+
const ask = asks[at];
|
|
380
|
+
return one?.read === true && one.pull?.state === "open" && ask !== void 0 ? [{
|
|
381
|
+
ask,
|
|
382
|
+
pull: one.pull
|
|
383
|
+
}] : [];
|
|
384
|
+
});
|
|
385
|
+
if (open.length === 0) continue;
|
|
386
|
+
for (const { ask, pull } of open) saveCardPull(db, card.key, {
|
|
387
|
+
repo: `${ask.owner}/${ask.repo}`,
|
|
388
|
+
number: pull.number,
|
|
389
|
+
url: pull.url,
|
|
390
|
+
foundBy: "branch",
|
|
391
|
+
title: pull.title,
|
|
392
|
+
state: pull.state
|
|
393
|
+
});
|
|
394
|
+
const pull = cardPull(open.map((one) => one.pull));
|
|
395
|
+
if (pull !== null) db.prepare("UPDATE cards SET pr_author = ?, pr_decision = ?, pr_head_at = ?, pr_draft = ?, pr_state = ? WHERE key = ? AND board = 'delivery'").run(pull.author, pull.decision, pull.headCommittedAt, pull.draft ? 1 : 0, pull.state, card.key);
|
|
396
|
+
linked.push(card.key);
|
|
397
|
+
}
|
|
398
|
+
if (linked.length > 0) bumpVersion(db);
|
|
399
|
+
return linked;
|
|
400
|
+
}
|
|
401
|
+
async function postDeliveryPulls(db, told, run = ghRunner()) {
|
|
402
|
+
let done;
|
|
403
|
+
try {
|
|
404
|
+
done = await refreshDeliveryPulls(db, run, AbortSignal.timeout(READ_TIMEOUT_MS));
|
|
405
|
+
} catch (error) {
|
|
406
|
+
return answer(409, { message: error.message });
|
|
407
|
+
}
|
|
408
|
+
const fresh = [];
|
|
409
|
+
const notes = [];
|
|
410
|
+
for (const key of done.read) try {
|
|
411
|
+
if ((await readCardDiscussions(db, key, run)).messages > 0) fresh.push(key);
|
|
412
|
+
} catch (error) {
|
|
413
|
+
notes.push(`The comments of ${key} were not read. ${error.message}`);
|
|
414
|
+
}
|
|
415
|
+
boardTold(db, told);
|
|
416
|
+
return answer(200, { said: [
|
|
417
|
+
done.said,
|
|
418
|
+
...fresh.length === 0 ? [] : [`New comments: ${fresh.join(", ")}.`],
|
|
419
|
+
...notes
|
|
420
|
+
].join(" ") });
|
|
421
|
+
}
|
|
422
|
+
var discussionInputs = (read) => [
|
|
423
|
+
...read.threads.map((thread) => ({
|
|
424
|
+
kind: "thread",
|
|
425
|
+
githubId: thread.id,
|
|
426
|
+
path: thread.path,
|
|
427
|
+
line: thread.line,
|
|
428
|
+
resolved: thread.resolved,
|
|
429
|
+
outdated: thread.outdated,
|
|
430
|
+
messages: thread.comments.map((one) => ({
|
|
431
|
+
githubId: one.id,
|
|
432
|
+
author: one.author,
|
|
433
|
+
body: one.body,
|
|
434
|
+
createdAt: one.createdAt,
|
|
435
|
+
url: one.url
|
|
436
|
+
}))
|
|
437
|
+
})),
|
|
438
|
+
...read.reviews.map((review) => ({
|
|
439
|
+
kind: "review",
|
|
440
|
+
githubId: review.id,
|
|
441
|
+
path: null,
|
|
442
|
+
line: null,
|
|
443
|
+
resolved: false,
|
|
444
|
+
outdated: false,
|
|
445
|
+
messages: [{
|
|
446
|
+
githubId: review.id,
|
|
447
|
+
author: review.author,
|
|
448
|
+
body: review.body,
|
|
449
|
+
createdAt: review.submittedAt,
|
|
450
|
+
url: review.url
|
|
451
|
+
}]
|
|
452
|
+
})),
|
|
453
|
+
...read.comments.map((one) => ({
|
|
454
|
+
kind: "comment",
|
|
455
|
+
githubId: one.id,
|
|
456
|
+
path: null,
|
|
457
|
+
line: null,
|
|
458
|
+
resolved: false,
|
|
459
|
+
outdated: false,
|
|
460
|
+
messages: [{
|
|
461
|
+
githubId: one.id,
|
|
462
|
+
author: one.author,
|
|
463
|
+
body: one.body,
|
|
464
|
+
createdAt: one.createdAt,
|
|
465
|
+
url: one.url
|
|
466
|
+
}]
|
|
467
|
+
}))
|
|
468
|
+
];
|
|
469
|
+
/**
|
|
470
|
+
* Reads what people wrote on a Delivery card's pull requests and stores it. The pull requests are found
|
|
471
|
+
* the way PR watch finds them, by the card's branch in each repository with a GitHub origin, and kept as
|
|
472
|
+
* found by branch. Every pull request the card holds is then read, an attached one too.
|
|
473
|
+
*
|
|
474
|
+
* Only a press calls this, never a timer, and every gh call is a GraphQL query: Nolzu writes nothing to
|
|
475
|
+
* GitHub. A gh that is missing or logged out throws its own sentence. Each pull request is stored as it
|
|
476
|
+
* is read, so one that fails after another keeps the first.
|
|
477
|
+
*/
|
|
478
|
+
async function readCardDiscussions(db, key, run = ghRunner(), signal = AbortSignal.timeout(READ_TIMEOUT_MS)) {
|
|
479
|
+
if (boardOfCard(db, key) !== "delivery") throw new Error(`${key} is not a Delivery card, so it has no pull request comments to read.`);
|
|
480
|
+
const project = getSetting(db, "projectPath");
|
|
481
|
+
if (project === null) throw new Error("No project folder is set, so there is no repository to look up pull requests in.");
|
|
482
|
+
const asks = await branchAsks(db, project, key, gitEnv(process.env));
|
|
483
|
+
const found = asks.length === 0 ? [] : await findBranchPulls(run, asks, signal);
|
|
484
|
+
const notes = [];
|
|
485
|
+
for (const [at, ask] of asks.entries()) {
|
|
486
|
+
const one = found[at];
|
|
487
|
+
if (one?.read !== true) notes.push(`GitHub did not answer for ${ask.owner}/${ask.repo}. The repository may be gone, or this login cannot open it.`);
|
|
488
|
+
else if (one.pull !== null) saveCardPull(db, key, {
|
|
489
|
+
repo: `${ask.owner}/${ask.repo}`,
|
|
490
|
+
number: one.pull.number,
|
|
491
|
+
url: one.pull.url,
|
|
492
|
+
foundBy: "branch",
|
|
493
|
+
title: one.pull.title,
|
|
494
|
+
state: one.pull.state
|
|
495
|
+
});
|
|
496
|
+
}
|
|
497
|
+
const pulls = cardPullRows(db, key);
|
|
498
|
+
const done = {
|
|
499
|
+
added: 0,
|
|
500
|
+
messages: 0
|
|
501
|
+
};
|
|
502
|
+
for (const pull of pulls) {
|
|
503
|
+
const [owner = "", repo = ""] = pull.repo.split("/");
|
|
504
|
+
const read = await readPullDiscussions(run, {
|
|
505
|
+
owner,
|
|
506
|
+
repo,
|
|
507
|
+
number: pull.number
|
|
508
|
+
}, signal);
|
|
509
|
+
const stored = storeDiscussions(db, pull.id, read.viewer, discussionInputs(read));
|
|
510
|
+
done.added += stored.added;
|
|
511
|
+
done.messages += stored.messages;
|
|
512
|
+
}
|
|
513
|
+
const held = cardDiscussions(db, key);
|
|
514
|
+
const unread = held.filter((one) => one.messages.some((message) => message.unread)).length;
|
|
515
|
+
const said = pulls.length === 0 ? `No pull request was found for ${key}, so there are no comments to read.` : `Read the comments of ${pulls.length === 1 ? "1 pull request" : `${pulls.length} pull requests`}: ${done.messages === 1 ? "1 new message" : `${done.messages} new messages`}.`;
|
|
516
|
+
return {
|
|
517
|
+
pulls: pulls.length,
|
|
518
|
+
...done,
|
|
519
|
+
discussions: held.length,
|
|
520
|
+
unread,
|
|
521
|
+
said: [said, ...notes].join(" ")
|
|
522
|
+
};
|
|
523
|
+
}
|
|
524
|
+
async function postCardDiscussions(db, key, told, run = ghRunner()) {
|
|
525
|
+
try {
|
|
526
|
+
const read = await readCardDiscussions(db, key, run);
|
|
527
|
+
boardTold(db, told);
|
|
528
|
+
return answer(200, read);
|
|
529
|
+
} catch (error) {
|
|
530
|
+
return answer(409, { message: error.message });
|
|
531
|
+
}
|
|
532
|
+
}
|
|
533
|
+
function boardTold(db, told) {
|
|
534
|
+
bumpVersion(db);
|
|
535
|
+
told();
|
|
536
|
+
}
|
|
537
|
+
function postDiscussionsSeen(db, key, told) {
|
|
538
|
+
const seen = markDiscussionsSeen(db, key);
|
|
539
|
+
if (seen > 0) boardTold(db, told);
|
|
540
|
+
return answer(200, { seen });
|
|
541
|
+
}
|
|
542
|
+
function patchDiscussion(db, key, body, told) {
|
|
543
|
+
const { ref, action } = body ?? {};
|
|
544
|
+
if (typeof ref !== "string" || action !== "done" && action !== "reopen") return answer(400, { message: "Send the ref of the comment, as in T1, and done or reopen." });
|
|
545
|
+
const done = markDiscussion(db, key, ref, action);
|
|
546
|
+
if (done === "missing") return answer(404, { message: `${key} has no comment ${ref}. Read the comments again.` });
|
|
547
|
+
if (done === "fixing") return answer(409, { message: `A fix is running on ${ref}. Change it once the fix is done.` });
|
|
548
|
+
boardTold(db, told);
|
|
549
|
+
return answer(200, { ref });
|
|
550
|
+
}
|
|
551
|
+
var Refused = class extends Error {
|
|
552
|
+
status;
|
|
553
|
+
constructor(status, message) {
|
|
554
|
+
super(message);
|
|
555
|
+
this.status = status;
|
|
556
|
+
}
|
|
557
|
+
};
|
|
558
|
+
function pullLink(link) {
|
|
559
|
+
const ref = pullRequestRef(typeof link === "string" ? link : "");
|
|
560
|
+
if ("refused" in ref) throw new Refused(400, ref.refused);
|
|
561
|
+
return {
|
|
562
|
+
owner: ref.owner,
|
|
563
|
+
repo: ref.repo,
|
|
564
|
+
number: ref.number,
|
|
565
|
+
full: ref.name
|
|
566
|
+
};
|
|
567
|
+
}
|
|
568
|
+
var refusedAnswer = (error) => answer(error instanceof Refused ? error.status : 409, { message: error.message });
|
|
569
|
+
/**
|
|
570
|
+
* Attaches a pull request a person names to a Delivery card, beside the ones its branch finds. It is
|
|
571
|
+
* read from GitHub before anything is stored, a GraphQL query and never a write, so a pull request that
|
|
572
|
+
* is not there or not readable leaves the card as it was.
|
|
573
|
+
*/
|
|
574
|
+
async function attachPull(db, key, link, run, signal) {
|
|
575
|
+
if (boardOfCard(db, key) !== "delivery") throw new Error(`${key} is not a Delivery card, so no pull request can be attached to it.`);
|
|
576
|
+
const { stage } = db.prepare("SELECT stage FROM cards WHERE key = ?").get(key);
|
|
577
|
+
if (!tabsFor("delivery", stage, cardPullRows(db, key).length > 0).some((tab) => tab.id === "prs")) throw new Error(`${key} has not reached Pull request yet, so no pull request can be attached to it.`);
|
|
578
|
+
const ref = pullLink(link);
|
|
579
|
+
if (cardPullRows(db, key).some((one) => one.repo === `${ref.owner}/${ref.repo}`.toLowerCase() && one.number === ref.number)) throw new Error(`${ref.full} is on ${key} already.`);
|
|
580
|
+
const found = await getPull(run, ref, signal);
|
|
581
|
+
if (found.pull === null) throw new Error(found.notFound ? `GitHub has no pull request ${ref.full}. The number may belong to an issue, the pull request may be gone, or this login may not open that repository.` : `${ref.full} could not be read from GitHub. The call failed, so the pull request may still be there. Try again.`);
|
|
582
|
+
saveCardPull(db, key, {
|
|
583
|
+
repo: `${ref.owner}/${ref.repo}`,
|
|
584
|
+
number: ref.number,
|
|
585
|
+
url: found.pull.url,
|
|
586
|
+
foundBy: "attached",
|
|
587
|
+
title: found.pull.title,
|
|
588
|
+
state: found.pull.state
|
|
589
|
+
});
|
|
590
|
+
return cardPullRows(db, key);
|
|
591
|
+
}
|
|
592
|
+
/** Takes an attached pull request off a card, with its discussions and messages. */
|
|
593
|
+
function detachPull(db, key, link) {
|
|
594
|
+
const ref = pullLink(link);
|
|
595
|
+
const done = detachCardPull(db, key, `${ref.owner}/${ref.repo}`, ref.number);
|
|
596
|
+
if (done === "branch") throw new Error(`${ref.full} was found by the card's branch, so it would come back on the next read. Only a pull request you attached can be detached.`);
|
|
597
|
+
if (done === "fixing") throw new Error(`A fix is running on a comment of ${ref.full}. Detach it once the fix is done.`);
|
|
598
|
+
if (done === "missing") throw new Error(`${ref.full} is not on ${key}.`);
|
|
599
|
+
return cardPullRows(db, key);
|
|
600
|
+
}
|
|
601
|
+
async function postPullLink(db, key, body, run = ghRunner()) {
|
|
602
|
+
try {
|
|
603
|
+
return answer(200, { pulls: await attachPull(db, key, body?.link, run, AbortSignal.timeout(READ_TIMEOUT_MS)) });
|
|
604
|
+
} catch (error) {
|
|
605
|
+
return refusedAnswer(error);
|
|
606
|
+
}
|
|
607
|
+
}
|
|
608
|
+
function deletePullLink(db, key, body, told) {
|
|
609
|
+
try {
|
|
610
|
+
const pulls = detachPull(db, key, body?.link);
|
|
611
|
+
boardTold(db, told);
|
|
612
|
+
return answer(200, { pulls });
|
|
613
|
+
} catch (error) {
|
|
614
|
+
return refusedAnswer(error);
|
|
615
|
+
}
|
|
616
|
+
}
|
|
617
|
+
var searchUrl = (ask) => `https://github.com/${ask.owner}/${ask.repo}/pulls?q=${encodeURIComponent(`is:pr head:${ask.branch}`)}`;
|
|
618
|
+
/**
|
|
619
|
+
* The pull request state of a closed card, read through gh each time the card page asks, and written
|
|
620
|
+
* nowhere. A gh that is missing, logged out or not answering keeps the links and claims no state, and
|
|
621
|
+
* `said` names why. A repository with no pull request from the branch is named in `said` too.
|
|
622
|
+
*/
|
|
623
|
+
async function cardPulls(db, key, run, signal) {
|
|
624
|
+
const project = getSetting(db, "projectPath");
|
|
625
|
+
if (project === null) return {
|
|
626
|
+
pulls: [],
|
|
627
|
+
said: null
|
|
628
|
+
};
|
|
629
|
+
let asks;
|
|
630
|
+
try {
|
|
631
|
+
asks = await branchAsks(db, project, key, gitEnv(process.env));
|
|
632
|
+
} catch (error) {
|
|
633
|
+
return {
|
|
634
|
+
pulls: [],
|
|
635
|
+
said: error.message
|
|
636
|
+
};
|
|
637
|
+
}
|
|
638
|
+
if (asks.length === 0) return {
|
|
639
|
+
pulls: [],
|
|
640
|
+
said: null
|
|
641
|
+
};
|
|
642
|
+
const unread = (ask) => ({
|
|
643
|
+
repo: `${ask.owner}/${ask.repo}`,
|
|
644
|
+
branch: ask.branch,
|
|
645
|
+
number: null,
|
|
646
|
+
url: searchUrl(ask),
|
|
647
|
+
state: null
|
|
648
|
+
});
|
|
649
|
+
let found;
|
|
650
|
+
try {
|
|
651
|
+
found = await findBranchPulls(run, asks, signal);
|
|
652
|
+
} catch (error) {
|
|
653
|
+
return {
|
|
654
|
+
pulls: asks.map(unread),
|
|
655
|
+
said: error.message
|
|
656
|
+
};
|
|
657
|
+
}
|
|
658
|
+
const pulls = [];
|
|
659
|
+
const notes = [];
|
|
660
|
+
for (const [at, ask] of asks.entries()) {
|
|
661
|
+
const one = found[at];
|
|
662
|
+
if (one?.read !== true) {
|
|
663
|
+
pulls.push(unread(ask));
|
|
664
|
+
notes.push(`GitHub did not answer for ${ask.owner}/${ask.repo}. The repository may be gone, or this login cannot open it.`);
|
|
665
|
+
} else if (one.pull === null) notes.push(`${ask.owner}/${ask.repo} has no pull request from ${ask.branch}.`);
|
|
666
|
+
else {
|
|
667
|
+
const pull = one.pull;
|
|
668
|
+
pulls.push({
|
|
669
|
+
repo: `${ask.owner}/${ask.repo}`,
|
|
670
|
+
branch: ask.branch,
|
|
671
|
+
number: pull.number,
|
|
672
|
+
url: pull.url ?? searchUrl(ask),
|
|
673
|
+
state: pull.state,
|
|
674
|
+
...pull.mergedBy === void 0 ? {} : { mergedBy: pull.mergedBy === one.viewer ? "you" : pull.mergedBy },
|
|
675
|
+
...pull.mergedAt === void 0 ? {} : { mergedAt: pull.mergedAt },
|
|
676
|
+
...pull.createdAt === void 0 ? {} : { openedAt: pull.createdAt },
|
|
677
|
+
...pull.additions === void 0 ? {} : { additions: pull.additions },
|
|
678
|
+
...pull.deletions === void 0 ? {} : { deletions: pull.deletions },
|
|
679
|
+
...pull.changedFiles === void 0 ? {} : { files: pull.changedFiles },
|
|
680
|
+
...pull.baseRef === void 0 ? {} : { base: pull.baseRef }
|
|
681
|
+
});
|
|
682
|
+
}
|
|
683
|
+
}
|
|
684
|
+
return {
|
|
685
|
+
pulls,
|
|
686
|
+
said: notes.length === 0 ? null : notes.join(" ")
|
|
687
|
+
};
|
|
688
|
+
}
|
|
689
|
+
|
|
690
|
+
export { postPullRefresh as a, postCardDiscussions as b, cardPulls as c, patchDiscussion as d, deletePullLink as e, postPullLink as f, postDiscussionsSeen as g, linkOpenPulls as l, postDeliveryPulls as p, unlinkedCards as u };
|
|
691
|
+
//# sourceMappingURL=pull-list.js-BCIBJdyz.js.map
|