werkmeister 0.93.2 → 0.93.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{budget-TJ5ZCV63.js → budget-M6Q2T6LB.js} +2 -2
- package/dist/{cache-JBDXLM35.js → cache-JBZR4WPQ.js} +2 -2
- package/dist/{chunk-XR7D4UBS.js → chunk-2RXLRCHL.js} +2 -2
- package/dist/{chunk-FO7AF54Y.js → chunk-3QVQNEW2.js} +2 -2
- package/dist/{chunk-LJPNME4Q.js → chunk-3Y3BULLF.js} +2 -2
- package/dist/{chunk-3WTHSTYS.js → chunk-4FPAKI7C.js} +2 -2
- package/dist/{chunk-4T7IEMCY.js → chunk-4NCV6JR7.js} +2 -2
- package/dist/{chunk-ICUBRHZI.js → chunk-5PLIRGOA.js} +2 -2
- package/dist/{chunk-MQ6R526K.js → chunk-5QV4XDJZ.js} +2 -2
- package/dist/{chunk-IRJVVN7Y.js → chunk-5X3N6AZP.js} +2 -2
- package/dist/{chunk-ECZBAD7L.js → chunk-76FS62DP.js} +2 -2
- package/dist/{chunk-JVMT5KGE.js → chunk-ACHONTIB.js} +2 -2
- package/dist/{chunk-ZZFJD6PY.js → chunk-B63EVTK3.js} +2 -2
- package/dist/{chunk-P3VQER4Q.js → chunk-B7RRUAOW.js} +2 -2
- package/dist/{chunk-ASF553GS.js → chunk-CB4VFJEL.js} +2 -2
- package/dist/{chunk-5VOJOWY3.js → chunk-CTD3M3ZO.js} +15 -10
- package/dist/{chunk-52FZE4KH.js → chunk-DJAG45GG.js} +2 -2
- package/dist/{chunk-ULR6EH4M.js → chunk-EAQJ3OP2.js} +2 -2
- package/dist/{chunk-3MJUN7FF.js → chunk-EHFZN2TL.js} +2 -2
- package/dist/{chunk-AUCJEXWT.js → chunk-F4IMOZQW.js} +2 -2
- package/dist/{chunk-YRQU5A47.js → chunk-FER2NQNY.js} +2 -2
- package/dist/{chunk-AIWEEDTX.js → chunk-FR6GPITJ.js} +2 -2
- package/dist/{chunk-SBAMBSFX.js → chunk-FVBAAF7Z.js} +3 -3
- package/dist/{chunk-DKMPT57Q.js → chunk-GL2LH3ZK.js} +2 -2
- package/dist/{chunk-OAFCZWMU.js → chunk-GRHGF46X.js} +2 -2
- package/dist/chunk-ID5DURPG.js +4 -0
- package/dist/{chunk-JKG6JQCB.js → chunk-JB5CVVN2.js} +2 -2
- package/dist/{chunk-JQWKJBDP.js → chunk-JDHBMVSN.js} +2 -2
- package/dist/{chunk-LTYMB2XG.js → chunk-JGUVBPJI.js} +2 -2
- package/dist/{chunk-VB6RAA25.js → chunk-K4WOL6WD.js} +2 -2
- package/dist/{chunk-QM2A7HTB.js → chunk-K6RCSRE3.js} +2 -2
- package/dist/{chunk-KSUASOM5.js → chunk-KQ3OMGNX.js} +2 -2
- package/dist/{chunk-S6BQOL3K.js → chunk-KR27O6KM.js} +2 -2
- package/dist/{chunk-4PXUFOF2.js → chunk-KXBHMOYS.js} +2 -2
- package/dist/{chunk-3GVGMLBB.js → chunk-LOARA444.js} +2 -2
- package/dist/{chunk-RWUX6TEA.js → chunk-MUSFRIK3.js} +2 -2
- package/dist/chunk-NORRRFBV.js +33 -0
- package/dist/{chunk-KMMUMNYM.js → chunk-O4K73Q2I.js} +2 -2
- package/dist/{chunk-F6C37Y2R.js → chunk-O76M2QHE.js} +2 -2
- package/dist/{chunk-QXGFYFNP.js → chunk-ORWGD7MD.js} +2 -2
- package/dist/{chunk-TMVSY33D.js → chunk-PZSUMAJA.js} +2 -2
- package/dist/{chunk-ZXV6DXRJ.js → chunk-Q2YBMEPF.js} +2 -2
- package/dist/{chunk-SO2T2ZN3.js → chunk-QDLSCYDM.js} +2 -2
- package/dist/{chunk-TOOLPUVG.js → chunk-QHKVGE7Y.js} +2 -2
- package/dist/{chunk-GQAD4XJ4.js → chunk-R4K233AX.js} +2 -2
- package/dist/{chunk-PEGGGOE6.js → chunk-RF3G4YRP.js} +3 -3
- package/dist/{chunk-K3ZGG5IK.js → chunk-RJF7ZLAO.js} +2 -2
- package/dist/{chunk-VJW6Y5WR.js → chunk-RPFKVTPE.js} +2 -2
- package/dist/{chunk-SFEYI3ND.js → chunk-RTBYODJT.js} +2 -2
- package/dist/{chunk-XEKGITG4.js → chunk-RXP24ITU.js} +2 -2
- package/dist/{chunk-LJGLMBOR.js → chunk-SE4JKSDJ.js} +2 -2
- package/dist/{chunk-3VFQKUDX.js → chunk-T3N2TU7T.js} +2 -2
- package/dist/{chunk-ODW2JE2W.js → chunk-UJ6DPS4B.js} +2 -2
- package/dist/{chunk-WYYM4CFN.js → chunk-UKEGRHTM.js} +2 -2
- package/dist/{chunk-6AVTZQKD.js → chunk-ULNRIE5C.js} +2 -2
- package/dist/{chunk-DXS5IA3V.js → chunk-UT262DG6.js} +2 -2
- package/dist/{chunk-DGSP7G7R.js → chunk-WP5YT7VS.js} +2 -2
- package/dist/{chunk-7EGC7C44.js → chunk-X57IXE7Q.js} +2 -2
- package/dist/{chunk-6YZIYPAV.js → chunk-XDBPLBUZ.js} +2 -2
- package/dist/{chunk-4SR6YMSK.js → chunk-XMDARS6Z.js} +2 -2
- package/dist/{chunk-A4JOBS3X.js → chunk-XY5RD66R.js} +2 -2
- package/dist/{chunk-W235VC3S.js → chunk-YE4G6SF3.js} +3 -3
- package/dist/{chunk-AZ5IHBXV.js → chunk-YGQHHRX3.js} +2 -2
- package/dist/{chunk-HMT3WVA6.js → chunk-YUZPGBGJ.js} +2 -2
- package/dist/{chunk-5KV6OR7H.js → chunk-ZH3PHAJR.js} +2 -2
- package/dist/{chunk-Y363LJO2.js → chunk-ZHIPODEL.js} +2 -2
- package/dist/{chunk-HDFC52G6.js → chunk-ZQWOS5LL.js} +2 -2
- package/dist/{chunk-IMB62QG5.js → chunk-ZTFZLNXX.js} +47 -46
- package/dist/clean-RJ3UU47I.js +8 -0
- package/dist/close_out-XIQZEV4X.js +8 -0
- package/dist/code-45HVFOAZ.js +4 -0
- package/dist/{config-UBWBZ526.js → config-OHK7YXIF.js} +2 -2
- package/dist/{connect-3WA3SGCE.js → connect-P23ZRHED.js} +2 -2
- package/dist/{daemon-M2SUJGYP.js → daemon-2EIJPAZM.js} +2 -2
- package/dist/dashboard.js +1 -1
- package/dist/{detect-K3CN6IUG.js → detect-E2F2QASJ.js} +2 -2
- package/dist/{down-ZFVUSJOQ.js → down-6RCGHBG2.js} +3 -3
- package/dist/{fixture-XI47YOTE.js → fixture-XFOURTGK.js} +2 -2
- package/dist/form-cli.js +1 -1
- package/dist/hooks-BKAQWOPG.js +4 -0
- package/dist/{hooks_gen-4AZQMABH.js → hooks_gen-LIAHG2UF.js} +2 -2
- package/dist/infra-5O4SJKCC.js +4 -0
- package/dist/init_workspace-JHW77HJE.js +4 -0
- package/dist/{intercept-FUF5W7RD.js → intercept-C255V2OV.js} +2 -2
- package/dist/{issue-V4VPVO27.js → issue-RJLHB4VC.js} +2 -2
- package/dist/lib/agent_state.js +1 -1
- package/dist/lib/gate.js +1 -1
- package/dist/lib/pr_guard.js +1 -1
- package/dist/list_workspaces-2ZIAWC44.js +7 -0
- package/dist/logs-NZDOMMJL.js +6 -0
- package/dist/main.js +3 -3
- package/dist/mcp-proxy.js +1 -1
- package/dist/mcp.js +1 -1
- package/dist/{migrate-43AUCURJ.js → migrate-Y76LMJRA.js} +2 -2
- package/dist/notes-EEC3POAG.js +4 -0
- package/dist/{open-CWS4TVAG.js → open-UFINFQTM.js} +2 -2
- package/dist/{optimize-CTUQ46VD.js → optimize-OFAEZOA3.js} +2 -2
- package/dist/pause-D7E4JCRV.js +4 -0
- package/dist/pr-XXYDX2GP.js +5 -0
- package/dist/proxy_reload-M7ZPWN7G.js +6 -0
- package/dist/{registry-TY7M6R7Y.js → registry-QM5A4VPM.js} +2 -2
- package/dist/remove-J5VGVFAF.js +7 -0
- package/dist/remove_workspace-ZTYN732K.js +8 -0
- package/dist/restart-PPKQGQ6V.js +8 -0
- package/dist/resume-67ZGI4WD.js +8 -0
- package/dist/{safari-N2QANFEN.js → safari-5WV7JRN4.js} +2 -2
- package/dist/{sandbox-VVWEZD6R.js → sandbox-GXF43IY4.js} +2 -2
- package/dist/{services-YWGYI3CQ.js → services-6DREGT73.js} +2 -2
- package/dist/{setup-I43XSSB4.js → setup-VODRPG5U.js} +2 -2
- package/dist/skills-IB6LCOBR.js +4 -0
- package/dist/{slots-HNHA6KFD.js → slots-WG2LH372.js} +2 -2
- package/dist/{standards-HGMR36O4.js → standards-XXNNGBGT.js} +2 -2
- package/dist/start_args-6MQ5NNOP.js +4 -0
- package/dist/starting_prompt-ZBOK5FP4.js +4 -0
- package/dist/stats-NCDLCTRZ.js +4 -0
- package/dist/{status-ETR5TAXK.js → status-LUGHPZ2I.js} +2 -2
- package/dist/{stop-WNGMPPKQ.js → stop-UTIAHN4W.js} +2 -2
- package/dist/{telepresence-JEAKY7YW.js → telepresence-5NETEVMM.js} +2 -2
- package/dist/{test-OWKCU4X5.js → test-XHXO7IVL.js} +2 -2
- package/dist/{tokens-A3GTX5YY.js → tokens-WLASHMKS.js} +2 -2
- package/dist/{up-O2NQFRV3.js → up-ODVE35OY.js} +3 -3
- package/dist/{v4-KHIQIC5F.js → v4-V57BX2LR.js} +2 -2
- package/dist/wait_load-DPC7TY2Z.js +4 -0
- package/dist/werkmeister-workspaces.vsix +0 -0
- package/dist/{workspace-XKDHTRRP.js → workspace-R6NV7VSO.js} +2 -2
- package/package.json +3 -3
- package/dist/chunk-4C7VSSUG.js +0 -33
- package/dist/chunk-PB7AQAOV.js +0 -4
- package/dist/clean-54XTEURK.js +0 -8
- package/dist/close_out-JXBKRFIH.js +0 -8
- package/dist/code-WXYZZQMV.js +0 -4
- package/dist/hooks-GWOEKWGH.js +0 -4
- package/dist/infra-BMUPVG5C.js +0 -4
- package/dist/init_workspace-4KPETNIV.js +0 -4
- package/dist/list_workspaces-RD6EFH5Y.js +0 -7
- package/dist/logs-C6ZXA5K7.js +0 -6
- package/dist/notes-SY3WCUNO.js +0 -4
- package/dist/pause-OMECBDI7.js +0 -4
- package/dist/pr-3LUOTDYG.js +0 -5
- package/dist/proxy_reload-OGIIIHFA.js +0 -6
- package/dist/remove-ITDIKN4D.js +0 -7
- package/dist/remove_workspace-FX6BIX43.js +0 -8
- package/dist/restart-FOSPANRH.js +0 -8
- package/dist/resume-UKM6SUOD.js +0 -8
- package/dist/skills-TYDZRM6G.js +0 -4
- package/dist/start_args-72UTJD5L.js +0 -4
- package/dist/starting_prompt-CFW7DZQ2.js +0 -4
- package/dist/stats-WBWNRK5Z.js +0 -4
- package/dist/wait_load-VZEA7F67.js +0 -4
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { createRequire as __sandboxCreateRequire } from "node:module";
|
|
2
2
|
const require = __sandboxCreateRequire(import.meta.url);
|
|
3
|
-
import{h as H}from"./chunk-
|
|
3
|
+
import{h as H}from"./chunk-5X3N6AZP.js";import{r as B}from"./chunk-CB4VFJEL.js";import{C as G,G as A,a as ne,l as N,w as U,y as W,z as L}from"./chunk-ULNRIE5C.js";import{a as K}from"./chunk-FER2NQNY.js";import{a as c,e as se,f as R}from"./chunk-F4IMOZQW.js";R();var $=se(ne(),1);import*as l from"node:fs";import*as V from"node:os";import*as _ from"node:path";R();import*as w from"node:fs";import*as X from"node:path";var ue=`# Port Allocation Scheme
|
|
4
4
|
# Each feature slot (1-12) gets a dedicated port range.
|
|
5
5
|
#
|
|
6
6
|
# k8s port-forward listen-ports (the 9000-range) are NOT defined here \u2014 they
|
|
@@ -16,13 +16,18 @@ feature_slots:
|
|
|
16
16
|
# ...
|
|
17
17
|
# Slot 12: 12200-12219
|
|
18
18
|
`,me=`# Per-million-token USD rates for estimating Claude Code usage cost.
|
|
19
|
-
# Add or reprice models here \u2014 no code change needed.
|
|
20
|
-
#
|
|
21
|
-
#
|
|
19
|
+
# Add or reprice models here \u2014 no code change needed. A rate here overrides
|
|
20
|
+
# werkmeister's built-in one; a model missing here falls back to the built-in
|
|
21
|
+
# rate. Unknown models show token counts with no dollar estimate and a warning.
|
|
22
|
+
# Rates are approximate; update when published pricing changes.
|
|
22
23
|
models:
|
|
23
|
-
claude-
|
|
24
|
-
claude-
|
|
25
|
-
claude-
|
|
24
|
+
claude-fable-5-2: { input: 8, output: 40, cacheWrite: 10, cacheRead: 0.20 }
|
|
25
|
+
claude-opus-5-5: { input: 4, output: 20, cacheWrite: 5, cacheRead: 0.20 }
|
|
26
|
+
claude-opus-4-8: { input: 5, output: 25, cacheWrite: 6.25, cacheRead: 0.50 }
|
|
27
|
+
claude-sonnet-5-5: { input: 2, output: 10, cacheWrite: 2.50, cacheRead: 0.10 }
|
|
28
|
+
claude-sonnet-5: { input: 2, output: 10, cacheWrite: 2.50, cacheRead: 0.20 }
|
|
29
|
+
claude-haiku-5-5: { input: 0.10, output: 0.50, cacheWrite: 0.125, cacheRead: 0.01 } # \u2264100K-token prompts
|
|
30
|
+
claude-haiku-4-5: { input: 1, output: 5, cacheWrite: 1.25, cacheRead: 0.10 }
|
|
26
31
|
`;function he(){return["# Machine-global secrets \u2014 real values, never committed.","#","# A service declares the keys it needs via `secrets:` in its services.yaml","# entry; `werkmeister feature up` writes them, as plain KEY, into that service's own","# <workspace>/.env.<service>, and fails fast when one is missing or empty.","#","# Namespace a key by service as <SERVICE>__KEY (service name uppercased,","# - -> _), e.g. MOBILE__EXPO_PUBLIC_CLERK_PUBLISHABLE_KEY=... It wins over a","# plain KEY=... line, which stays a shared fallback. Namespaced keys a","# service doesn't declare (e.g. test logins for agents) reach no container.",""].join(`
|
|
27
32
|
`)+`
|
|
28
33
|
`}c(he,"renderSecretsEnv");function J(e){return`# Machine-local registry overrides \u2014 hand-edit freely.
|
|
@@ -43,6 +48,6 @@ models:
|
|
|
43
48
|
#
|
|
44
49
|
# Kube context for a dev cluster \u2014 consumed by \`werkmeister infra intercept\`.
|
|
45
50
|
k8s_context: ${e.trim()||"orbstack"}
|
|
46
|
-
`}c(J,"renderServicesLocalYaml");function z(e,n,r=420){return
|
|
47
|
-
`)+(0
|
|
48
|
-
//# sourceMappingURL=chunk-
|
|
51
|
+
`}c(J,"renderServicesLocalYaml");function z(e,n,r=420){return w.existsSync(e)?{path:e,status:"present"}:(w.mkdirSync(X.dirname(e),{recursive:!0}),w.writeFileSync(e,n,{mode:r}),w.chmodSync(e,r),{path:e,status:"created"})}c(z,"seedFile");var C={archetypes:{"node-web":{standards:["ui","config","testing"],mcp_servers:["context7"],test:"npm test"},"node-service":{standards:["service","testing"],test:"npm test"},"node-tool":{standards:["engineering","testing"],validate:"Library: run the unit/smoke tests. No URL, cookie, or Caddy step applies."},"mcp-client":{standards:["engineering","testing"],validate:"Build, then npm run test:integration (Extension Development Host via @vscode/test-cli). Walk the open items in MANUAL-CHECKLIST.md for anything visual."}},caches:{"pnpm-store":{path:"/pnpm-store",env:{npm_config_store_dir:"/pnpm-store"},detect:["pnpm-lock.yaml"]},turbo:{path:"/turbo-cache",env:{TURBO_CACHE_DIR:"/turbo-cache",TURBO_CACHE_MAX_AGE:"14d"},detect:["turbo.json"],max_age:"14d"}},mcp_servers:{context7:{type:"stdio",command:"npx",args:["-y","@upstash/context7-mcp"],env:{CONTEXT7_API_KEY:"${CONTEXT7_API_KEY:-}"}},werkmeister:{type:"http",url:"http://host.docker.internal:${WERKMEISTER_MCP_PORT:-3002}/mcp",headers:{Authorization:"Bearer ${WERKMEISTER_MCP_TOKEN}"}}}};var D=_.join(K,"services.yaml");function M(e){let n=_.join(e,D);return l.existsSync(n)?n:null}c(M,"fragmentPath");var ie="# GENERATED by `werkmeister registry sync` \u2014 do not edit.",F=c(e=>e.startsWith("# GENERATED by "),"isGenerated"),x=["services","setup_services","infrastructure","caches"],ae=["archetypes","caches","mcp_servers","k8s_context","services","infrastructure","setup_services","repos"],y=class extends Error{static{c(this,"RegistryError")}};function m(e){return typeof e=="object"&&e!==null&&!Array.isArray(e)}c(m,"isDict");function q(e){if(!l.existsSync(e))return[];let n=[];for(let r of l.readdirSync(e).sort()){let s=M(_.join(e,r));s&&(l.statSync(_.join(e,r,".git"),{throwIfNoEntry:!1})?.isFile()||n.push(P(r,s)))}return n}c(q,"discoverFragments");function P(e,n){let r;try{r=(0,$.parse)(l.readFileSync(n,"utf8"))}catch(s){throw new y(`${n}: ${s instanceof Error?s.message:String(s)}`)}return{repo:e,path:n,doc:m(r)?r:{}}}c(P,"readFragment");var ce=/\{\{\s*(home|repos_root|workspaces_root|werkmeister_home|local_domain)\s*\}\}/g;function I(e,n){if(typeof e=="string")return e.replace(ce,(r,s)=>n[s]);if(Array.isArray(e))return e.map(r=>I(r,n));if(m(e)){let r={};for(let[s,o]of Object.entries(e))r[s]=I(o,n);return r}return e}c(I,"expandPlaceholders");function Q(e,n){let r={...e};for(let[s,o]of Object.entries(n))r[s]=m(o)&&m(r[s])?Q(r[s],o):o;return r}c(Q,"deepMerge");function j(e,n,r,s){let o=e.get(n);if(o!==void 0&&o!==r)throw new y(`${s} is defined by both ${o} and ${r}`);e.set(n,r)}c(j,"claim");function Z(e,n){let r={archetypes:structuredClone(n.defaults.archetypes??{}),caches:structuredClone(n.defaults.caches??{}),mcp_servers:structuredClone(n.defaults.mcp_servers??{}),services:{},infrastructure:{},setup_services:{},repos:{}},s=new Map;for(let o of Object.keys(r.caches))s.set(`caches/${o}`,"werkmeister");for(let o of e){let i=I(o.doc,n.paths);for(let t of Object.keys(i))if(!(t.startsWith("x-")||t==="repo"||x.includes(t)))throw new y(`${o.path}: unexpected top-level key \`${t}\` \u2014 a fragment may only contain ${x.join(", ")}, repo (and x-* anchor blocks)`);if(i.repo!==void 0){if(!m(i.repo))throw new y(`${o.path}: \`repo:\` must be a map`);Object.assign(r.repos[o.repo]??={services:[],path_mappings:{}},i.repo)}for(let t of x){let d=i[t]??{};if(!m(d))throw new y(`${o.path}: \`${t}:\` must be a map`);for(let[f,a]of Object.entries(d)){if(!m(a))throw new y(`${o.path}: \`${t}.${f}\` must be a map`);j(s,`${t}/${f}`,o.repo,`${t}.${f}`);let p=a;if(t==="services"||t==="setup_services"){if(a.repo!==void 0&&a.repo!==o.repo)throw new y(`${o.path}: ${t}.${f} says repo: ${a.repo} but lives in ${o.repo}`);p={repo:o.repo,...a}}if(t==="services"){p.port_offset!==void 0&&j(s,`port_offset/${p.port_offset}`,`${o.repo}:${f}`,`port_offset ${p.port_offset}`);let k=r.repos[o.repo]??={services:[],path_mappings:{}};k.services.push(f);let g=String(p.path??".").replace(/^\/+|\/+$/g,"");g!==""&&g!=="."&&(k.path_mappings[g]=f)}(t==="services"||t==="infrastructure")&&p.k8s_forward_port!==void 0&&j(s,`k8s_forward_port/${p.k8s_forward_port}`,`${o.repo}:${f}`,`k8s_forward_port ${p.k8s_forward_port}`),r[t][f]=p}}}return Q(r,n.local)}c(Z,"mergeRegistry");var v="disabled_fragments";function ee(e,n,r){let{[v]:s,...o}=n,i=s??[];if(!Array.isArray(i)||!i.every(a=>typeof a=="string"))throw new y(`${r}: ${v} must be a list of repo names`);let t=new Set(i),d=e.filter(a=>t.has(a.repo)),f=structuredClone(o);for(let a of["services","setup_services","infrastructure"]){let p=f[a];if(m(p))for(let[k,g]of Object.entries(p))(d.some(E=>m(E.doc[a])&&k in E.doc[a])||m(g)&&t.has(g.repo))&&delete p[k]}if(m(f.repos))for(let a of t)delete f.repos[a];return{fragments:e.filter(a=>!t.has(a.repo)),skipped:d,unknown:i.filter(a=>!e.some(p=>p.repo===a)),local:f}}c(ee,"applyDisabled");function fe(e,n,r,s=[]){let o={};for(let t of ae)t in e&&(o[t]=e[t]);for(let t of Object.keys(e))t in o||(o[t]=e[t]);return[ie,"# Edit a repo's .werkmeister/services.yaml fragment, or the machine overrides file, then","# run `werkmeister registry sync` (or `werkmeister machine setup`). Regenerated from:",...n.map(t=>`# Source: ${t}`),...s.map(t=>`# Disabled: ${t}`),`# Machine overrides: ${r}`,""].join(`
|
|
52
|
+
`)+(0,$.stringify)(o,{lineWidth:0})}c(fe,"renderRegistry");function pe(e){if(!l.existsSync(e))return null;let n=l.readFileSync(e,"utf8");if(F(n))return null;try{let r=(0,$.parse)(n),s=m(r)?r.k8s_context:void 0;return typeof s=="string"&&s.trim()?s.trim():null}catch{return null}}c(pe,"inheritedK8sContext");function le(e,n){let r;try{r=(0,$.parse)(e)}catch{return[]}if(!m(r))return[];let s=[];for(let o of x){let i=r[o];if(m(i))for(let t of Object.keys(i))t in(n[o]??{})||s.push(`${o}.${t}`)}return s}c(le,"orphanedEntries");function Ee(e,n){let r=c(t=>{try{let d=t===null?null:(0,$.parse)(t);return m(d)?d:{}}catch{return{}}},"sections"),s=r(e),o=r(n),i={added:[],removed:[],changed:[]};for(let t of x){let d=m(s[t])?s[t]:{},f=m(o[t])?o[t]:{};for(let a of new Set([...Object.keys(d),...Object.keys(f)])){let p=`${t}.${a}`;a in d?a in f?JSON.stringify(d[a])!==JSON.stringify(f[a])&&i.changed.push(p):i.removed.push(p):i.added.push(p)}}for(let t of Object.values(i))t.sort();return i}c(Ee,"registryChanges");function te(){return{home:V.homedir(),repos_root:A(),workspaces_root:G(),werkmeister_home:U(),local_domain:B().local_domain}}c(te,"placeholderPaths");function re(e){if(!l.existsSync(e))return{};let n;try{n=(0,$.parse)(l.readFileSync(e,"utf8"))}catch(r){throw new y(`${e}: ${r instanceof Error?r.message:String(r)}`)}if(n==null)return{};if(!m(n))throw new y(`${e}: must be a map of registry keys`);return n}c(re,"readLocalOverlay");function de(e,n,r=A()){let s=M(n);if(!s)return null;let o=q(r).filter(a=>a.repo!==e);o.push(P(e,s));let i=L(),t=re(i),d=t[v];Array.isArray(d)&&(t[v]=d.filter(a=>a!==e));let f=ee(o,t,i);return Z(f.fragments,{defaults:C,local:f.local,paths:te()})}c(de,"branchRegistry");function Se(e,n){let r={...e};for(let s of H(n)){let o=_.basename(s),i;try{i=de(o,s)}catch(t){N(`${o}: branch fragment ignored: ${t instanceof Error?t.message:String(t)}`);continue}for(let[t,d]of Object.entries(i?.services??{}))d.repo===o&&(r[t]=d)}return r}c(Se,"workspaceServices");function xe(e={}){let n="config services.yaml",r=e.reposRoot??A(),s=e.target??W(),o=L();if(e.generatedOnly&&l.existsSync(s)&&!F(l.readFileSync(s,"utf8")))return[{label:n,ok:!1,detail:`${s} is hand-written \u2014 left as is; \`werkmeister registry sync\` converts it (with a backup)`}];let i,t,d,f="";try{if(!e.checkOnly&&!e.target&&!l.existsSync(o)){let h=pe(s)??"orbstack";z(o,J(h)),f=`; seeded ${o} (k8s_context: ${h} \u2014 edit there)`}let u=q(r);if(u.length===0)return[{label:n,ok:!1,detail:`no ${D} found under ${r} \u2014 clone your team's repos there and re-run \`werkmeister machine setup\` (or answer yes to the demo apps)`}];let S=re(o);if(e.from){let h=M(e.from);if(!h)return[{label:n,ok:!1,detail:`no ${D} in ${e.from}`}];let O=_.basename(e.from);u=[...u.filter(T=>T.repo!==O),P(O,h)];let Y=S[v];Array.isArray(Y)&&(S[v]=Y.filter(T=>T!==O))}i=ee(u,S,o),t=Z(i.fragments,{defaults:C,local:i.local,paths:te()}),d=fe(t,i.fragments.map(h=>h.path),o,i.skipped.map(h=>h.path))}catch(u){return[{label:n,ok:!1,detail:u instanceof Error?u.message:String(u)}]}let a=[...i.skipped.map(u=>({label:`fragment ${u.repo}`,ok:!0,detail:`disabled in ${o} \u2014 skipped`})),...i.unknown.map(u=>({label:`fragment ${u}`,ok:!0,detail:`listed in ${v} in ${o}, but no fragment under ${r}`}))],p=c(u=>[u,...a],"report"),k=i.fragments.length,g=`${k} fragment${k===1?"":"s"}`,b=l.existsSync(s)?l.readFileSync(s,"utf8"):null;if(b===d)return p({label:n,ok:!0,detail:`up to date (${g}) at ${s}${f}`});if(e.checkOnly)return p({label:n,ok:!1,detail:b===null?`missing \u2014 would generate ${s} from ${g}`:`drift \u2014 would regenerate ${s} from ${g}`});let E="";if(b!==null&&!F(b)){let u=Math.floor((e.now??Date.now)()/1e3),S=`${s}.bak-${u}`;l.copyFileSync(s,S),E=`; hand-written registry backed up to ${S}`;let h=le(b,t);h.length&&(E+=`; not in any fragment: ${h.join(", ")}`)}try{l.mkdirSync(_.dirname(s),{recursive:!0}),l.writeFileSync(s,d)}catch(u){return p({label:n,ok:!1,detail:`could not write ${s}: ${u}`})}return p({label:n,ok:!0,detail:`generated ${s} from ${g}${E}${f}`})}c(xe,"syncRegistry");export{ue as a,me as b,he as c,J as d,z as e,D as f,y as g,q as h,Z as i,pe as j,Ee as k,de as l,Se as m,xe as n};
|
|
53
|
+
//# sourceMappingURL=chunk-CTD3M3ZO.js.map
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { createRequire as __sandboxCreateRequire } from "node:module";
|
|
2
2
|
const require = __sandboxCreateRequire(import.meta.url);
|
|
3
|
-
import{a as M}from"./chunk-
|
|
3
|
+
import{a as M}from"./chunk-RXP24ITU.js";import{a as $,b as v,c as y,d as u,e as S}from"./chunk-ORWGD7MD.js";import{f as x}from"./chunk-XDBPLBUZ.js";import{h as e,j as E,k as R,l as C}from"./chunk-ULNRIE5C.js";import{a as p,f as h}from"./chunk-F4IMOZQW.js";h();function T(n,t){if(Object.keys(n).length===0)return" No container data collected.";let a=[],o=` ${e.BOLD}${"Container".padEnd(35)} ${"Avg CPU".padStart(8)} ${"Max CPU".padStart(8)} ${"Avg Mem".padStart(8)} ${"Max Mem".padStart(8)} ${"Samples".padStart(7)} ${"CPU Lim".padStart(7)}${e.RESET}`;a.push(o),a.push(` ${"\u2500".repeat(94)}`);for(let r of Object.keys(n).sort()){let s=n[r];a.push(` ${r.padEnd(35)} ${s.avgCpu.toFixed(1).padStart(7)}% ${s.maxCpu.toFixed(1).padStart(7)}% ${$(s.avgMem).padStart(8)} ${$(s.maxMem).padStart(8)} ${String(s.samples).padStart(7)} ${(S(r,t)??"n/a").padStart(7)}`)}return a.join(`
|
|
4
4
|
`)}p(T,"formatStatsTable");function O(n){if(n.length===0)return" No recommendations available (no data collected).";let t=[],a=` ${e.BOLD}${"Container".padEnd(35)} ${"Max CPU".padStart(8)} ${"Max Mem".padStart(8)} ${"Rec. CPU".padStart(9)} ${"Rec. Mem".padStart(9)} ${"Rec. Rsrv".padStart(9)}${e.RESET}`;t.push(a),t.push(` ${"\u2500".repeat(90)}`);for(let o of n)t.push(` ${o.name.padEnd(35)} ${o.max_cpu_pct.toFixed(1).padStart(7)}% ${$(o.max_mem_mib).padStart(8)} ${o.recommended_cpus.padStart(9)} ${o.recommended_memory.padStart(9)} ${o.recommended_reservation.padStart(9)}`);t.push(""),t.push(` ${e.BOLD}YAML Snippets:${e.RESET}`),t.push("");for(let o of n)t.push(` # ${o.name}`),t.push(" deploy:"),t.push(" resources:"),t.push(" limits:"),t.push(` cpus: "${o.recommended_cpus}"`),t.push(` memory: ${o.recommended_memory}`),t.push(" reservations:"),t.push(` cpus: "${v(o.recommended_cpus)}"`),t.push(` memory: ${o.recommended_reservation}`),t.push("");return t.join(`
|
|
5
5
|
`)}p(O,"formatRecommendations");async function k(n){let t=n.collect??0,a=n.interval??10,o=!!n.save;console.log(`
|
|
6
6
|
${e.BOLD}=== Docker Resource Usage ===${e.RESET}
|
|
@@ -10,4 +10,4 @@ ${e.BOLD}--- Collected Statistics ---${e.RESET}
|
|
|
10
10
|
`),console.log(T(r.stats,u())),console.log(`
|
|
11
11
|
${e.BOLD}--- Recommended Resource Limits ---${e.RESET}
|
|
12
12
|
`),console.log(O(r.recommendations)),r.reportPath?R(`Report saved to: ${r.reportPath}`):a||console.log(` ${e.DIM}Tip: Use --save to write results to stats/ directory${e.RESET}`),console.log())}p(D,"renderCollection");function f(n){return n>=1024?`${(n/1024).toFixed(1)} GiB`:n>=1?`${n.toFixed(0)} MiB`:`${(n*1024).toFixed(0)} KiB`}p(f,"fmtMem");export{k as a,f as b};
|
|
13
|
-
//# sourceMappingURL=chunk-
|
|
13
|
+
//# sourceMappingURL=chunk-DJAG45GG.js.map
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { createRequire as __sandboxCreateRequire } from "node:module";
|
|
2
2
|
const require = __sandboxCreateRequire(import.meta.url);
|
|
3
|
-
import{a as Er}from"./chunk-
|
|
3
|
+
import{a as Er}from"./chunk-KQ3OMGNX.js";import{a as gr}from"./chunk-3Y3BULLF.js";import{m as kr}from"./chunk-CTD3M3ZO.js";import{d as yr}from"./chunk-KR27O6KM.js";import{b as fr}from"./chunk-RTBYODJT.js";import{i as ur}from"./chunk-5PLIRGOA.js";import{E as pr,L as hr}from"./chunk-NORRRFBV.js";import{a as mr}from"./chunk-Q2YBMEPF.js";import{Y as vr,ba as _r,c as $e,ca as ye,da as ct,u as dr}from"./chunk-ZQWOS5LL.js";import{a as Te,d as Qt}from"./chunk-76FS62DP.js";import{f as cr}from"./chunk-CB4VFJEL.js";import{b as lr}from"./chunk-ZHIPODEL.js";import{$ as lt,D as it,H as Ke,I as er,K as Me,L as tr,M as st,O as rr,Q as ot,R as nr,S as ir,U as sr,V as at,X as _e,Z as or,_ as ar,a as $i,j as je,k as te,l as fe,s as Zt}from"./chunk-ULNRIE5C.js";import{b as Ae}from"./chunk-FER2NQNY.js";import{a,b as Q,c as M,e as Jt,f as b}from"./chunk-F4IMOZQW.js";var ee=M((hc,Lr)=>{"use strict";b();var De=Array.prototype,Ne=Object.prototype,Di={"&":"&",'"':""","'":"'","<":"<",">":">","\\":"\"},qi=/[&"'<>\\]/g,j=Lr.exports={};function ut(t,n){return Ne.hasOwnProperty.call(t,n)}a(ut,"hasOwnProp");j.hasOwnProp=ut;function Ui(t){return Di[t]}a(Ui,"lookupEscape");function Vi(t,n,s){if(s.Update||(s=new j.TemplateError(s)),s.Update(t),!n){var i=s;s=new Error(i.message),s.name=i.name}return s}a(Vi,"_prettifyError");j._prettifyError=Vi;function Le(t,n,s){var i,e;t instanceof Error&&(e=t,t=e.name+": "+e.message),Object.setPrototypeOf?(i=new Error(t),Object.setPrototypeOf(i,Le.prototype)):(i=this,Object.defineProperty(i,"message",{enumerable:!1,writable:!0,value:t})),Object.defineProperty(i,"name",{value:"Template render error"}),Error.captureStackTrace&&Error.captureStackTrace(i,this.constructor);var r;if(e){var o=Object.getOwnPropertyDescriptor(e,"stack");r=o&&(o.get||function(){return o.value}),r||(r=a(function(){return e.stack},"getStack"))}else{var l=new Error(t).stack;r=a(function(){return l},"getStack")}return Object.defineProperty(i,"stack",{get:a(function(){return r.call(i)},"get")}),Object.defineProperty(i,"cause",{value:e}),i.lineno=n,i.colno=s,i.firstUpdate=!0,i.Update=a(function(u){var f="("+(u||"unknown path")+")";return this.firstUpdate&&(this.lineno&&this.colno?f+=" [Line "+this.lineno+", Column "+this.colno+"]":this.lineno&&(f+=" [Line "+this.lineno+"]")),f+=`
|
|
4
4
|
`,this.firstUpdate&&(f+=" "),this.message=f+(this.message||""),this.firstUpdate=!1,this},"Update"),i}a(Le,"TemplateError");Object.setPrototypeOf?Object.setPrototypeOf(Le.prototype,Error.prototype):Le.prototype=Object.create(Error.prototype,{constructor:{value:Le}});j.TemplateError=Le;function Wi(t){return t.replace(qi,Ui)}a(Wi,"escape");j.escape=Wi;function wr(t){return Ne.toString.call(t)==="[object Function]"}a(wr,"isFunction");j.isFunction=wr;function br(t){return Ne.toString.call(t)==="[object Array]"}a(br,"isArray");j.isArray=br;function xr(t){return Ne.toString.call(t)==="[object String]"}a(xr,"isString");j.isString=xr;function Or(t){return Ne.toString.call(t)==="[object Object]"}a(Or,"isObject");j.isObject=Or;function Gi(t){return t?typeof t=="string"?t.split("."):[t]:[]}a(Gi,"_prepareAttributeParts");function Sr(t){var n=Gi(t);return a(function(i){for(var e=i,r=0;r<n.length;r++){var o=n[r];if(ut(e,o))e=e[o];else return}return e},"attrGetter")}a(Sr,"getAttrGetter");j.getAttrGetter=Sr;function Hi(t,n,s){for(var i={},e=wr(n)?n:Sr(n),r=0;r<t.length;r++){var o=t[r],l=e(o,r);if(l===void 0&&s===!0)throw new TypeError('groupby: attribute "'+n+'" resolved to undefined');(i[l]||(i[l]=[])).push(o)}return i}a(Hi,"groupBy");j.groupBy=Hi;function Tr(t){return Array.prototype.slice.call(t)}a(Tr,"toArray");j.toArray=Tr;function Yi(t){var n=[];if(!t)return n;for(var s=t.length,i=Tr(arguments).slice(1),e=-1;++e<s;)Ar(i,t[e])===-1&&n.push(t[e]);return n}a(Yi,"without");j.without=Yi;function Xi(t,n){for(var s="",i=0;i<n;i++)s+=t;return s}a(Xi,"repeat");j.repeat=Xi;function zi(t,n,s){if(t!=null){if(De.forEach&&t.forEach===De.forEach)t.forEach(n,s);else if(t.length===+t.length)for(var i=0,e=t.length;i<e;i++)n.call(s,t[i],i,t)}}a(zi,"each");j.each=zi;function Ji(t,n){var s=[];if(t==null)return s;if(De.map&&t.map===De.map)return t.map(n);for(var i=0;i<t.length;i++)s[s.length]=n(t[i],i);return t.length===+t.length&&(s.length=t.length),s}a(Ji,"map");j.map=Ji;function Qi(t,n,s){var i=-1;function e(){i++,i<t.length?n(t[i],i,e,s):s()}a(e,"next"),e()}a(Qi,"asyncIter");j.asyncIter=Qi;function Zi(t,n,s){var i=Ce(t||{}),e=i.length,r=-1;function o(){r++;var l=i[r];r<e?n(l,t[l],r,e,o):s()}a(o,"next"),o()}a(Zi,"asyncFor");j.asyncFor=Zi;function Ar(t,n,s){return Array.prototype.indexOf.call(t||[],n,s)}a(Ar,"indexOf");j.indexOf=Ar;function Ce(t){var n=[];for(var s in t)ut(t,s)&&n.push(s);return n}a(Ce,"keys_");j.keys=Ce;function es(t){return Ce(t).map(function(n){return[n,t[n]]})}a(es,"_entries");j._entries=es;function ts(t){return Ce(t).map(function(n){return t[n]})}a(ts,"_values");j._values=ts;function rs(t,n){return t=t||{},Ce(n).forEach(function(s){t[s]=n[s]}),t}a(rs,"extend");j._assign=j.extend=rs;function ns(t,n){if(br(n)||xr(n))return n.indexOf(t)!==-1;if(Or(n))return t in n;throw new Error('Cannot use "in" operator to search for "'+t+'" in unexpected types.')}a(ns,"inOperator");j.inOperator=ns});var Pr=M((vc,Rr)=>{"use strict";b();var qe,is=typeof setImmediate=="function";Rr.exports=Cr;function Cr(t){ne.length||(Fr(),ft=!0),ne[ne.length]=t}a(Cr,"rawAsap");var ne=[],ft=!1,re=0,ss=1024;function Nr(){for(;re<ne.length;){var t=re;if(re=re+1,ne[t].call(),re>ss){for(var n=0,s=ne.length-re;n<s;n++)ne[n]=ne[n+re];ne.length-=re,re=0}}ne.length=0,re=0,ft=!1}a(Nr,"flush");Cr.requestFlush=Fr;function Fr(){var t=process.domain;t&&(qe||(qe=Q("domain")),qe.active=process.domain=null),ft&&is?setImmediate(Nr):process.nextTick(Nr),t&&(qe.active=process.domain=t)}a(Fr,"requestFlush")});var Kr=M((gc,jr)=>{"use strict";b();var Ir=Pr(),pt=[];jr.exports=os;function os(t){var n;pt.length?n=pt.pop():n=new Br,n.task=t,n.domain=process.domain,Ir(n)}a(os,"asap");function Br(){this.task=null,this.domain=null}a(Br,"RawTask");Br.prototype.call=function(){this.domain&&this.domain.enter();var t=!0;try{this.task.call(),t=!1,this.domain&&this.domain.exit()}finally{t&&Ir.requestFlush(),this.task=null,this.domain=null,pt.push(this)}}});var $r=M((Mr,Ue)=>{b();(function(t){"use strict";var n=a(function(){var o=Array.prototype.slice.call(arguments);typeof o[0]=="function"&&o[0].apply(null,o.splice(1))},"executeSync"),s=a(function(o){typeof setImmediate=="function"?setImmediate(o):typeof process<"u"&&process.nextTick?process.nextTick(o):setTimeout(o,0)},"executeAsync"),i=a(function(o){var l=a(function(c){var u=a(function(){return o.length&&o[c].apply(null,arguments),u.next()},"fn");return u.next=function(){return c<o.length-1?l(c+1):null},u},"makeCallback");return l(0)},"makeIterator"),e=Array.isArray||function(o){return Object.prototype.toString.call(o)==="[object Array]"},r=a(function(o,l,c){var u=c?s:n;if(l=l||function(){},!e(o)){var f=new Error("First argument to waterfall must be an array of functions");return l(f)}if(!o.length)return l();var p=a(function(m){return function(y){if(y)l.apply(null,arguments),l=a(function(){},"callback");else{var w=Array.prototype.slice.call(arguments,1),O=m.next();O?w.push(p(O)):w.push(l),u(function(){m.apply(null,w)})}}},"wrapIterator");p(i(o))()},"waterfall");typeof define<"u"&&define.amd?define([],function(){return r}):typeof Ue<"u"&&Ue.exports?Ue.exports=r:t.waterfall=r})(Mr)});var mt=M((xc,dn)=>{"use strict";b();var Dr=ee(),qr=`
|
|
5
5
|
\r\xA0`,Ur="()[]{}%*-+~/#,:|.<>=!",as="0123456789",ls="{%",cs="%}",us="{{",fs="}}",ps="{#",hs="#}",Vr="string",Wr="whitespace",Gr="data",Hr="block-start",Yr="block-end",Xr="variable-start",zr="variable-end",Jr="comment",Qr="left-paren",Zr="right-paren",en="left-bracket",tn="right-bracket",rn="left-curly",nn="right-curly",sn="operator",on="comma",an="colon",ln="tilde",cn="pipe",un="int",fn="float",pn="boolean",ht="none",hn="symbol",ms="special",mn="regex";function Y(t,n,s,i){return{type:t,value:n,lineno:s,colno:i}}a(Y,"token");var ds=function(){function t(s,i){this.str=s,this.index=0,this.len=s.length,this.lineno=0,this.colno=0,this.in_code=!1,i=i||{};var e=i.tags||{};this.tags={BLOCK_START:e.blockStart||ls,BLOCK_END:e.blockEnd||cs,VARIABLE_START:e.variableStart||us,VARIABLE_END:e.variableEnd||fs,COMMENT_START:e.commentStart||ps,COMMENT_END:e.commentEnd||hs},this.trimBlocks=!!i.trimBlocks,this.lstripBlocks=!!i.lstripBlocks}a(t,"Tokenizer");var n=t.prototype;return n.nextToken=a(function(){var i=this.lineno,e=this.colno,r;if(this.in_code){var o=this.current();if(this.isFinished())return null;if(o==='"'||o==="'")return Y(Vr,this._parseString(o),i,e);if(r=this._extract(qr))return Y(Wr,r,i,e);if((r=this._extractString(this.tags.BLOCK_END))||(r=this._extractString("-"+this.tags.BLOCK_END)))return this.in_code=!1,this.trimBlocks&&(o=this.current(),o===`
|
|
6
6
|
`?this.forward():o==="\r"&&(this.forward(),o=this.current(),o===`
|
|
@@ -79,4 +79,4 @@ Why: ${L}
|
|
|
79
79
|
|
|
80
80
|
Next: ${x} That rewrites this file with the container recipe.
|
|
81
81
|
`),null}tc(t,w,m,l,s,"werkmeister workspace init"),sc(t,w,m,l,s),ac(t,w,m,l,s);let[O,k]=ye(w);te(`Compose ready (slot ${w}, ports ${O}-${k})`);let _=nr(),h=yr(t,w,O,k,m,r,i,null,ur(e,_,m),pr(s),fr(s),_),d=Ae(s);return T.mkdirSync(d,{recursive:!0}),T.writeFileSync(C.join(d,"werkmeister-context.md"),h),T.rmSync(C.join(d,"sandbox-context.md"),{force:!0}),te(`Wrote ${C.basename(d)}/werkmeister-context.md`),w}a(ef,"generateWorkspaceCompose");export{Li as a,Ni as b,Ci as c,zu as d,ji as e,ec as f,tc as g,Ju as h,rc as i,Qu as j,sc as k,oc as l,ac as m,Zu as n,ef as o};
|
|
82
|
-
//# sourceMappingURL=chunk-
|
|
82
|
+
//# sourceMappingURL=chunk-EAQJ3OP2.js.map
|