@inkeep/open-knowledge 0.30.0 → 0.30.1-beta.1

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.
Files changed (82) hide show
  1. package/dist/assets/skills/discovery/SKILL.md +1 -1
  2. package/dist/assets/skills/project/SKILL.md +1 -1
  3. package/dist/assets/skills/write-skill/SKILL.md +1 -1
  4. package/dist/cli.mjs +66 -66
  5. package/dist/constants-Dna0AK_L.mjs +2 -0
  6. package/dist/{dist-Dv1J08lw.mjs → dist-BXlA66Rv.mjs} +15 -13
  7. package/dist/dist-MZRC45Vk.mjs +1 -0
  8. package/dist/{gh-detect-BMbpd_Yj.mjs → gh-detect-BAop1ZEi.mjs} +2 -2
  9. package/dist/index.mjs +1 -1
  10. package/dist/init-DeoV6_ch.mjs +1 -0
  11. package/dist/{init-CiE61hR0.mjs → init-DwesVWyB.mjs} +3 -3
  12. package/dist/{launch-json-removal-Dq7MQJaK.mjs → launch-json-removal-wOi7iCjC.mjs} +2 -2
  13. package/dist/{loader-CU9plu3Y.mjs → loader-DPFCFSlV.mjs} +3 -3
  14. package/dist/loader-rXR2Ghgh.mjs +1 -0
  15. package/dist/{open-browser-B0EHWyOL.mjs → open-browser-c8D-FzSc.mjs} +2 -2
  16. package/dist/{preview-hK8GmB4J.mjs → preview-B5glRlyK.mjs} +2 -2
  17. package/dist/preview-Ol2--0Od.mjs +1 -0
  18. package/dist/public/assets/{ActivityModeContent-C0_GSBuC.js → ActivityModeContent-BmNXHtkV.js} +1 -1
  19. package/dist/public/assets/CodeMirrorPropInput-Cqy5AMG8.js +3 -0
  20. package/dist/public/assets/DocumentContext-TfAt4kJ2.js +35 -0
  21. package/dist/public/assets/{EnableSyncConfirmDialog-BhwhYBFL.js → EnableSyncConfirmDialog-CWfJC2tV.js} +1 -1
  22. package/dist/public/assets/{GraphPanel-ByzLo6-b.js → GraphPanel-64dKrEeN.js} +1 -1
  23. package/dist/public/assets/{ManagedArtifactProperties-DAzdDsOt.js → ManagedArtifactProperties-CdDmcobU.js} +1 -1
  24. package/dist/public/assets/{McpConsentDialogBody-BwDo5LSJ.js → McpConsentDialogBody-CBhFj_dO.js} +1 -1
  25. package/dist/public/assets/{MermaidDocEditor-BpnOw4CA.js → MermaidDocEditor-DHYDIKqN.js} +1 -1
  26. package/dist/public/assets/{PropertyPanel-B3wmhQBT.js → PropertyPanel-zzS00_gE.js} +1 -1
  27. package/dist/public/assets/SettingsDialogBody-BmmrykCe.js +7 -0
  28. package/dist/public/assets/{ShareBranchSwitchDialog-i35Gg8js.js → ShareBranchSwitchDialog-BlhZ6hTx.js} +1 -1
  29. package/dist/public/assets/{ShareReceiveDialog-LrK6Us6O.js → ShareReceiveDialog-L3wJj8ez.js} +1 -1
  30. package/dist/public/assets/{ShareReceiveMissDialog-CEV0ExUm.js → ShareReceiveMissDialog-D6rKf26E.js} +1 -1
  31. package/dist/public/assets/{SkillEditorActions-BoEoI6NN.js → SkillEditorActions-DAfDDMK2.js} +1 -1
  32. package/dist/public/assets/SourceEditor-CEgPDQLe.js +1 -0
  33. package/dist/public/assets/{TerminalPanel-Di7sR9_K.js → TerminalPanel-CFfN7G5Q.js} +1 -1
  34. package/dist/public/assets/{agent-presence-DOgDiPgh.js → agent-presence-DiQ_l3Q4.js} +1 -1
  35. package/dist/public/assets/{auth-state-cache-CZRVpVW6.js → auth-state-cache-BqN1GQly.js} +1 -1
  36. package/dist/public/assets/{config-provider-BnOnKhga.js → config-provider-DON2sTkv.js} +2 -2
  37. package/dist/public/assets/{dist-xdRBzARh.js → dist-CUDp0fN-.js} +2 -2
  38. package/dist/public/assets/{dist-D7PDymSy.js → dist-cAytzZ0r.js} +101 -95
  39. package/dist/public/assets/{doc-hash-i5oNLfum.js → doc-hash-KGQoVCvb.js} +1 -1
  40. package/dist/public/assets/{documents-events-D26lhbOZ.js → documents-events-BnMDLvDB.js} +1 -1
  41. package/dist/public/assets/{file-tree-adapter-N1FVhfKw.js → file-tree-adapter-uHXxUJ8g.js} +1 -1
  42. package/dist/public/assets/{index-KSKNKDpJ.js → index-CeH_SKGP.js} +15 -15
  43. package/dist/public/assets/{keyboard-shortcuts-Bgozgsx2.js → keyboard-shortcuts-bJc2PBGE.js} +1 -1
  44. package/dist/public/assets/{navigation-targets-D_wZddL9.js → navigation-targets-DdhO6GKu.js} +1 -1
  45. package/dist/public/assets/{open-managed-artifact-tab-kOn8WHrp.js → open-managed-artifact-tab-qxJ9p8Vi.js} +1 -1
  46. package/dist/public/assets/{pending-receive-nav-store-CDyGvnwD.js → pending-receive-nav-store-v67LB7tS.js} +1 -1
  47. package/dist/public/assets/{prop-types-BK5m4zFC.js → prop-types-Dkcm5cUg.js} +1 -1
  48. package/dist/public/assets/{receive-store-Jc3PEGIh.js → receive-store-CtqQYghY.js} +1 -1
  49. package/dist/public/assets/selection-context-CowvMKTL.js +4 -0
  50. package/dist/public/assets/{skill-actions-CeU8Dbpm.js → skill-actions-HpoN1bS5.js} +1 -1
  51. package/dist/public/assets/{skills-api-k47WvkqQ.js → skills-api-Dg6gQ9CV.js} +1 -1
  52. package/dist/public/assets/{src-B6vksAtW.js → src-BYPkKUxg.js} +1 -1
  53. package/dist/public/assets/{target-navigation-intent-DEwTup1R.js → target-navigation-intent-DhT4boi_.js} +1 -1
  54. package/dist/public/assets/{telemetry-impl-CSONG7_p.js → telemetry-impl-DGG3JG6S.js} +1 -1
  55. package/dist/public/assets/{telemetry-startup-BK7tF5N1.js → telemetry-startup-DxsH0f-U.js} +1 -1
  56. package/dist/public/assets/{typing-burst-detector-BC1YUpwK.js → typing-burst-detector-PdfZQie3.js} +2 -2
  57. package/dist/public/assets/{workspace-paths-D4weWrbA.js → workspace-paths-DYS2c17l.js} +1 -1
  58. package/dist/public/index.html +25 -25
  59. package/dist/{repair-launch-json-szAhAk7h.mjs → repair-launch-json-D9Enw9jp.mjs} +2 -2
  60. package/dist/{repair-mcp-configs-DOFA0U7b.mjs → repair-mcp-configs-BkLxipkW.mjs} +2 -2
  61. package/dist/repair-skills-BAEDb9Ho.mjs +1 -0
  62. package/dist/{repair-skills-B0R_QUCx.mjs → repair-skills-BwUGllKc.mjs} +2 -2
  63. package/dist/server-lock-GuuouVft-uqSUkxXo.mjs +1 -0
  64. package/dist/{server-lock-iLcBw_q0-DB1Ahu2b.mjs → server-lock-iLcBw_q0-WEyo7ukm.mjs} +111 -104
  65. package/dist/{src-5A7WMaZM.mjs → src-CQgIysi4.mjs} +2 -2
  66. package/dist/{start-BYisI2iR.mjs → start-BB5Q_CLQ.mjs} +2 -2
  67. package/dist/start-Bll_YyDb.mjs +1 -0
  68. package/dist/{write-project-skill-B5fSGkbt.mjs → write-project-skill-dxucK8PX.mjs} +2 -2
  69. package/package.json +1 -1
  70. package/dist/constants-CpHqANcZ.mjs +0 -2
  71. package/dist/dist-DV45zaO6.mjs +0 -1
  72. package/dist/init-H9qpwnHQ.mjs +0 -1
  73. package/dist/loader-fm_JJ54p.mjs +0 -1
  74. package/dist/preview-B8DOkQQi.mjs +0 -1
  75. package/dist/public/assets/CodeMirrorPropInput-C2VECyjO.js +0 -3
  76. package/dist/public/assets/DocumentContext-f6XQqg_y.js +0 -35
  77. package/dist/public/assets/SettingsDialogBody-DVvKGL9J.js +0 -7
  78. package/dist/public/assets/SourceEditor-DuPpY_T6.js +0 -1
  79. package/dist/public/assets/selection-context-72mLve4s.js +0 -4
  80. package/dist/repair-skills-CS0_a3yn.mjs +0 -1
  81. package/dist/server-lock-GuuouVft-CXM0Fdz7.mjs +0 -1
  82. package/dist/start-DZBjiXoP.mjs +0 -1
@@ -1 +1 @@
1
- import{o as e}from"./chunk-CFjPhJqf.js";import{n as t}from"./compiler-runtime-CVnuRdak.js";import{r as n}from"./dist-CQw2y-s3.js";import{fn as r}from"./dist-D7PDymSy.js";import{u as i}from"./button-cneJOVxD.js";var a=i(`copy-plus`,[[`line`,{x1:`15`,x2:`15`,y1:`12`,y2:`18`,key:`1p7wdc`}],[`line`,{x1:`12`,x2:`18`,y1:`15`,y2:`15`,key:`1nscbv`}],[`rect`,{width:`14`,height:`14`,x:`8`,y:`8`,rx:`2`,ry:`2`,key:`17jyea`}],[`path`,{d:`M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2`,key:`zix9uf`}]]),o=i(`copy`,[[`rect`,{width:`14`,height:`14`,x:`8`,y:`8`,rx:`2`,ry:`2`,key:`17jyea`}],[`path`,{d:`M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2`,key:`zix9uf`}]]),s=i(`pencil`,[[`path`,{d:`M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z`,key:`1a8usu`}],[`path`,{d:`m15 5 4 4`,key:`1mk7zo`}]]),c=i(`sparkles`,[[`path`,{d:`M11.017 2.814a1 1 0 0 1 1.966 0l1.051 5.558a2 2 0 0 0 1.594 1.594l5.558 1.051a1 1 0 0 1 0 1.966l-5.558 1.051a2 2 0 0 0-1.594 1.594l-1.051 5.558a1 1 0 0 1-1.966 0l-1.051-5.558a2 2 0 0 0-1.594-1.594l-5.558-1.051a1 1 0 0 1 0-1.966l5.558-1.051a2 2 0 0 0 1.594-1.594z`,key:`1s2grr`}],[`path`,{d:`M20 2v4`,key:`1rf3ol`}],[`path`,{d:`M22 4h-4`,key:`gwowj6`}],[`circle`,{cx:`4`,cy:`20`,r:`2`,key:`6kqj1y`}]]),l=[`global`,`project`];function u(e){return{project:new Set(e.filter(e=>e.scope===`project`).map(e=>e.name)),global:new Set(e.filter(e=>e.scope===`global`).map(e=>e.name))}}var d=`open-knowledge-pack-`;function f(e){return e.startsWith(d)?e.slice(20):e}function p(){let{_:e}=n();return{project:e({id:`e0NrBM`}),global:e({id:`2GT3Hf`})}}function m(){let{_:e}=n();return{project:e({id:`HyvSqq`}),global:e({id:`C7XjNB`})}}var h=e(t(),1);function g(){let[e]=(0,h.useState)(_);return e}function _(){return r()!=null}function v(e,t,n){let r=n===`\\`?t.replaceAll(`/`,`\\`):t;return`${e.endsWith(n)?e.slice(0,-1):e}${n}${r}`}var y=/\.(md|mdx)$/i;function b(e){return y.test(e)?e:`${e}.md`}export{f as a,m as c,o as d,a as f,l as i,c as l,v as n,u as o,g as r,p as s,b as t,s as u};
1
+ import{o as e}from"./chunk-CFjPhJqf.js";import{n as t}from"./compiler-runtime-CVnuRdak.js";import{r as n}from"./dist-CQw2y-s3.js";import{fn as r}from"./dist-cAytzZ0r.js";import{u as i}from"./button-cneJOVxD.js";var a=i(`copy-plus`,[[`line`,{x1:`15`,x2:`15`,y1:`12`,y2:`18`,key:`1p7wdc`}],[`line`,{x1:`12`,x2:`18`,y1:`15`,y2:`15`,key:`1nscbv`}],[`rect`,{width:`14`,height:`14`,x:`8`,y:`8`,rx:`2`,ry:`2`,key:`17jyea`}],[`path`,{d:`M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2`,key:`zix9uf`}]]),o=i(`copy`,[[`rect`,{width:`14`,height:`14`,x:`8`,y:`8`,rx:`2`,ry:`2`,key:`17jyea`}],[`path`,{d:`M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2`,key:`zix9uf`}]]),s=i(`pencil`,[[`path`,{d:`M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z`,key:`1a8usu`}],[`path`,{d:`m15 5 4 4`,key:`1mk7zo`}]]),c=i(`sparkles`,[[`path`,{d:`M11.017 2.814a1 1 0 0 1 1.966 0l1.051 5.558a2 2 0 0 0 1.594 1.594l5.558 1.051a1 1 0 0 1 0 1.966l-5.558 1.051a2 2 0 0 0-1.594 1.594l-1.051 5.558a1 1 0 0 1-1.966 0l-1.051-5.558a2 2 0 0 0-1.594-1.594l-5.558-1.051a1 1 0 0 1 0-1.966l5.558-1.051a2 2 0 0 0 1.594-1.594z`,key:`1s2grr`}],[`path`,{d:`M20 2v4`,key:`1rf3ol`}],[`path`,{d:`M22 4h-4`,key:`gwowj6`}],[`circle`,{cx:`4`,cy:`20`,r:`2`,key:`6kqj1y`}]]),l=[`global`,`project`];function u(e){return{project:new Set(e.filter(e=>e.scope===`project`).map(e=>e.name)),global:new Set(e.filter(e=>e.scope===`global`).map(e=>e.name))}}var d=`open-knowledge-pack-`;function f(e){return e.startsWith(d)?e.slice(20):e}function p(){let{_:e}=n();return{project:e({id:`e0NrBM`}),global:e({id:`2GT3Hf`})}}function m(){let{_:e}=n();return{project:e({id:`HyvSqq`}),global:e({id:`C7XjNB`})}}var h=e(t(),1);function g(){let[e]=(0,h.useState)(_);return e}function _(){return r()!=null}function v(e,t,n){let r=n===`\\`?t.replaceAll(`/`,`\\`):t;return`${e.endsWith(n)?e.slice(0,-1):e}${n}${r}`}var y=/\.(md|mdx)$/i;function b(e){return y.test(e)?e:`${e}.md`}export{f as a,m as c,o as d,a as f,l as i,c as l,v as n,u as o,g as r,p as s,b as t,s as u};
@@ -48,7 +48,7 @@
48
48
  -->
49
49
  <script>(() => { let t = 'system'; try { const r = localStorage.getItem('ok-theme-v1'); if (r === 'light' || r === 'dark' || r === 'system') t = r; } catch {} let dark = t === 'dark'; if (t === 'system') { try { dark = window.matchMedia('(prefers-color-scheme: dark)').matches; } catch {} } if (dark) document.documentElement.classList.add('dark'); if (window.okDesktop) document.documentElement.classList.add('electron-mode'); })();</script>
50
50
  <style>html { background-color: #fafafa } html.dark { background-color: #171717 }</style>
51
- <script type="module" crossorigin src="./assets/index-KSKNKDpJ.js"></script>
51
+ <script type="module" crossorigin src="./assets/index-CeH_SKGP.js"></script>
52
52
  <link rel="modulepreload" crossorigin href="./assets/chunk-CFjPhJqf.js">
53
53
  <link rel="modulepreload" crossorigin href="./assets/preload-helper-2ej06EnG.js">
54
54
  <link rel="modulepreload" crossorigin href="./assets/w3c-keyname-CHcJEDvG.js">
@@ -64,11 +64,11 @@
64
64
  <link rel="modulepreload" crossorigin href="./assets/stex-4t0JIuX_.js">
65
65
  <link rel="modulepreload" crossorigin href="./assets/floating-ui.dom-DVRWCLii.js">
66
66
  <link rel="modulepreload" crossorigin href="./assets/trace-api-D6fqC5Nw.js">
67
- <link rel="modulepreload" crossorigin href="./assets/dist-D7PDymSy.js">
67
+ <link rel="modulepreload" crossorigin href="./assets/dist-cAytzZ0r.js">
68
68
  <link rel="modulepreload" crossorigin href="./assets/compiler-runtime-CVnuRdak.js">
69
69
  <link rel="modulepreload" crossorigin href="./assets/dist-BVOt51sU.js">
70
70
  <link rel="modulepreload" crossorigin href="./assets/config-context-CE3SCVYc.js">
71
- <link rel="modulepreload" crossorigin href="./assets/config-provider-BnOnKhga.js">
71
+ <link rel="modulepreload" crossorigin href="./assets/config-provider-DON2sTkv.js">
72
72
  <link rel="modulepreload" crossorigin href="./assets/dist-BvBijIC5.js">
73
73
  <link rel="modulepreload" crossorigin href="./assets/dist-CQw2y-s3.js">
74
74
  <link rel="modulepreload" crossorigin href="./assets/button-cneJOVxD.js">
@@ -76,14 +76,14 @@
76
76
  <link rel="modulepreload" crossorigin href="./assets/trash-2-Dcpo0Di-.js">
77
77
  <link rel="modulepreload" crossorigin href="./assets/triangle-alert-c3yCucJv.js">
78
78
  <link rel="modulepreload" crossorigin href="./assets/react-dom-C-oc-P2K.js">
79
- <link rel="modulepreload" crossorigin href="./assets/doc-hash-i5oNLfum.js">
80
- <link rel="modulepreload" crossorigin href="./assets/navigation-targets-D_wZddL9.js">
79
+ <link rel="modulepreload" crossorigin href="./assets/doc-hash-KGQoVCvb.js">
80
+ <link rel="modulepreload" crossorigin href="./assets/navigation-targets-DdhO6GKu.js">
81
81
  <link rel="modulepreload" crossorigin href="./assets/documents-fetch-oup83IZh.js">
82
- <link rel="modulepreload" crossorigin href="./assets/CodeMirrorPropInput-C2VECyjO.js">
83
- <link rel="modulepreload" crossorigin href="./assets/dist-xdRBzARh.js">
84
- <link rel="modulepreload" crossorigin href="./assets/documents-events-D26lhbOZ.js">
82
+ <link rel="modulepreload" crossorigin href="./assets/CodeMirrorPropInput-Cqy5AMG8.js">
83
+ <link rel="modulepreload" crossorigin href="./assets/dist-CUDp0fN-.js">
84
+ <link rel="modulepreload" crossorigin href="./assets/documents-events-BnMDLvDB.js">
85
85
  <link rel="modulepreload" crossorigin href="./assets/parse-api-error-CqtA8BcL.js">
86
- <link rel="modulepreload" crossorigin href="./assets/open-managed-artifact-tab-kOn8WHrp.js">
86
+ <link rel="modulepreload" crossorigin href="./assets/open-managed-artifact-tab-qxJ9p8Vi.js">
87
87
  <link rel="modulepreload" crossorigin href="./assets/dist-BSkHa6UR.js">
88
88
  <link rel="modulepreload" crossorigin href="./assets/dist-fpPv-rVb.js">
89
89
  <link rel="modulepreload" crossorigin href="./assets/propagation-api-BHhJitgG.js">
@@ -97,44 +97,44 @@
97
97
  <link rel="modulepreload" crossorigin href="./assets/chevron-down-BvNcCN1f.js">
98
98
  <link rel="modulepreload" crossorigin href="./assets/chevron-right-DSNnH-Vb.js">
99
99
  <link rel="modulepreload" crossorigin href="./assets/startup-marks-DDtA9pbt.js">
100
- <link rel="modulepreload" crossorigin href="./assets/prop-types-BK5m4zFC.js">
101
- <link rel="modulepreload" crossorigin href="./assets/workspace-paths-D4weWrbA.js">
100
+ <link rel="modulepreload" crossorigin href="./assets/prop-types-Dkcm5cUg.js">
101
+ <link rel="modulepreload" crossorigin href="./assets/workspace-paths-DYS2c17l.js">
102
102
  <link rel="modulepreload" crossorigin href="./assets/eye-WB1l5kVb.js">
103
103
  <link rel="modulepreload" crossorigin href="./assets/git-branch-q0qWPEwd.js">
104
104
  <link rel="modulepreload" crossorigin href="./assets/info-BlYnsVoP.js">
105
105
  <link rel="modulepreload" crossorigin href="./assets/loader-circle-B7Gv_Djz.js">
106
106
  <link rel="modulepreload" crossorigin href="./assets/file-tree-rename-validation-DeKIxKnc.js">
107
107
  <link rel="modulepreload" crossorigin href="./assets/input-tW78aNaR.js">
108
- <link rel="modulepreload" crossorigin href="./assets/DocumentContext-f6XQqg_y.js">
108
+ <link rel="modulepreload" crossorigin href="./assets/DocumentContext-TfAt4kJ2.js">
109
109
  <link rel="modulepreload" crossorigin href="./assets/checkbox-DurEHAAx.js">
110
110
  <link rel="modulepreload" crossorigin href="./assets/dist-CyYz03up.js">
111
- <link rel="modulepreload" crossorigin href="./assets/skills-api-k47WvkqQ.js">
111
+ <link rel="modulepreload" crossorigin href="./assets/skills-api-Dg6gQ9CV.js">
112
112
  <link rel="modulepreload" crossorigin href="./assets/label-DPn_C7ZD.js">
113
113
  <link rel="modulepreload" crossorigin href="./assets/radio-group-B0RG5um-.js">
114
- <link rel="modulepreload" crossorigin href="./assets/EnableSyncConfirmDialog-BhwhYBFL.js">
114
+ <link rel="modulepreload" crossorigin href="./assets/EnableSyncConfirmDialog-CWfJC2tV.js">
115
115
  <link rel="modulepreload" crossorigin href="./assets/arrow-up-right-Crm0Btez.js">
116
116
  <link rel="modulepreload" crossorigin href="./assets/refresh-cw-CluaccKu.js">
117
117
  <link rel="modulepreload" crossorigin href="./assets/cursor-CjNH7VrK.js">
118
- <link rel="modulepreload" crossorigin href="./assets/skill-actions-CeU8Dbpm.js">
118
+ <link rel="modulepreload" crossorigin href="./assets/skill-actions-HpoN1bS5.js">
119
119
  <link rel="modulepreload" crossorigin href="./assets/textarea-DtAQz2_P.js">
120
120
  <link rel="modulepreload" crossorigin href="./assets/external-link-BjECE2gH.js">
121
- <link rel="modulepreload" crossorigin href="./assets/keyboard-shortcuts-Bgozgsx2.js">
122
- <link rel="modulepreload" crossorigin href="./assets/auth-state-cache-CZRVpVW6.js">
121
+ <link rel="modulepreload" crossorigin href="./assets/keyboard-shortcuts-bJc2PBGE.js">
122
+ <link rel="modulepreload" crossorigin href="./assets/auth-state-cache-BqN1GQly.js">
123
123
  <link rel="modulepreload" crossorigin href="./assets/toggle-group-CXHn0FKi.js">
124
124
  <link rel="modulepreload" crossorigin href="./assets/panel-BH2RZRZQ.js">
125
125
  <link rel="modulepreload" crossorigin href="./assets/format-EMqSStmm.js">
126
- <link rel="modulepreload" crossorigin href="./assets/selection-context-72mLve4s.js">
127
- <link rel="modulepreload" crossorigin href="./assets/PropertyPanel-B3wmhQBT.js">
126
+ <link rel="modulepreload" crossorigin href="./assets/selection-context-CowvMKTL.js">
127
+ <link rel="modulepreload" crossorigin href="./assets/PropertyPanel-zzS00_gE.js">
128
128
  <link rel="modulepreload" crossorigin href="./assets/miss-dialog-store-PJQ_kr0I.js">
129
- <link rel="modulepreload" crossorigin href="./assets/pending-receive-nav-store-CDyGvnwD.js">
129
+ <link rel="modulepreload" crossorigin href="./assets/pending-receive-nav-store-v67LB7tS.js">
130
130
  <link rel="modulepreload" crossorigin href="./assets/chevron-left-BEP8MhU3.js">
131
- <link rel="modulepreload" crossorigin href="./assets/agent-presence-DOgDiPgh.js">
132
- <link rel="modulepreload" crossorigin href="./assets/typing-burst-detector-BC1YUpwK.js">
131
+ <link rel="modulepreload" crossorigin href="./assets/agent-presence-DiQ_l3Q4.js">
132
+ <link rel="modulepreload" crossorigin href="./assets/typing-burst-detector-PdfZQie3.js">
133
133
  <link rel="modulepreload" crossorigin href="./assets/project-paths-Bdm7wr4i.js">
134
- <link rel="modulepreload" crossorigin href="./assets/file-tree-adapter-N1FVhfKw.js">
135
- <link rel="modulepreload" crossorigin href="./assets/target-navigation-intent-DEwTup1R.js">
134
+ <link rel="modulepreload" crossorigin href="./assets/file-tree-adapter-uHXxUJ8g.js">
135
+ <link rel="modulepreload" crossorigin href="./assets/target-navigation-intent-DhT4boi_.js">
136
136
  <link rel="modulepreload" crossorigin href="./assets/mcp-consent-store-BxRtlIhJ.js">
137
- <link rel="modulepreload" crossorigin href="./assets/receive-store-Jc3PEGIh.js">
137
+ <link rel="modulepreload" crossorigin href="./assets/receive-store-CtqQYghY.js">
138
138
  <link rel="stylesheet" crossorigin href="./assets/DocumentContext-B0sQn39F.css">
139
139
  <link rel="stylesheet" crossorigin href="./assets/index-Ba1S3D-p.css">
140
140
  </head>
@@ -1,2 +1,2 @@
1
- import{t as e}from"./launch-json-removal-Dq7MQJaK.mjs";import{join as t}from"node:path";function n(n){let i=n.logger??r,a=t(n.projectDir,`.claude`,`launch.json`);if(n.reclaimDisableEnv===`1`)return i({event:`launch-json-repair-skipped`,reason:`reclaim-disabled`}),{outcome:{configPath:a,outcome:`skipped-reclaim-disabled`},repairedCount:0};let o;try{o=e(n.projectDir)}catch(e){let t=e instanceof Error?e.message:String(e);return i({event:`launch-json-repair-write-failed`,configPath:a}),{outcome:{configPath:a,outcome:`write-failed`,error:t},repairedCount:0}}let s=o.kind===`removed`||o.kind===`removed-file`;return s&&i({event:`launch-json-repair-removed`,configPath:a}),{outcome:{configPath:a,outcome:o.kind},repairedCount:s?1:0}}function r(e){process.stderr.write(`${JSON.stringify(e)}\n`)}export{n as repairLaunchJson};
2
- //# sourceMappingURL=repair-launch-json-szAhAk7h.mjs.map
1
+ import{t as e}from"./launch-json-removal-wOi7iCjC.mjs";import{join as t}from"node:path";function n(n){let i=n.logger??r,a=t(n.projectDir,`.claude`,`launch.json`);if(n.reclaimDisableEnv===`1`)return i({event:`launch-json-repair-skipped`,reason:`reclaim-disabled`}),{outcome:{configPath:a,outcome:`skipped-reclaim-disabled`},repairedCount:0};let o;try{o=e(n.projectDir)}catch(e){let t=e instanceof Error?e.message:String(e);return i({event:`launch-json-repair-write-failed`,configPath:a}),{outcome:{configPath:a,outcome:`write-failed`,error:t},repairedCount:0}}let s=o.kind===`removed`||o.kind===`removed-file`;return s&&i({event:`launch-json-repair-removed`,configPath:a}),{outcome:{configPath:a,outcome:o.kind},repairedCount:s?1:0}}function r(e){process.stderr.write(`${JSON.stringify(e)}\n`)}export{n as repairLaunchJson};
2
+ //# sourceMappingURL=repair-launch-json-D9Enw9jp.mjs.map
@@ -1,2 +1,2 @@
1
- import{d as e,v as t}from"./init-CiE61hR0.mjs";import{_ as n,d as r,s as i}from"./write-project-skill-B5fSGkbt.mjs";import{t as a}from"./mcp-migrate-event-CyH1VVyy.mjs";import{homedir as o}from"node:os";function s(e){let t=e.logger??u,n=e.home??o(),a=[];if(e.reclaimDisableEnv===`1`)return t({event:`mcp-config-repair-skipped`,reason:`reclaim-disabled`}),{outcomes:a,repairedCount:0};for(let o of i){let i=r[o],s=c(()=>i.configPath(``,n));if(s!==null&&a.push(l({scope:`user`,editorId:o,target:i,home:n,cwd:``,configPath:s,configPathOverride:void 0,logger:t})),i.projectConfigPath){let n=i.projectConfigPath,r=c(()=>n(e.projectDir));r!==null&&a.push(l({scope:`project`,editorId:o,target:i,home:void 0,cwd:e.projectDir,configPath:r,configPathOverride:r,logger:t}))}}return{outcomes:a,repairedCount:a.filter(e=>e.outcome===`repaired`).length}}function c(e){try{return e()}catch{return null}}function l(r){let i={scope:r.scope,editorId:r.editorId,configPath:r.configPath},o=e(r.target,r.cwd,r.home,r.configPathOverride);if(o===null)return{...i,outcome:`no-entry`};if(n(o))return{...i,outcome:`canonical`};r.logger(a({scope:r.scope,surface:`cli-repair`,editorId:r.editorId,configPath:r.configPath,priorEntry:o}));let s=t(r.target,r.cwd,{mode:`published`,skipAvailabilityCheck:!0},r.home,r.configPathOverride);if(s.action===`failed`){let e=s.error??`unknown write failure`;return r.logger({event:`mcp-config-repair-write-failed`,scope:r.scope,editorId:r.editorId,configPath:r.configPath,error:e}),{...i,outcome:`write-failed`,error:e}}return s.action===`declined`?(r.logger({event:`mcp-config-repair-declined`,scope:r.scope,editorId:r.editorId,configPath:r.configPath,reason:s.declineReason}),{...i,outcome:`declined`}):{...i,outcome:`repaired`}}function u(e){process.stderr.write(`${JSON.stringify(e)}\n`)}export{s as repairMcpConfigs};
2
- //# sourceMappingURL=repair-mcp-configs-DOFA0U7b.mjs.map
1
+ import{d as e,v as t}from"./init-DwesVWyB.mjs";import{_ as n,d as r,s as i}from"./write-project-skill-dxucK8PX.mjs";import{t as a}from"./mcp-migrate-event-CyH1VVyy.mjs";import{homedir as o}from"node:os";function s(e){let t=e.logger??u,n=e.home??o(),a=[];if(e.reclaimDisableEnv===`1`)return t({event:`mcp-config-repair-skipped`,reason:`reclaim-disabled`}),{outcomes:a,repairedCount:0};for(let o of i){let i=r[o],s=c(()=>i.configPath(``,n));if(s!==null&&a.push(l({scope:`user`,editorId:o,target:i,home:n,cwd:``,configPath:s,configPathOverride:void 0,logger:t})),i.projectConfigPath){let n=i.projectConfigPath,r=c(()=>n(e.projectDir));r!==null&&a.push(l({scope:`project`,editorId:o,target:i,home:void 0,cwd:e.projectDir,configPath:r,configPathOverride:r,logger:t}))}}return{outcomes:a,repairedCount:a.filter(e=>e.outcome===`repaired`).length}}function c(e){try{return e()}catch{return null}}function l(r){let i={scope:r.scope,editorId:r.editorId,configPath:r.configPath},o=e(r.target,r.cwd,r.home,r.configPathOverride);if(o===null)return{...i,outcome:`no-entry`};if(n(o))return{...i,outcome:`canonical`};r.logger(a({scope:r.scope,surface:`cli-repair`,editorId:r.editorId,configPath:r.configPath,priorEntry:o}));let s=t(r.target,r.cwd,{mode:`published`,skipAvailabilityCheck:!0},r.home,r.configPathOverride);if(s.action===`failed`){let e=s.error??`unknown write failure`;return r.logger({event:`mcp-config-repair-write-failed`,scope:r.scope,editorId:r.editorId,configPath:r.configPath,error:e}),{...i,outcome:`write-failed`,error:e}}return s.action===`declined`?(r.logger({event:`mcp-config-repair-declined`,scope:r.scope,editorId:r.editorId,configPath:r.configPath,reason:s.declineReason}),{...i,outcome:`declined`}):{...i,outcome:`repaired`}}function u(e){process.stderr.write(`${JSON.stringify(e)}\n`)}export{s as repairMcpConfigs};
2
+ //# sourceMappingURL=repair-mcp-configs-BkLxipkW.mjs.map
@@ -0,0 +1 @@
1
+ import{t as e}from"./repair-skills-BwUGllKc.mjs";export{e as repairSkills};
@@ -1,3 +1,3 @@
1
- import{ua as e}from"./server-lock-iLcBw_q0-DB1Ahu2b.mjs";import{Br as t,Fr as n,Nr as r,Wr as i,Xr as a,d as o,ea as s,ia as c,lt as l}from"./dist-Dv1J08lw.mjs";import{t as u}from"./esm-CsQUg9js.mjs";import{a as d,d as f,f as p,t as m}from"./write-project-skill-B5fSGkbt.mjs";import{dirname as h,join as g,resolve as _}from"node:path";import{homedir as v}from"node:os";import{existsSync as y,mkdirSync as b,readFileSync as x,readdirSync as S,rmSync as C,statSync as w,writeFileSync as T}from"node:fs";const E={existsSync:e=>y(e),isDirectory:e=>{try{return w(e).isDirectory()}catch(e){if(e.code===`ENOENT`)return!1;throw e}},readdirSync:e=>S(e),readFileSync:e=>x(e),writeFileSync:(e,t)=>{T(e,t)},mkdirSync:(e,t)=>{b(e,t)},rmSync:(e,t)=>{C(e,t)}},D={resolveProjectBundledSkillDir:()=>a(`project`,{checkDesktop:!1}),resolveUserBundledSkillDir:e=>a(e,{checkDesktop:!1}),readBundledVersion:()=>n(),readRecordedVersion:e=>t(e,`cli-hosts`),writeRecordedVersion:(e,t)=>c(e,`cli-hosts`,t,`cli-start`),recordEvent:e=>i(e),readBundleDecision:(e,t)=>r(e,t),writeBundleDecision:(e,t,n)=>s(e,t,n),removeBundleFromDisk:(e,t)=>d(e,t)};function O(e){process.stderr.write(`${JSON.stringify(e)}\n`)}function k(e,t,n){n.rmSync(t,{recursive:!0,force:!0}),n.mkdirSync(h(t),{recursive:!0}),A(e,t,n)}function A(e,t,n){n.mkdirSync(t,{recursive:!0});for(let r of n.readdirSync(e)){let i=g(e,r),a=g(t,r);n.isDirectory(i)?A(i,a,n):n.writeFileSync(a,n.readFileSync(i))}}function j(e,t,n,r,i,a){let o=[],s=g(e,`.agents`,`skills`,t),c=r.existsSync(s),l=!1;try{k(n,s,r),l=!0,o.push({kind:`central`,path:s,outcome:c?`overwritten`:`written`}),i({event:`user-skill-reclaim-central-written`,scope:`user`,path:s,preexisting:c,version:a})}catch(e){let t=e instanceof Error?e.message:String(e);o.push({kind:`central`,path:s,outcome:`failed`,error:t}),i({event:`user-skill-reclaim-central-failed`,scope:`user`,path:s,error:t})}for(let c of p){let l=g(e,c.hostDir),u=g(l,`skills`,t);if(u===s){o.push({kind:`host`,editorId:c.editorId,hostDir:c.hostDir,path:u,outcome:`skipped-collapsed-with-central`});continue}if(!r.existsSync(l)){o.push({kind:`host`,editorId:c.editorId,hostDir:c.hostDir,path:u,outcome:`skipped-host-absent`});continue}let d=r.existsSync(u);try{k(n,u,r),o.push({kind:`host`,editorId:c.editorId,hostDir:c.hostDir,path:u,outcome:d?`overwritten`:`written`}),i({event:`user-skill-reclaim-host-written`,scope:`user`,editorId:c.editorId,hostDir:c.hostDir,path:u,preexisting:d,version:a})}catch(e){let t=e instanceof Error?e.message:String(e);o.push({kind:`host`,editorId:c.editorId,hostDir:c.hostDir,path:u,outcome:`failed`,error:t}),i({event:`user-skill-reclaim-host-failed`,scope:`user`,editorId:c.editorId,hostDir:c.hostDir,path:u,error:t})}}return{entries:o,centralWritten:l}}function M(e,t){if(!e)return!1;try{if(!t.existsSync(e))return!1;let n=t.readFileSync(e).toString(`utf8`);return n.includes(`# ok-mcp-v1`)||n.includes(`# ok-mcp-win-v1`)}catch{return!1}}function N(e,t,n,r){let i;try{i=t.resolveProjectBundledSkillDir()}catch(e){return r({event:`project-skill-reclaim-bundle-missing`,scope:`project`,error:e instanceof Error?e.message:String(e)}),{outcome:`skipped`,reason:`bundle-missing`}}let a=[];for(let t of p){let o=g(e,t.hostDir,`skills`,`open-knowledge`),s=g(o,`SKILL.md`),c=n.existsSync(s),l=f[t.editorId]?.projectConfigPath?.(e),u=!c&&M(l,n);if(!c&&!u){a.push({editorId:t.editorId,hostDir:t.hostDir,path:o,outcome:`no-token`}),r({event:`project-skill-reclaim-no-token`,scope:`project`,editorId:t.editorId,path:o});continue}try{m(o,e),k(i,o,n);let s=c?`reclaimed`:`created`;a.push({editorId:t.editorId,hostDir:t.hostDir,path:o,outcome:s}),r({event:c?`project-skill-reclaim-reclaimed`:`project-skill-reclaim-created`,scope:`project`,editorId:t.editorId,path:o})}catch(e){let n=e instanceof Error?e.message:String(e);a.push({editorId:t.editorId,hostDir:t.hostDir,path:o,outcome:`failed`,error:n}),r({event:`project-skill-reclaim-failed`,scope:`project`,editorId:t.editorId,path:o,error:n})}}return{outcome:`done`,entries:a}}async function P(t,n,r,i){let a=e=>{n.recordEvent(e).catch(()=>{})},s=()=>new Date().toISOString(),c;try{c=await n.readBundledVersion()}catch(e){let t=e instanceof Error?e.message:String(e);return i({event:`user-skill-reclaim-version-read-failed`,scope:`user`,error:t}),a({ts:s(),surface:`cli-start`,target:`cli-hosts`,bundle:`discovery`,outcome:`failed`,reason:`version-read-failed:${t}`}),{outcome:`skipped`,reason:`version-read-failed`}}let u;try{u=await n.readRecordedVersion(t)}catch(e){i({event:`user-skill-reclaim-version-read-error`,scope:`user`,error:e instanceof Error?e.message:String(e)}),u=null}let d=[],f=null;for(let e of l)try{d.push({id:e,sourceDir:n.resolveUserBundledSkillDir(e)})}catch(e){f=e instanceof Error?e.message:String(e)}if(d.length===0)return i({event:`user-skill-reclaim-bundle-missing`,scope:`user`,error:f??`no user-global bundles`}),a({ts:s(),surface:`cli-start`,target:`cli-hosts`,outcome:`failed`,reason:`bundle-missing:${f}`}),{outcome:`skipped`,reason:`bundle-missing`};let p=[];for(let a of d){let s=o[a.id],c=r.existsSync(g(t,`.agents`,`skills`,s)),l=await n.readBundleDecision(t,s).catch(()=>null);if(!e(l,{installedOnDisk:c})){if(c)try{n.removeBundleFromDisk(t,a.id),i({event:`user-skill-reclaim-bundle-declined-removed`,scope:`user`,bundle:a.id})}catch(e){i({event:`user-skill-reclaim-bundle-remove-failed`,scope:`user`,bundle:a.id,error:e instanceof Error?e.message:String(e)})}continue}if(l===null&&c)try{await n.writeBundleDecision(t,s,!0)}catch(e){i({event:`user-skill-reclaim-grandfather-write-failed`,scope:`user`,bundle:a.id,error:e instanceof Error?e.message:String(e)})}p.push(a)}if(p.length===0)return{outcome:`skipped`,reason:`all-bundles-declined`};let m=p.every(e=>r.existsSync(g(t,`.agents`,`skills`,o[e.id])));if(u!==null&&u===c&&m)return i({event:`user-skill-reclaim-skipped-version-current`,scope:`user`,version:c}),{outcome:`skipped`,reason:`version-current`};let h=[],_=d.length===l.length,v=!0;for(let{id:e,sourceDir:n}of p){let a=j(t,o[e],n,r,i,c);h.push(...a.entries),a.centralWritten||(v=!1)}let y=h.some(e=>e.kind===`central`&&(e.outcome===`written`||e.outcome===`overwritten`));if(_&&v&&y){let e=null;try{await n.writeRecordedVersion(t,c),i({event:`user-skill-reclaim-version-recorded`,scope:`user`,version:c})}catch(t){e=t instanceof Error?t.message:String(t),i({event:`user-skill-reclaim-version-record-failed`,scope:`user`,version:c,error:e})}for(let{id:t}of p)a({ts:s(),surface:`cli-start`,target:`cli-hosts`,bundle:t,outcome:e===null?`installed`:`failed`,version:c,...e===null?{}:{reason:`state-write-failed:${e}`}})}else{let e=h.some(e=>e.kind===`host`&&e.outcome===`failed`);a({ts:s(),surface:`cli-start`,target:`cli-hosts`,outcome:`failed`,version:c,reason:e?`all-writes-failed`:`no-hosts-installed`})}return{outcome:`done`,version:c,entries:h}}async function F(e){let t=e.logger??O,n=e.fs??E,r=e.home??v(),i={...D,...e.deps};return e.reclaimDisableEnv===`1`?(t({event:`skill-repair-skipped`,reason:`reclaim-disabled`}),{status:`skipped`,reason:`reclaim-disabled`}):{status:`done`,project:N(e.projectDir,i,n,t),user:await P(r,i,n,t)}}function I(e){return e.status===`skipped`?e.reason===`reclaim-disabled`?0:1:e.project.outcome===`skipped`||e.user.outcome===`skipped`&&e.user.reason!==`version-current`&&e.user.reason!==`all-bundles-declined`||e.project.entries.some(e=>e.outcome===`failed`)||e.user.outcome===`done`&&e.user.entries.some(e=>e.outcome===`failed`)?1:0}function L(e){if(e.status===`skipped`)return`Skipped: ${e.reason}`;let t=[`Skill reclaim complete.`];if(e.project.outcome===`done`){let n=e.project.entries.filter(e=>e.outcome===`reclaimed`).length,r=e.project.entries.filter(e=>e.outcome===`created`).length,i=e.project.entries.filter(e=>e.outcome===`no-token`).length,a=e.project.entries.filter(e=>e.outcome===`failed`).length;t.push(` Project: ${n} reclaimed, ${r} created, ${i} no-token, ${a} failed.`)}else t.push(` Project: skipped (${e.project.reason}).`);if(e.user.outcome===`done`){let n=e.user.entries.filter(e=>e.outcome===`written`||e.outcome===`overwritten`).length,r=e.user.entries.filter(e=>e.outcome===`skipped-host-absent`||e.outcome===`skipped-collapsed-with-central`).length,i=e.user.entries.filter(e=>e.outcome===`failed`).length;t.push(` User (${e.user.version}): ${n} written, ${r} skipped, ${i} failed.`)}else t.push(` User: skipped (${e.user.reason}).`);return t.join(`
1
+ import{da as e}from"./server-lock-iLcBw_q0-WEyo7ukm.mjs";import{Br as t,Fr as n,Nr as r,Wr as i,Xr as a,d as o,ea as s,ia as c,lt as l}from"./dist-BXlA66Rv.mjs";import{t as u}from"./esm-CsQUg9js.mjs";import{a as d,d as f,f as p,t as m}from"./write-project-skill-dxucK8PX.mjs";import{dirname as h,join as g,resolve as _}from"node:path";import{homedir as v}from"node:os";import{existsSync as y,mkdirSync as b,readFileSync as x,readdirSync as S,rmSync as C,statSync as w,writeFileSync as T}from"node:fs";const E={existsSync:e=>y(e),isDirectory:e=>{try{return w(e).isDirectory()}catch(e){if(e.code===`ENOENT`)return!1;throw e}},readdirSync:e=>S(e),readFileSync:e=>x(e),writeFileSync:(e,t)=>{T(e,t)},mkdirSync:(e,t)=>{b(e,t)},rmSync:(e,t)=>{C(e,t)}},D={resolveProjectBundledSkillDir:()=>a(`project`,{checkDesktop:!1}),resolveUserBundledSkillDir:e=>a(e,{checkDesktop:!1}),readBundledVersion:()=>n(),readRecordedVersion:e=>t(e,`cli-hosts`),writeRecordedVersion:(e,t)=>c(e,`cli-hosts`,t,`cli-start`),recordEvent:e=>i(e),readBundleDecision:(e,t)=>r(e,t),writeBundleDecision:(e,t,n)=>s(e,t,n),removeBundleFromDisk:(e,t)=>d(e,t)};function O(e){process.stderr.write(`${JSON.stringify(e)}\n`)}function k(e,t,n){n.rmSync(t,{recursive:!0,force:!0}),n.mkdirSync(h(t),{recursive:!0}),A(e,t,n)}function A(e,t,n){n.mkdirSync(t,{recursive:!0});for(let r of n.readdirSync(e)){let i=g(e,r),a=g(t,r);n.isDirectory(i)?A(i,a,n):n.writeFileSync(a,n.readFileSync(i))}}function j(e,t,n,r,i,a){let o=[],s=g(e,`.agents`,`skills`,t),c=r.existsSync(s),l=!1;try{k(n,s,r),l=!0,o.push({kind:`central`,path:s,outcome:c?`overwritten`:`written`}),i({event:`user-skill-reclaim-central-written`,scope:`user`,path:s,preexisting:c,version:a})}catch(e){let t=e instanceof Error?e.message:String(e);o.push({kind:`central`,path:s,outcome:`failed`,error:t}),i({event:`user-skill-reclaim-central-failed`,scope:`user`,path:s,error:t})}for(let c of p){let l=g(e,c.hostDir),u=g(l,`skills`,t);if(u===s){o.push({kind:`host`,editorId:c.editorId,hostDir:c.hostDir,path:u,outcome:`skipped-collapsed-with-central`});continue}if(!r.existsSync(l)){o.push({kind:`host`,editorId:c.editorId,hostDir:c.hostDir,path:u,outcome:`skipped-host-absent`});continue}let d=r.existsSync(u);try{k(n,u,r),o.push({kind:`host`,editorId:c.editorId,hostDir:c.hostDir,path:u,outcome:d?`overwritten`:`written`}),i({event:`user-skill-reclaim-host-written`,scope:`user`,editorId:c.editorId,hostDir:c.hostDir,path:u,preexisting:d,version:a})}catch(e){let t=e instanceof Error?e.message:String(e);o.push({kind:`host`,editorId:c.editorId,hostDir:c.hostDir,path:u,outcome:`failed`,error:t}),i({event:`user-skill-reclaim-host-failed`,scope:`user`,editorId:c.editorId,hostDir:c.hostDir,path:u,error:t})}}return{entries:o,centralWritten:l}}function M(e,t){if(!e)return!1;try{if(!t.existsSync(e))return!1;let n=t.readFileSync(e).toString(`utf8`);return n.includes(`# ok-mcp-v1`)||n.includes(`# ok-mcp-win-v1`)}catch{return!1}}function N(e,t,n,r){let i;try{i=t.resolveProjectBundledSkillDir()}catch(e){return r({event:`project-skill-reclaim-bundle-missing`,scope:`project`,error:e instanceof Error?e.message:String(e)}),{outcome:`skipped`,reason:`bundle-missing`}}let a=[];for(let t of p){let o=g(e,t.hostDir,`skills`,`open-knowledge`),s=g(o,`SKILL.md`),c=n.existsSync(s),l=f[t.editorId]?.projectConfigPath?.(e),u=!c&&M(l,n);if(!c&&!u){a.push({editorId:t.editorId,hostDir:t.hostDir,path:o,outcome:`no-token`}),r({event:`project-skill-reclaim-no-token`,scope:`project`,editorId:t.editorId,path:o});continue}try{m(o,e),k(i,o,n);let s=c?`reclaimed`:`created`;a.push({editorId:t.editorId,hostDir:t.hostDir,path:o,outcome:s}),r({event:c?`project-skill-reclaim-reclaimed`:`project-skill-reclaim-created`,scope:`project`,editorId:t.editorId,path:o})}catch(e){let n=e instanceof Error?e.message:String(e);a.push({editorId:t.editorId,hostDir:t.hostDir,path:o,outcome:`failed`,error:n}),r({event:`project-skill-reclaim-failed`,scope:`project`,editorId:t.editorId,path:o,error:n})}}return{outcome:`done`,entries:a}}async function P(t,n,r,i){let a=e=>{n.recordEvent(e).catch(()=>{})},s=()=>new Date().toISOString(),c;try{c=await n.readBundledVersion()}catch(e){let t=e instanceof Error?e.message:String(e);return i({event:`user-skill-reclaim-version-read-failed`,scope:`user`,error:t}),a({ts:s(),surface:`cli-start`,target:`cli-hosts`,bundle:`discovery`,outcome:`failed`,reason:`version-read-failed:${t}`}),{outcome:`skipped`,reason:`version-read-failed`}}let u;try{u=await n.readRecordedVersion(t)}catch(e){i({event:`user-skill-reclaim-version-read-error`,scope:`user`,error:e instanceof Error?e.message:String(e)}),u=null}let d=[],f=null;for(let e of l)try{d.push({id:e,sourceDir:n.resolveUserBundledSkillDir(e)})}catch(e){f=e instanceof Error?e.message:String(e)}if(d.length===0)return i({event:`user-skill-reclaim-bundle-missing`,scope:`user`,error:f??`no user-global bundles`}),a({ts:s(),surface:`cli-start`,target:`cli-hosts`,outcome:`failed`,reason:`bundle-missing:${f}`}),{outcome:`skipped`,reason:`bundle-missing`};let p=[];for(let a of d){let s=o[a.id],c=r.existsSync(g(t,`.agents`,`skills`,s)),l=await n.readBundleDecision(t,s).catch(()=>null);if(!e(l,{installedOnDisk:c})){if(c)try{n.removeBundleFromDisk(t,a.id),i({event:`user-skill-reclaim-bundle-declined-removed`,scope:`user`,bundle:a.id})}catch(e){i({event:`user-skill-reclaim-bundle-remove-failed`,scope:`user`,bundle:a.id,error:e instanceof Error?e.message:String(e)})}continue}if(l===null&&c)try{await n.writeBundleDecision(t,s,!0)}catch(e){i({event:`user-skill-reclaim-grandfather-write-failed`,scope:`user`,bundle:a.id,error:e instanceof Error?e.message:String(e)})}p.push(a)}if(p.length===0)return{outcome:`skipped`,reason:`all-bundles-declined`};let m=p.every(e=>r.existsSync(g(t,`.agents`,`skills`,o[e.id])));if(u!==null&&u===c&&m)return i({event:`user-skill-reclaim-skipped-version-current`,scope:`user`,version:c}),{outcome:`skipped`,reason:`version-current`};let h=[],_=d.length===l.length,v=!0;for(let{id:e,sourceDir:n}of p){let a=j(t,o[e],n,r,i,c);h.push(...a.entries),a.centralWritten||(v=!1)}let y=h.some(e=>e.kind===`central`&&(e.outcome===`written`||e.outcome===`overwritten`));if(_&&v&&y){let e=null;try{await n.writeRecordedVersion(t,c),i({event:`user-skill-reclaim-version-recorded`,scope:`user`,version:c})}catch(t){e=t instanceof Error?t.message:String(t),i({event:`user-skill-reclaim-version-record-failed`,scope:`user`,version:c,error:e})}for(let{id:t}of p)a({ts:s(),surface:`cli-start`,target:`cli-hosts`,bundle:t,outcome:e===null?`installed`:`failed`,version:c,...e===null?{}:{reason:`state-write-failed:${e}`}})}else{let e=h.some(e=>e.kind===`host`&&e.outcome===`failed`);a({ts:s(),surface:`cli-start`,target:`cli-hosts`,outcome:`failed`,version:c,reason:e?`all-writes-failed`:`no-hosts-installed`})}return{outcome:`done`,version:c,entries:h}}async function F(e){let t=e.logger??O,n=e.fs??E,r=e.home??v(),i={...D,...e.deps};return e.reclaimDisableEnv===`1`?(t({event:`skill-repair-skipped`,reason:`reclaim-disabled`}),{status:`skipped`,reason:`reclaim-disabled`}):{status:`done`,project:N(e.projectDir,i,n,t),user:await P(r,i,n,t)}}function I(e){return e.status===`skipped`?e.reason===`reclaim-disabled`?0:1:e.project.outcome===`skipped`||e.user.outcome===`skipped`&&e.user.reason!==`version-current`&&e.user.reason!==`all-bundles-declined`||e.project.entries.some(e=>e.outcome===`failed`)||e.user.outcome===`done`&&e.user.entries.some(e=>e.outcome===`failed`)?1:0}function L(e){if(e.status===`skipped`)return`Skipped: ${e.reason}`;let t=[`Skill reclaim complete.`];if(e.project.outcome===`done`){let n=e.project.entries.filter(e=>e.outcome===`reclaimed`).length,r=e.project.entries.filter(e=>e.outcome===`created`).length,i=e.project.entries.filter(e=>e.outcome===`no-token`).length,a=e.project.entries.filter(e=>e.outcome===`failed`).length;t.push(` Project: ${n} reclaimed, ${r} created, ${i} no-token, ${a} failed.`)}else t.push(` Project: skipped (${e.project.reason}).`);if(e.user.outcome===`done`){let n=e.user.entries.filter(e=>e.outcome===`written`||e.outcome===`overwritten`).length,r=e.user.entries.filter(e=>e.outcome===`skipped-host-absent`||e.outcome===`skipped-collapsed-with-central`).length,i=e.user.entries.filter(e=>e.outcome===`failed`).length;t.push(` User (${e.user.version}): ${n} written, ${r} skipped, ${i} failed.`)}else t.push(` User: skipped (${e.user.reason}).`);return t.join(`
2
2
  `)}function R(){return new u(`repair-skills`).description("Refresh bundled SKILL.md files for installed AI editors (project-local + user-global). Runs automatically during `ok start`; this command forces an explicit sweep.").action(async()=>{let e=await F({projectDir:_(process.cwd()),reclaimDisableEnv:process.env.OK_RECLAIM_DISABLE??null});process.stdout.write(`${L(e)}\n`),process.exitCode=I(e)})}export{R as n,F as t};
3
- //# sourceMappingURL=repair-skills-B0R_QUCx.mjs.map
3
+ //# sourceMappingURL=repair-skills-BwUGllKc.mjs.map
@@ -0,0 +1 @@
1
+ import{_ as e,f as t,y as n}from"./server-lock-iLcBw_q0-WEyo7ukm.mjs";export{t as markServerLockDraining,e as releaseServerLock,n as updateServerLockPort};