@shipit-ai/cli 1.166.0 → 1.166.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.
- package/dist/tsconfig.build.tsbuildinfo +1 -1
- package/package.json +4 -2
- package/web/.next/BUILD_ID +1 -1
- package/web/.next/build-manifest.json +3 -3
- package/web/.next/fallback-build-manifest.json +3 -3
- package/web/.next/prerender-manifest.json +3 -3
- package/web/.next/required-server-files.js +2 -2
- package/web/.next/required-server-files.json +2 -2
- package/web/.next/server/app/(dashboard)/@drawer/adopt/page/server-reference-manifest.json +29 -29
- package/web/.next/server/app/(dashboard)/@drawer/adopt/page.js.nft.json +1 -1
- package/web/.next/server/app/(dashboard)/@drawer/adopt/page_client-reference-manifest.js +1 -1
- package/web/.next/server/app/(dashboard)/@drawer/chat/page/server-reference-manifest.json +27 -27
- package/web/.next/server/app/(dashboard)/@drawer/chat/page.js.nft.json +1 -1
- package/web/.next/server/app/(dashboard)/@drawer/chat/page_client-reference-manifest.js +1 -1
- package/web/.next/server/app/(dashboard)/@drawer/create/page/server-reference-manifest.json +30 -30
- package/web/.next/server/app/(dashboard)/@drawer/create/page.js.nft.json +1 -1
- package/web/.next/server/app/(dashboard)/@drawer/create/page_client-reference-manifest.js +1 -1
- package/web/.next/server/app/(dashboard)/@drawer/feature/[featureId]/[tab]/page/server-reference-manifest.json +37 -37
- package/web/.next/server/app/(dashboard)/@drawer/feature/[featureId]/[tab]/page.js.nft.json +1 -1
- package/web/.next/server/app/(dashboard)/@drawer/feature/[featureId]/[tab]/page_client-reference-manifest.js +1 -1
- package/web/.next/server/app/(dashboard)/@drawer/feature/[featureId]/page/server-reference-manifest.json +37 -37
- package/web/.next/server/app/(dashboard)/@drawer/feature/[featureId]/page.js.nft.json +1 -1
- package/web/.next/server/app/(dashboard)/@drawer/feature/[featureId]/page_client-reference-manifest.js +1 -1
- package/web/.next/server/app/(dashboard)/@drawer/repository/[repositoryId]/[tab]/page/server-reference-manifest.json +28 -28
- package/web/.next/server/app/(dashboard)/@drawer/repository/[repositoryId]/[tab]/page.js.nft.json +1 -1
- package/web/.next/server/app/(dashboard)/@drawer/repository/[repositoryId]/[tab]/page_client-reference-manifest.js +1 -1
- package/web/.next/server/app/(dashboard)/@drawer/repository/[repositoryId]/page/server-reference-manifest.json +28 -28
- package/web/.next/server/app/(dashboard)/@drawer/repository/[repositoryId]/page.js.nft.json +1 -1
- package/web/.next/server/app/(dashboard)/@drawer/repository/[repositoryId]/page_client-reference-manifest.js +1 -1
- package/web/.next/server/app/(dashboard)/chat/page/server-reference-manifest.json +27 -27
- package/web/.next/server/app/(dashboard)/chat/page.js.nft.json +1 -1
- package/web/.next/server/app/(dashboard)/chat/page_client-reference-manifest.js +1 -1
- package/web/.next/server/app/(dashboard)/create/page/server-reference-manifest.json +30 -30
- package/web/.next/server/app/(dashboard)/create/page.js.nft.json +1 -1
- package/web/.next/server/app/(dashboard)/create/page_client-reference-manifest.js +1 -1
- package/web/.next/server/app/(dashboard)/feature/[featureId]/[tab]/page/server-reference-manifest.json +37 -37
- package/web/.next/server/app/(dashboard)/feature/[featureId]/[tab]/page.js.nft.json +1 -1
- package/web/.next/server/app/(dashboard)/feature/[featureId]/[tab]/page_client-reference-manifest.js +1 -1
- package/web/.next/server/app/(dashboard)/feature/[featureId]/page/server-reference-manifest.json +37 -37
- package/web/.next/server/app/(dashboard)/feature/[featureId]/page.js.nft.json +1 -1
- package/web/.next/server/app/(dashboard)/feature/[featureId]/page_client-reference-manifest.js +1 -1
- package/web/.next/server/app/(dashboard)/page/server-reference-manifest.json +27 -27
- package/web/.next/server/app/(dashboard)/page.js.nft.json +1 -1
- package/web/.next/server/app/(dashboard)/page_client-reference-manifest.js +1 -1
- package/web/.next/server/app/(dashboard)/repository/[repositoryId]/[tab]/page/server-reference-manifest.json +28 -28
- package/web/.next/server/app/(dashboard)/repository/[repositoryId]/[tab]/page.js.nft.json +1 -1
- package/web/.next/server/app/(dashboard)/repository/[repositoryId]/[tab]/page_client-reference-manifest.js +1 -1
- package/web/.next/server/app/(dashboard)/repository/[repositoryId]/page/server-reference-manifest.json +28 -28
- package/web/.next/server/app/(dashboard)/repository/[repositoryId]/page.js.nft.json +1 -1
- package/web/.next/server/app/(dashboard)/repository/[repositoryId]/page_client-reference-manifest.js +1 -1
- package/web/.next/server/app/_global-error.html +1 -1
- package/web/.next/server/app/_global-error.rsc +1 -1
- package/web/.next/server/app/_global-error.segments/__PAGE__.segment.rsc +1 -1
- package/web/.next/server/app/_global-error.segments/_full.segment.rsc +1 -1
- package/web/.next/server/app/_global-error.segments/_head.segment.rsc +1 -1
- package/web/.next/server/app/_global-error.segments/_index.segment.rsc +1 -1
- package/web/.next/server/app/_global-error.segments/_tree.segment.rsc +1 -1
- package/web/.next/server/app/_not-found/page/server-reference-manifest.json +6 -6
- package/web/.next/server/app/_not-found/page.js.nft.json +1 -1
- package/web/.next/server/app/_not-found/page_client-reference-manifest.js +1 -1
- package/web/.next/server/app/settings/page/server-reference-manifest.json +11 -11
- package/web/.next/server/app/settings/page.js.nft.json +1 -1
- package/web/.next/server/app/settings/page_client-reference-manifest.js +1 -1
- package/web/.next/server/app/skills/page/server-reference-manifest.json +11 -11
- package/web/.next/server/app/skills/page.js.nft.json +1 -1
- package/web/.next/server/app/skills/page_client-reference-manifest.js +1 -1
- package/web/.next/server/app/tools/page/server-reference-manifest.json +11 -11
- package/web/.next/server/app/tools/page.js.nft.json +1 -1
- package/web/.next/server/app/tools/page_client-reference-manifest.js +1 -1
- package/web/.next/server/app/version/page/server-reference-manifest.json +6 -6
- package/web/.next/server/app/version/page.js.nft.json +1 -1
- package/web/.next/server/app/version/page_client-reference-manifest.js +1 -1
- package/web/.next/server/chunks/[root-of-the-server]__0tb~wwk._.js +1 -1
- package/web/.next/server/chunks/ssr/0j.8_web__next-internal_server_app_(dashboard)_@drawer_adopt_page_actions_00~eq5i.js +1 -1
- package/web/.next/server/chunks/ssr/0j.8_web__next-internal_server_app_(dashboard)_@drawer_adopt_page_actions_00~eq5i.js.map +1 -1
- package/web/.next/server/chunks/ssr/0j.8_web__next-internal_server_app_(dashboard)_@drawer_chat_page_actions_0979_c..js +1 -1
- package/web/.next/server/chunks/ssr/0j.8_web__next-internal_server_app_(dashboard)_@drawer_chat_page_actions_0979_c..js.map +1 -1
- package/web/.next/server/chunks/ssr/0j.8_web__next-internal_server_app_(dashboard)_chat_page_actions_0dqll_1.js +1 -1
- package/web/.next/server/chunks/ssr/0j.8_web__next-internal_server_app_(dashboard)_chat_page_actions_0dqll_1.js.map +1 -1
- package/web/.next/server/chunks/ssr/0j.8_web_components_common_control-center-drawer_create-drawer-client_tsx_0g70fc5._.js +1 -1
- package/web/.next/server/chunks/ssr/0j.8_web_components_common_control-center-drawer_create-drawer-client_tsx_0g70fc5._.js.map +1 -1
- package/web/.next/server/chunks/ssr/0j.8_web_components_common_control-center-drawer_feature-drawer-client_tsx_104cna.._.js +2 -2
- package/web/.next/server/chunks/ssr/0j.8_web_components_common_control-center-drawer_feature-drawer-client_tsx_104cna.._.js.map +1 -1
- package/web/.next/server/chunks/ssr/0ukq_presentation_web_components_features_settings_settings-page-client_tsx_0j1uius._.js +1 -1
- package/web/.next/server/chunks/ssr/0ukq_presentation_web_components_features_settings_settings-page-client_tsx_0j1uius._.js.map +1 -1
- package/web/.next/server/chunks/ssr/11y9_components_common_control-center-drawer_repository-drawer-client_tsx_09z.znp._.js +1 -1
- package/web/.next/server/chunks/ssr/11y9_components_common_control-center-drawer_repository-drawer-client_tsx_09z.znp._.js.map +1 -1
- package/web/.next/server/chunks/ssr/[root-of-the-server]__045sv4b._.js +1 -1
- package/web/.next/server/chunks/ssr/[root-of-the-server]__045sv4b._.js.map +1 -1
- package/web/.next/server/chunks/ssr/[root-of-the-server]__0d_0_fp._.js +1 -1
- package/web/.next/server/chunks/ssr/[root-of-the-server]__0d_0_fp._.js.map +1 -1
- package/web/.next/server/chunks/ssr/[root-of-the-server]__0l4d7e.._.js +1 -1
- package/web/.next/server/chunks/ssr/[root-of-the-server]__0l4d7e.._.js.map +1 -1
- package/web/.next/server/chunks/ssr/[root-of-the-server]__0o3qggc._.js +1 -1
- package/web/.next/server/chunks/ssr/[root-of-the-server]__0o3qggc._.js.map +1 -1
- package/web/.next/server/chunks/ssr/[root-of-the-server]__0r32z03._.js +1 -1
- package/web/.next/server/chunks/ssr/[root-of-the-server]__0r32z03._.js.map +1 -1
- package/web/.next/server/chunks/ssr/[root-of-the-server]__0rv1gci._.js +1 -1
- package/web/.next/server/chunks/ssr/[root-of-the-server]__12g8h3_._.js +1 -1
- package/web/.next/server/chunks/ssr/_01mq~sm._.js +1 -1
- package/web/.next/server/chunks/ssr/_01mq~sm._.js.map +1 -1
- package/web/.next/server/chunks/ssr/_01sesw0._.js +1 -1
- package/web/.next/server/chunks/ssr/_01sesw0._.js.map +1 -1
- package/web/.next/server/chunks/ssr/{_0r~xv6k._.js → _0a-ddx-._.js} +2 -2
- package/web/.next/server/chunks/ssr/{_0r~xv6k._.js.map → _0a-ddx-._.js.map} +1 -1
- package/web/.next/server/chunks/ssr/{_09di2m~._.js → _0e4npv~._.js} +2 -2
- package/web/.next/server/chunks/ssr/{_09di2m~._.js.map → _0e4npv~._.js.map} +1 -1
- package/web/.next/server/chunks/ssr/_0jpbsh_._.js +1 -1
- package/web/.next/server/chunks/ssr/{_12104w0._.js → _0nvrqsj._.js} +2 -2
- package/web/.next/server/chunks/ssr/{_12104w0._.js.map → _0nvrqsj._.js.map} +1 -1
- package/web/.next/server/chunks/ssr/_0vyfc4b._.js +1 -1
- package/web/.next/server/chunks/ssr/_0vyfc4b._.js.map +1 -1
- package/web/.next/server/chunks/ssr/_0w-_hww._.js +1 -1
- package/web/.next/server/chunks/ssr/_0w-_hww._.js.map +1 -1
- package/web/.next/server/chunks/ssr/_0~7lwu_._.js +1 -1
- package/web/.next/server/chunks/ssr/_0~7lwu_._.js.map +1 -1
- package/web/.next/server/chunks/ssr/_109n-y4._.js +1 -1
- package/web/.next/server/chunks/ssr/src_presentation_web_0.e4~xc._.js +1 -1
- package/web/.next/server/chunks/ssr/src_presentation_web_0.e4~xc._.js.map +1 -1
- package/web/.next/server/chunks/ssr/src_presentation_web_00dvh.m._.js +1 -1
- package/web/.next/server/chunks/ssr/src_presentation_web_00dvh.m._.js.map +1 -1
- package/web/.next/server/chunks/ssr/src_presentation_web_06b6~lt._.js +2 -2
- package/web/.next/server/chunks/ssr/src_presentation_web_06b6~lt._.js.map +1 -1
- package/web/.next/server/chunks/ssr/src_presentation_web_08fy2mf._.js +1 -1
- package/web/.next/server/chunks/ssr/src_presentation_web_08fy2mf._.js.map +1 -1
- package/web/.next/server/chunks/ssr/src_presentation_web_0f~udu1._.js +1 -1
- package/web/.next/server/chunks/ssr/src_presentation_web_0f~udu1._.js.map +1 -1
- package/web/.next/server/chunks/ssr/src_presentation_web_0qys821._.js +2 -2
- package/web/.next/server/chunks/ssr/src_presentation_web_0qys821._.js.map +1 -1
- package/web/.next/server/chunks/ssr/src_presentation_web_0q~dt0o._.js +1 -1
- package/web/.next/server/chunks/ssr/src_presentation_web_0q~dt0o._.js.map +1 -1
- package/web/.next/server/chunks/ssr/src_presentation_web_11jrkxt._.js +1 -1
- package/web/.next/server/chunks/ssr/src_presentation_web_11jrkxt._.js.map +1 -1
- package/web/.next/server/chunks/ssr/src_presentation_web__next-internal_server_app_(dashboard)_page_actions_1199d3x.js +1 -1
- package/web/.next/server/chunks/ssr/src_presentation_web__next-internal_server_app_(dashboard)_page_actions_1199d3x.js.map +1 -1
- package/web/.next/server/chunks/ssr/src_presentation_web__next-internal_server_app__not-found_page_actions_0m2jqxx.js +1 -1
- package/web/.next/server/chunks/ssr/src_presentation_web__next-internal_server_app__not-found_page_actions_0m2jqxx.js.map +1 -1
- package/web/.next/server/chunks/ssr/src_presentation_web__next-internal_server_app_version_page_actions_0krkh_0.js +1 -1
- package/web/.next/server/chunks/ssr/src_presentation_web__next-internal_server_app_version_page_actions_0krkh_0.js.map +1 -1
- package/web/.next/server/chunks/ssr/src_presentation_web_app_actions_load-settings_ts_0b8f3pf._.js +1 -1
- package/web/.next/server/chunks/ssr/src_presentation_web_app_actions_open-ide_ts_0w2wqvu._.js +1 -1
- package/web/.next/server/chunks/ssr/src_presentation_web_components_features_control-center_0l3oxx9._.js +1 -1
- package/web/.next/server/chunks/ssr/src_presentation_web_components_features_control-center_0l3oxx9._.js.map +1 -1
- package/web/.next/server/middleware-build-manifest.js +3 -3
- package/web/.next/server/pages/500.html +1 -1
- package/web/.next/server/server-reference-manifest.js +1 -1
- package/web/.next/server/server-reference-manifest.json +49 -49
- package/web/.next/static/chunks/{13ryk8qc9y3qu.js → 00dg6gti40.3i.js} +1 -1
- package/web/.next/static/chunks/{0ntps8p7wo1re.js → 09dqgshddfxff.js} +1 -1
- package/web/.next/static/chunks/{121l3o3vd~hvn.js → 0_--5mgqukm__.js} +1 -1
- package/web/.next/static/chunks/{0rfap2l5xz_-p.js → 0_c5~n__lz4ks.js} +1 -1
- package/web/.next/static/chunks/{0fmbl3o08a~-h.js → 0awttldb-.7m..js} +1 -1
- package/web/.next/static/chunks/{16jcg65-2mxc..js → 0d-2jp.f._l2e.js} +1 -1
- package/web/.next/static/chunks/{01hf_nf2ge.tn.js → 0ist7260j__0m.js} +2 -2
- package/web/.next/static/chunks/{0b_anwzlzr9p7.js → 0njrgvmyafrod.js} +1 -1
- package/web/.next/static/chunks/{0b01fd0lkhnzf.js → 0nk2r-18.7g6r.js} +1 -1
- package/web/.next/static/chunks/{00uywouqbytc0.js → 0ntgq3d_.m5el.js} +3 -3
- package/web/.next/static/chunks/{0rhoh5o1y7grf.js → 0t.pzrmeoq6th.js} +1 -1
- package/web/.next/static/chunks/{0sywjtf8m0_fb.js → 0t8zwgaz.d1s5.js} +1 -1
- package/web/.next/static/chunks/{0tutcr7trd_7d.js → 14g1l3~6i5251.js} +2 -2
- /package/web/.next/static/{21GZVGanhwKlq9p5dtTCB → ZpPnD_b687G9xVr2nzrds}/_buildManifest.js +0 -0
- /package/web/.next/static/{21GZVGanhwKlq9p5dtTCB → ZpPnD_b687G9xVr2nzrds}/_clientMiddlewareManifest.js +0 -0
- /package/web/.next/static/{21GZVGanhwKlq9p5dtTCB → ZpPnD_b687G9xVr2nzrds}/_ssgManifest.js +0 -0
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
module.exports=[60197,22018,a=>{"use strict";let b=(0,a.i(97624).default)("check",[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]]);a.s(["default",0,b],22018),a.s(["Check",0,b],60197)},53823,a=>{"use strict";var b=a.i(53083),c=a.i(11321),d=a.i(59653),e=a.i(80303),f=a.i(95819),g=a.i(49350),h=a.i(98340),i=a.i(39990),j=a.i(55277),k=a.i(29724),l=a.i(50608),m=a.i(73490),n=a.i(30419),o=a.i(92274),p=a.i(47427),q=a.i(16164),r=a.i(55571),s="Popover",[t,u]=(0,f.createContextScope)(s,[k.createPopperScope]),v=(0,k.createPopperScope)(),[w,x]=t(s),y=a=>{let{__scopePopover:d,children:e,open:f,defaultOpen:g,onOpenChange:h,modal:i=!1}=a,l=v(d),m=c.useRef(null),[n,o]=c.useState(!1),[q,r]=(0,p.useControllableState)({prop:f,defaultProp:g??!1,onChange:h,caller:s});return(0,b.jsx)(k.Root,{...l,children:(0,b.jsx)(w,{scope:d,contentId:(0,j.useId)(),triggerRef:m,open:q,onOpenChange:r,onOpenToggle:c.useCallback(()=>r(a=>!a),[r]),hasCustomAnchor:n,onCustomAnchorAdd:c.useCallback(()=>o(!0),[]),onCustomAnchorRemove:c.useCallback(()=>o(!1),[]),modal:i,children:e})})};y.displayName=s;var z="PopoverAnchor",A=c.forwardRef((a,d)=>{let{__scopePopover:e,...f}=a,g=x(z,e),h=v(e),{onCustomAnchorAdd:i,onCustomAnchorRemove:j}=g;return c.useEffect(()=>(i(),()=>j()),[i,j]),(0,b.jsx)(k.Anchor,{...h,...f,ref:d})});A.displayName=z;var B="PopoverTrigger",C=c.forwardRef((a,c)=>{let{__scopePopover:f,...g}=a,h=x(B,f),i=v(f),j=(0,e.useComposedRefs)(c,h.triggerRef),l=(0,b.jsx)(n.Primitive.button,{type:"button","aria-haspopup":"dialog","aria-expanded":h.open,"aria-controls":h.contentId,"data-state":Q(h.open),...g,ref:j,onClick:(0,d.composeEventHandlers)(a.onClick,h.onOpenToggle)});return h.hasCustomAnchor?l:(0,b.jsx)(k.Anchor,{asChild:!0,...i,children:l})});C.displayName=B;var D="PopoverPortal",[E,F]=t(D,{forceMount:void 0}),G=a=>{let{__scopePopover:c,forceMount:d,children:e,container:f}=a,g=x(D,c);return(0,b.jsx)(E,{scope:c,forceMount:d,children:(0,b.jsx)(m.Presence,{present:d||g.open,children:(0,b.jsx)(l.Portal,{asChild:!0,container:f,children:e})})})};G.displayName=D;var H="PopoverContent",I=c.forwardRef((a,c)=>{let d=F(H,a.__scopePopover),{forceMount:e=d.forceMount,...f}=a,g=x(H,a.__scopePopover);return(0,b.jsx)(m.Presence,{present:e||g.open,children:g.modal?(0,b.jsx)(K,{...f,ref:c}):(0,b.jsx)(L,{...f,ref:c})})});I.displayName=H;var J=(0,o.createSlot)("PopoverContent.RemoveScroll"),K=c.forwardRef((a,f)=>{let g=x(H,a.__scopePopover),h=c.useRef(null),i=(0,e.useComposedRefs)(f,h),j=c.useRef(!1);return c.useEffect(()=>{let a=h.current;if(a)return(0,q.hideOthers)(a)},[]),(0,b.jsx)(r.RemoveScroll,{as:J,allowPinchZoom:!0,children:(0,b.jsx)(M,{...a,ref:i,trapFocus:g.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:(0,d.composeEventHandlers)(a.onCloseAutoFocus,a=>{a.preventDefault(),j.current||g.triggerRef.current?.focus()}),onPointerDownOutside:(0,d.composeEventHandlers)(a.onPointerDownOutside,a=>{let b=a.detail.originalEvent,c=0===b.button&&!0===b.ctrlKey;j.current=2===b.button||c},{checkForDefaultPrevented:!1}),onFocusOutside:(0,d.composeEventHandlers)(a.onFocusOutside,a=>a.preventDefault(),{checkForDefaultPrevented:!1})})})}),L=c.forwardRef((a,d)=>{let e=x(H,a.__scopePopover),f=c.useRef(!1),g=c.useRef(!1);return(0,b.jsx)(M,{...a,ref:d,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:b=>{a.onCloseAutoFocus?.(b),b.defaultPrevented||(f.current||e.triggerRef.current?.focus(),b.preventDefault()),f.current=!1,g.current=!1},onInteractOutside:b=>{a.onInteractOutside?.(b),b.defaultPrevented||(f.current=!0,"pointerdown"===b.detail.originalEvent.type&&(g.current=!0));let c=b.target;e.triggerRef.current?.contains(c)&&b.preventDefault(),"focusin"===b.detail.originalEvent.type&&g.current&&b.preventDefault()}})}),M=c.forwardRef((a,c)=>{let{__scopePopover:d,trapFocus:e,onOpenAutoFocus:f,onCloseAutoFocus:j,disableOutsidePointerEvents:l,onEscapeKeyDown:m,onPointerDownOutside:n,onFocusOutside:o,onInteractOutside:p,...q}=a,r=x(H,d),s=v(d);return(0,h.useFocusGuards)(),(0,b.jsx)(i.FocusScope,{asChild:!0,loop:!0,trapped:e,onMountAutoFocus:f,onUnmountAutoFocus:j,children:(0,b.jsx)(g.DismissableLayer,{asChild:!0,disableOutsidePointerEvents:l,onInteractOutside:p,onEscapeKeyDown:m,onPointerDownOutside:n,onFocusOutside:o,onDismiss:()=>r.onOpenChange(!1),children:(0,b.jsx)(k.Content,{"data-state":Q(r.open),role:"dialog",id:r.contentId,...s,...q,ref:c,style:{...q.style,"--radix-popover-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-popover-content-available-width":"var(--radix-popper-available-width)","--radix-popover-content-available-height":"var(--radix-popper-available-height)","--radix-popover-trigger-width":"var(--radix-popper-anchor-width)","--radix-popover-trigger-height":"var(--radix-popper-anchor-height)"}})})})}),N="PopoverClose",O=c.forwardRef((a,c)=>{let{__scopePopover:e,...f}=a,g=x(N,e);return(0,b.jsx)(n.Primitive.button,{type:"button",...f,ref:c,onClick:(0,d.composeEventHandlers)(a.onClick,()=>g.onOpenChange(!1))})});O.displayName=N;var P=c.forwardRef((a,c)=>{let{__scopePopover:d,...e}=a,f=v(d);return(0,b.jsx)(k.Arrow,{...f,...e,ref:c})});function Q(a){return a?"open":"closed"}P.displayName="PopoverArrow",a.s(["Anchor",0,A,"Arrow",0,P,"Close",0,O,"Content",0,I,"Popover",0,y,"PopoverAnchor",0,A,"PopoverArrow",0,P,"PopoverClose",0,O,"PopoverContent",0,I,"PopoverPortal",0,G,"PopoverTrigger",0,C,"Portal",0,G,"Root",0,y,"Trigger",0,C,"createPopoverScope",0,u],97514);var R=a.i(97514),R=R,S=a.i(85536);let T=R.Root,U=R.Trigger;R.Anchor;let V=c.forwardRef(({className:a,align:c="center",sideOffset:d=4,...e},f)=>(0,b.jsx)(R.Portal,{children:(0,b.jsx)(R.Content,{ref:f,align:c,sideOffset:d,className:(0,S.cn)("bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 z-50 w-72 rounded-md border p-4 shadow-md outline-none",a),...e})}));V.displayName=R.Content.displayName,a.s(["Popover",0,T,"PopoverContent",0,V,"PopoverTrigger",0,U],53823)},58339,a=>{"use strict";var b=a.i(53083),c=a.i(42261),d=a.i(85536);let e=(0,c.cva)("inline-flex items-center rounded-md border px-2.5 py-0.5 text-xs font-semibold transition-colors focus:ring-2 focus:ring-ring focus:ring-offset-2 focus:outline-none",{variants:{variant:{default:"border-transparent bg-primary text-primary-foreground shadow hover:bg-primary/80",secondary:"border-transparent bg-secondary text-secondary-foreground hover:bg-secondary/80",destructive:"border-transparent bg-destructive text-destructive-foreground shadow hover:bg-destructive/80",outline:"text-foreground"}},defaultVariants:{variant:"default"}});a.s(["Badge",0,function({className:a,variant:c,...f}){return(0,b.jsx)("div",{className:(0,d.cn)(e({variant:c}),a),...f})}])},54233,(a,b,c)=>{"use strict";Object.defineProperty(c,"__esModule",{value:!0}),Object.defineProperty(c,"useMergedRef",{enumerable:!0,get:function(){return e}});let d=a.r(11321);function e(a,b){let c=(0,d.useRef)(null),e=(0,d.useRef)(null);return(0,d.useCallback)(d=>{if(null===d){let a=c.current;a&&(c.current=null,a());let b=e.current;b&&(e.current=null,b())}else a&&(c.current=f(a,d)),b&&(e.current=f(b,d))},[a,b])}function f(a,b){if("function"!=typeof a)return a.current=b,()=>{a.current=null};{let c=a(b);return"function"==typeof c?c:()=>a(null)}}("function"==typeof c.default||"object"==typeof c.default&&null!==c.default)&&void 0===c.default.__esModule&&(Object.defineProperty(c.default,"__esModule",{value:!0}),Object.assign(c.default,c),b.exports=c.default)},92527,(a,b,c)=>{"use strict";Object.defineProperty(c,"__esModule",{value:!0}),Object.defineProperty(c,"warnOnce",{enumerable:!0,get:function(){return d}});let d=a=>{}},99760,(a,b,c)=>{"use strict";let d;Object.defineProperty(c,"__esModule",{value:!0});var e={getAssetToken:function(){return i},getAssetTokenQuery:function(){return j},getDeploymentId:function(){return g},getDeploymentIdQuery:function(){return h}};for(var f in e)Object.defineProperty(c,f,{enumerable:!0,get:e[f]});function g(){return d}function h(a=!1){return d?`${a?"&":"?"}dpl=${d}`:""}function i(){return!1}function j(a=!1){return""}d=void 0},61781,a=>{"use strict";var b=a.i(53083),c=a.i(11321),d=a.i(60197),e=a.i(40227),f=a.i(38776);a.i(98617);var g=a.i(50040),h=a.i(40179),i=a.i(35571),j=a.i(17606),k=a.i(83852),l=a.i(58339),m=a.i(18948),n=a.i(53823),o=a.i(85536);a.s(["AgentModelPicker",0,function({initialAgentType:a,initialModel:p,onAgentModelChange:q,disabled:r,className:s,mode:t}){let{t:u}=(0,g.useTranslation)("web"),[v,w]=c.useState(!1),[x,y]=c.useState([]),[z,A]=c.useState(!0),[B,C]=c.useState(a),[D,E]=c.useState(p),[F,G]=c.useState(null),[H,I]=c.useState(0),[J,K]=c.useState(null);c.useEffect(()=>{(0,h.getAllAgentModels)().then(y).finally(()=>A(!1))},[]),c.useEffect(()=>{if(!v){let a=setTimeout(()=>{I(0),K(null)},150);return()=>clearTimeout(a)}},[v]);let L=async(a,b)=>{if(w(!1),a!==B||b!==D){if("override"===t){C(a),E(b),q?.(a,b);return}C(a),E(b),q?.(a,b),G(null);try{let c=await (0,i.updateAgentAndModel)(a,b||null);c.ok||(C(B),E(D),q?.(B,D),G(c.error??"Failed to save"))}catch{C(B),E(D),q?.(B,D),G("Failed to save")}}},M=(0,j.getAgentTypeIcon)(B),N=x.find(a=>a.agentType===B)?.label??B,O=D?(0,k.getModelMeta)(D).displayName||D:null,P=J?x.find(a=>a.agentType===J):null;return(0,b.jsxs)("div",{className:(0,o.cn)("flex flex-col gap-1",s),children:[(0,b.jsxs)(n.Popover,{open:v,onOpenChange:w,children:[(0,b.jsx)(n.PopoverTrigger,{asChild:!0,children:(0,b.jsx)(m.Button,{type:"button",variant:"outline",role:"combobox","aria-expanded":v,"aria-invalid":!!F,"aria-describedby":F?"agent-model-picker-error":void 0,disabled:(r??!1)||z,className:"w-auto cursor-pointer justify-start font-normal hover:border-violet-300 hover:bg-violet-50/50 dark:hover:border-violet-700 dark:hover:bg-violet-950/30",children:(0,b.jsxs)("span",{className:"flex items-center gap-2 truncate",children:[(0,b.jsx)(M,{className:"h-4 w-4 shrink-0"}),z?"Loading…":(0,b.jsxs)("span",{className:"flex items-center gap-1",children:[(0,b.jsx)("span",{className:"text-muted-foreground text-xs",children:N}),O?(0,b.jsxs)(b.Fragment,{children:[(0,b.jsx)("span",{className:"text-muted-foreground/50 text-xs",children:"·"}),(0,b.jsx)("span",{className:"text-xs font-medium",children:O})]}):null]})]})})}),(0,b.jsx)(n.PopoverContent,{className:"z-[70] w-(--radix-popover-trigger-width) overflow-hidden p-0",align:"start",children:(0,b.jsxs)("div",{className:"flex transition-transform duration-200 ease-in-out",style:{transform:`translateX(${1===H?"-50%":"0%"})`,width:"200%"},children:[(0,b.jsxs)("div",{className:"w-1/2 shrink-0",children:[(0,b.jsx)("div",{className:"text-muted-foreground border-b px-3 py-2 text-xs font-medium",children:"Select agent"}),x.map(a=>{let c=(0,j.getAgentTypeIcon)(a.agentType),e=B===a.agentType,g=a.models.length>0;return(0,b.jsxs)("button",{type:"button",disabled:!a.installed,className:(0,o.cn)("flex w-full items-center gap-2.5 px-3 py-2 text-xs transition-colors",a.installed?"hover:bg-accent hover:text-accent-foreground cursor-pointer":"cursor-not-allowed opacity-60",e&&"bg-accent/50"),onClick:()=>{a.installed&&(g?(K(a.agentType),requestAnimationFrame(()=>{requestAnimationFrame(()=>I(1))})):L(a.agentType,""))},children:[(0,b.jsx)(c,{className:"h-4 w-4 shrink-0"}),(0,b.jsx)("span",{className:"flex-1 text-start",children:a.label}),(0,b.jsx)(l.Badge,{variant:"outline",className:(0,o.cn)("px-1.5 py-0 text-[10px] leading-4 font-normal",a.installed?"border-emerald-500/30 text-emerald-500":"border-muted-foreground/30 text-muted-foreground"),children:a.installed?u("settings.environment.installed"):u("settings.environment.notInstalled")}),e&&!g?(0,b.jsx)(d.Check,{className:"text-primary h-3.5 w-3.5 shrink-0"}):null,g&&a.installed?(0,b.jsx)(f.ChevronRight,{className:"text-muted-foreground h-3.5 w-3.5 shrink-0"}):null]},a.agentType)})]}),(0,b.jsx)("div",{className:"w-1/2 shrink-0",children:P?(0,b.jsxs)(b.Fragment,{children:[(0,b.jsxs)("button",{type:"button",className:"text-muted-foreground hover:text-foreground flex w-full cursor-pointer items-center gap-1.5 border-b px-3 py-2 text-xs font-medium transition-colors",onClick:()=>{I(0),setTimeout(()=>K(null),220)},children:[(0,b.jsx)(e.ChevronLeft,{className:"h-3.5 w-3.5"}),P.label]}),P.models.map(a=>{let c=B===P.agentType&&D===a.id;return(0,b.jsxs)("button",{type:"button",className:(0,o.cn)("flex w-full cursor-pointer items-center gap-3 px-3 py-2 text-start transition-colors","hover:bg-accent hover:text-accent-foreground",c&&"bg-accent/50"),onClick:()=>L(P.agentType,a.id),children:[(0,b.jsxs)("div",{className:"flex min-w-0 flex-1 flex-col",children:[(0,b.jsx)("span",{className:"text-xs font-medium",children:a.displayName}),(0,b.jsx)("span",{className:"text-muted-foreground text-xs",children:a.description})]}),c?(0,b.jsx)(d.Check,{className:"text-primary h-3.5 w-3.5 shrink-0"}):null]},a.id)})]}):null})]})})]}),!!F&&(0,b.jsx)("p",{id:"agent-model-picker-error",className:"text-destructive text-sm",role:"alert",children:F})]})}])},14068,a=>{"use strict";let b=(0,a.i(97624).default)("code",[["path",{d:"m16 18 6-6-6-6",key:"eg8j8"}],["path",{d:"m8 6-6 6 6 6",key:"ppft3o"}]]);a.s(["default",0,b])}];
|
|
1
|
+
module.exports=[60197,22018,a=>{"use strict";let b=(0,a.i(97624).default)("check",[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]]);a.s(["default",0,b],22018),a.s(["Check",0,b],60197)},53823,a=>{"use strict";var b=a.i(53083),c=a.i(11321),d=a.i(59653),e=a.i(80303),f=a.i(95819),g=a.i(49350),h=a.i(98340),i=a.i(39990),j=a.i(55277),k=a.i(29724),l=a.i(50608),m=a.i(73490),n=a.i(30419),o=a.i(92274),p=a.i(47427),q=a.i(16164),r=a.i(55571),s="Popover",[t,u]=(0,f.createContextScope)(s,[k.createPopperScope]),v=(0,k.createPopperScope)(),[w,x]=t(s),y=a=>{let{__scopePopover:d,children:e,open:f,defaultOpen:g,onOpenChange:h,modal:i=!1}=a,l=v(d),m=c.useRef(null),[n,o]=c.useState(!1),[q,r]=(0,p.useControllableState)({prop:f,defaultProp:g??!1,onChange:h,caller:s});return(0,b.jsx)(k.Root,{...l,children:(0,b.jsx)(w,{scope:d,contentId:(0,j.useId)(),triggerRef:m,open:q,onOpenChange:r,onOpenToggle:c.useCallback(()=>r(a=>!a),[r]),hasCustomAnchor:n,onCustomAnchorAdd:c.useCallback(()=>o(!0),[]),onCustomAnchorRemove:c.useCallback(()=>o(!1),[]),modal:i,children:e})})};y.displayName=s;var z="PopoverAnchor",A=c.forwardRef((a,d)=>{let{__scopePopover:e,...f}=a,g=x(z,e),h=v(e),{onCustomAnchorAdd:i,onCustomAnchorRemove:j}=g;return c.useEffect(()=>(i(),()=>j()),[i,j]),(0,b.jsx)(k.Anchor,{...h,...f,ref:d})});A.displayName=z;var B="PopoverTrigger",C=c.forwardRef((a,c)=>{let{__scopePopover:f,...g}=a,h=x(B,f),i=v(f),j=(0,e.useComposedRefs)(c,h.triggerRef),l=(0,b.jsx)(n.Primitive.button,{type:"button","aria-haspopup":"dialog","aria-expanded":h.open,"aria-controls":h.contentId,"data-state":Q(h.open),...g,ref:j,onClick:(0,d.composeEventHandlers)(a.onClick,h.onOpenToggle)});return h.hasCustomAnchor?l:(0,b.jsx)(k.Anchor,{asChild:!0,...i,children:l})});C.displayName=B;var D="PopoverPortal",[E,F]=t(D,{forceMount:void 0}),G=a=>{let{__scopePopover:c,forceMount:d,children:e,container:f}=a,g=x(D,c);return(0,b.jsx)(E,{scope:c,forceMount:d,children:(0,b.jsx)(m.Presence,{present:d||g.open,children:(0,b.jsx)(l.Portal,{asChild:!0,container:f,children:e})})})};G.displayName=D;var H="PopoverContent",I=c.forwardRef((a,c)=>{let d=F(H,a.__scopePopover),{forceMount:e=d.forceMount,...f}=a,g=x(H,a.__scopePopover);return(0,b.jsx)(m.Presence,{present:e||g.open,children:g.modal?(0,b.jsx)(K,{...f,ref:c}):(0,b.jsx)(L,{...f,ref:c})})});I.displayName=H;var J=(0,o.createSlot)("PopoverContent.RemoveScroll"),K=c.forwardRef((a,f)=>{let g=x(H,a.__scopePopover),h=c.useRef(null),i=(0,e.useComposedRefs)(f,h),j=c.useRef(!1);return c.useEffect(()=>{let a=h.current;if(a)return(0,q.hideOthers)(a)},[]),(0,b.jsx)(r.RemoveScroll,{as:J,allowPinchZoom:!0,children:(0,b.jsx)(M,{...a,ref:i,trapFocus:g.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:(0,d.composeEventHandlers)(a.onCloseAutoFocus,a=>{a.preventDefault(),j.current||g.triggerRef.current?.focus()}),onPointerDownOutside:(0,d.composeEventHandlers)(a.onPointerDownOutside,a=>{let b=a.detail.originalEvent,c=0===b.button&&!0===b.ctrlKey;j.current=2===b.button||c},{checkForDefaultPrevented:!1}),onFocusOutside:(0,d.composeEventHandlers)(a.onFocusOutside,a=>a.preventDefault(),{checkForDefaultPrevented:!1})})})}),L=c.forwardRef((a,d)=>{let e=x(H,a.__scopePopover),f=c.useRef(!1),g=c.useRef(!1);return(0,b.jsx)(M,{...a,ref:d,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:b=>{a.onCloseAutoFocus?.(b),b.defaultPrevented||(f.current||e.triggerRef.current?.focus(),b.preventDefault()),f.current=!1,g.current=!1},onInteractOutside:b=>{a.onInteractOutside?.(b),b.defaultPrevented||(f.current=!0,"pointerdown"===b.detail.originalEvent.type&&(g.current=!0));let c=b.target;e.triggerRef.current?.contains(c)&&b.preventDefault(),"focusin"===b.detail.originalEvent.type&&g.current&&b.preventDefault()}})}),M=c.forwardRef((a,c)=>{let{__scopePopover:d,trapFocus:e,onOpenAutoFocus:f,onCloseAutoFocus:j,disableOutsidePointerEvents:l,onEscapeKeyDown:m,onPointerDownOutside:n,onFocusOutside:o,onInteractOutside:p,...q}=a,r=x(H,d),s=v(d);return(0,h.useFocusGuards)(),(0,b.jsx)(i.FocusScope,{asChild:!0,loop:!0,trapped:e,onMountAutoFocus:f,onUnmountAutoFocus:j,children:(0,b.jsx)(g.DismissableLayer,{asChild:!0,disableOutsidePointerEvents:l,onInteractOutside:p,onEscapeKeyDown:m,onPointerDownOutside:n,onFocusOutside:o,onDismiss:()=>r.onOpenChange(!1),children:(0,b.jsx)(k.Content,{"data-state":Q(r.open),role:"dialog",id:r.contentId,...s,...q,ref:c,style:{...q.style,"--radix-popover-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-popover-content-available-width":"var(--radix-popper-available-width)","--radix-popover-content-available-height":"var(--radix-popper-available-height)","--radix-popover-trigger-width":"var(--radix-popper-anchor-width)","--radix-popover-trigger-height":"var(--radix-popper-anchor-height)"}})})})}),N="PopoverClose",O=c.forwardRef((a,c)=>{let{__scopePopover:e,...f}=a,g=x(N,e);return(0,b.jsx)(n.Primitive.button,{type:"button",...f,ref:c,onClick:(0,d.composeEventHandlers)(a.onClick,()=>g.onOpenChange(!1))})});O.displayName=N;var P=c.forwardRef((a,c)=>{let{__scopePopover:d,...e}=a,f=v(d);return(0,b.jsx)(k.Arrow,{...f,...e,ref:c})});function Q(a){return a?"open":"closed"}P.displayName="PopoverArrow",a.s(["Anchor",0,A,"Arrow",0,P,"Close",0,O,"Content",0,I,"Popover",0,y,"PopoverAnchor",0,A,"PopoverArrow",0,P,"PopoverClose",0,O,"PopoverContent",0,I,"PopoverPortal",0,G,"PopoverTrigger",0,C,"Portal",0,G,"Root",0,y,"Trigger",0,C,"createPopoverScope",0,u],97514);var R=a.i(97514),R=R,S=a.i(85536);let T=R.Root,U=R.Trigger;R.Anchor;let V=c.forwardRef(({className:a,align:c="center",sideOffset:d=4,...e},f)=>(0,b.jsx)(R.Portal,{children:(0,b.jsx)(R.Content,{ref:f,align:c,sideOffset:d,className:(0,S.cn)("bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 z-50 w-72 rounded-md border p-4 shadow-md outline-none",a),...e})}));V.displayName=R.Content.displayName,a.s(["Popover",0,T,"PopoverContent",0,V,"PopoverTrigger",0,U],53823)},58339,a=>{"use strict";var b=a.i(53083),c=a.i(42261),d=a.i(85536);let e=(0,c.cva)("inline-flex items-center rounded-md border px-2.5 py-0.5 text-xs font-semibold transition-colors focus:ring-2 focus:ring-ring focus:ring-offset-2 focus:outline-none",{variants:{variant:{default:"border-transparent bg-primary text-primary-foreground shadow hover:bg-primary/80",secondary:"border-transparent bg-secondary text-secondary-foreground hover:bg-secondary/80",destructive:"border-transparent bg-destructive text-destructive-foreground shadow hover:bg-destructive/80",outline:"text-foreground"}},defaultVariants:{variant:"default"}});a.s(["Badge",0,function({className:a,variant:c,...f}){return(0,b.jsx)("div",{className:(0,d.cn)(e({variant:c}),a),...f})}])},54233,(a,b,c)=>{"use strict";Object.defineProperty(c,"__esModule",{value:!0}),Object.defineProperty(c,"useMergedRef",{enumerable:!0,get:function(){return e}});let d=a.r(11321);function e(a,b){let c=(0,d.useRef)(null),e=(0,d.useRef)(null);return(0,d.useCallback)(d=>{if(null===d){let a=c.current;a&&(c.current=null,a());let b=e.current;b&&(e.current=null,b())}else a&&(c.current=f(a,d)),b&&(e.current=f(b,d))},[a,b])}function f(a,b){if("function"!=typeof a)return a.current=b,()=>{a.current=null};{let c=a(b);return"function"==typeof c?c:()=>a(null)}}("function"==typeof c.default||"object"==typeof c.default&&null!==c.default)&&void 0===c.default.__esModule&&(Object.defineProperty(c.default,"__esModule",{value:!0}),Object.assign(c.default,c),b.exports=c.default)},92527,(a,b,c)=>{"use strict";Object.defineProperty(c,"__esModule",{value:!0}),Object.defineProperty(c,"warnOnce",{enumerable:!0,get:function(){return d}});let d=a=>{}},99760,(a,b,c)=>{"use strict";let d;Object.defineProperty(c,"__esModule",{value:!0});var e={getAssetToken:function(){return i},getAssetTokenQuery:function(){return j},getDeploymentId:function(){return g},getDeploymentIdQuery:function(){return h}};for(var f in e)Object.defineProperty(c,f,{enumerable:!0,get:e[f]});function g(){return d}function h(a=!1){return d?`${a?"&":"?"}dpl=${d}`:""}function i(){return!1}function j(a=!1){return""}d=void 0},61781,a=>{"use strict";var b=a.i(53083),c=a.i(11321),d=a.i(60197),e=a.i(40227),f=a.i(38776);a.i(98617);var g=a.i(50040),h=a.i(22052),i=a.i(41665),j=a.i(17606),k=a.i(83852),l=a.i(58339),m=a.i(18948),n=a.i(53823),o=a.i(85536);a.s(["AgentModelPicker",0,function({initialAgentType:a,initialModel:p,onAgentModelChange:q,disabled:r,className:s,mode:t}){let{t:u}=(0,g.useTranslation)("web"),[v,w]=c.useState(!1),[x,y]=c.useState([]),[z,A]=c.useState(!0),[B,C]=c.useState(a),[D,E]=c.useState(p),[F,G]=c.useState(null),[H,I]=c.useState(0),[J,K]=c.useState(null);c.useEffect(()=>{(0,h.getAllAgentModels)().then(y).finally(()=>A(!1))},[]),c.useEffect(()=>{if(!v){let a=setTimeout(()=>{I(0),K(null)},150);return()=>clearTimeout(a)}},[v]);let L=async(a,b)=>{if(w(!1),a!==B||b!==D){if("override"===t){C(a),E(b),q?.(a,b);return}C(a),E(b),q?.(a,b),G(null);try{let c=await (0,i.updateAgentAndModel)(a,b||null);c.ok||(C(B),E(D),q?.(B,D),G(c.error??"Failed to save"))}catch{C(B),E(D),q?.(B,D),G("Failed to save")}}},M=(0,j.getAgentTypeIcon)(B),N=x.find(a=>a.agentType===B)?.label??B,O=D?(0,k.getModelMeta)(D).displayName||D:null,P=J?x.find(a=>a.agentType===J):null;return(0,b.jsxs)("div",{className:(0,o.cn)("flex flex-col gap-1",s),children:[(0,b.jsxs)(n.Popover,{open:v,onOpenChange:w,children:[(0,b.jsx)(n.PopoverTrigger,{asChild:!0,children:(0,b.jsx)(m.Button,{type:"button",variant:"outline",role:"combobox","aria-expanded":v,"aria-invalid":!!F,"aria-describedby":F?"agent-model-picker-error":void 0,disabled:(r??!1)||z,className:"w-auto cursor-pointer justify-start font-normal hover:border-violet-300 hover:bg-violet-50/50 dark:hover:border-violet-700 dark:hover:bg-violet-950/30",children:(0,b.jsxs)("span",{className:"flex items-center gap-2 truncate",children:[(0,b.jsx)(M,{className:"h-4 w-4 shrink-0"}),z?"Loading…":(0,b.jsxs)("span",{className:"flex items-center gap-1",children:[(0,b.jsx)("span",{className:"text-muted-foreground text-xs",children:N}),O?(0,b.jsxs)(b.Fragment,{children:[(0,b.jsx)("span",{className:"text-muted-foreground/50 text-xs",children:"·"}),(0,b.jsx)("span",{className:"text-xs font-medium",children:O})]}):null]})]})})}),(0,b.jsx)(n.PopoverContent,{className:"z-[70] w-(--radix-popover-trigger-width) overflow-hidden p-0",align:"start",children:(0,b.jsxs)("div",{className:"flex transition-transform duration-200 ease-in-out",style:{transform:`translateX(${1===H?"-50%":"0%"})`,width:"200%"},children:[(0,b.jsxs)("div",{className:"w-1/2 shrink-0",children:[(0,b.jsx)("div",{className:"text-muted-foreground border-b px-3 py-2 text-xs font-medium",children:"Select agent"}),x.map(a=>{let c=(0,j.getAgentTypeIcon)(a.agentType),e=B===a.agentType,g=a.models.length>0;return(0,b.jsxs)("button",{type:"button",disabled:!a.installed,className:(0,o.cn)("flex w-full items-center gap-2.5 px-3 py-2 text-xs transition-colors",a.installed?"hover:bg-accent hover:text-accent-foreground cursor-pointer":"cursor-not-allowed opacity-60",e&&"bg-accent/50"),onClick:()=>{a.installed&&(g?(K(a.agentType),requestAnimationFrame(()=>{requestAnimationFrame(()=>I(1))})):L(a.agentType,""))},children:[(0,b.jsx)(c,{className:"h-4 w-4 shrink-0"}),(0,b.jsx)("span",{className:"flex-1 text-start",children:a.label}),(0,b.jsx)(l.Badge,{variant:"outline",className:(0,o.cn)("px-1.5 py-0 text-[10px] leading-4 font-normal",a.installed?"border-emerald-500/30 text-emerald-500":"border-muted-foreground/30 text-muted-foreground"),children:a.installed?u("settings.environment.installed"):u("settings.environment.notInstalled")}),e&&!g?(0,b.jsx)(d.Check,{className:"text-primary h-3.5 w-3.5 shrink-0"}):null,g&&a.installed?(0,b.jsx)(f.ChevronRight,{className:"text-muted-foreground h-3.5 w-3.5 shrink-0"}):null]},a.agentType)})]}),(0,b.jsx)("div",{className:"w-1/2 shrink-0",children:P?(0,b.jsxs)(b.Fragment,{children:[(0,b.jsxs)("button",{type:"button",className:"text-muted-foreground hover:text-foreground flex w-full cursor-pointer items-center gap-1.5 border-b px-3 py-2 text-xs font-medium transition-colors",onClick:()=>{I(0),setTimeout(()=>K(null),220)},children:[(0,b.jsx)(e.ChevronLeft,{className:"h-3.5 w-3.5"}),P.label]}),P.models.map(a=>{let c=B===P.agentType&&D===a.id;return(0,b.jsxs)("button",{type:"button",className:(0,o.cn)("flex w-full cursor-pointer items-center gap-3 px-3 py-2 text-start transition-colors","hover:bg-accent hover:text-accent-foreground",c&&"bg-accent/50"),onClick:()=>L(P.agentType,a.id),children:[(0,b.jsxs)("div",{className:"flex min-w-0 flex-1 flex-col",children:[(0,b.jsx)("span",{className:"text-xs font-medium",children:a.displayName}),(0,b.jsx)("span",{className:"text-muted-foreground text-xs",children:a.description})]}),c?(0,b.jsx)(d.Check,{className:"text-primary h-3.5 w-3.5 shrink-0"}):null]},a.id)})]}):null})]})})]}),!!F&&(0,b.jsx)("p",{id:"agent-model-picker-error",className:"text-destructive text-sm",role:"alert",children:F})]})}])},14068,a=>{"use strict";let b=(0,a.i(97624).default)("code",[["path",{d:"m16 18 6-6-6-6",key:"eg8j8"}],["path",{d:"m8 6-6 6 6 6",key:"ppft3o"}]]);a.s(["default",0,b])}];
|
|
2
2
|
|
|
3
3
|
//# sourceMappingURL=_109n-y4._.js.map
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
module.exports=[35556,a=>{"use strict";var b=a.i(2211),c=a.i(74533),d=a.i(12057),e=a.i(50961);let f=(0,d.promisify)(c.execFile);async function g(a,b){let{stdout:c}=await f("git",b,{cwd:a,timeout:5e3});return c.trim()}async function h(a,b=8){if(!a.trim())return{commits:[],branches:[],remotes:[],tags:[],stashCount:0,currentBranch:"",diffStats:null,workingTree:{staged:0,modified:0,untracked:0},error:"Repository path is required"};let c=await Promise.allSettled([g(a,["log",`--max-count=${b}`,"--format=%H%x00%h%x00%s%x00%an%x00%cr","--no-color"]),g(a,["branch","--show-current"]),g(a,["branch","--sort=-committerdate","--format=%(HEAD)%(refname:short)%00%(committerdate:relative)","--no-color"]),g(a,["remote","-v"]),g(a,["tag","--sort=-creatordate","-l","--format=%(refname:short)"]),g(a,["stash","list"]),g(a,["status","--porcelain"]),g(a,["diff","--shortstat"])]),d=a=>"fulfilled"===c[a].status?c[a].value:"",e=d(0).split("\n").filter(Boolean).map(a=>{let[b,c,d,e,f]=a.split("\0");return{hash:b,shortHash:c,subject:d,author:e,relativeDate:f}}),f=d(1);e.length>0&&f&&(e[0].branch=f);let i=d(2).split("\n").filter(Boolean).slice(0,10).map(a=>{let b=a.startsWith("*"),[c,d]=(b?a.slice(1):a).split("\0");return{name:c.trim(),isCurrent:b,lastCommitDate:d?.trim()??""}}),j=new Map;d(3).split("\n").filter(Boolean).forEach(a=>{let b=a.match(/^(\S+)\s+(\S+)\s+\(fetch\)/);if(b){let a=b[2].replace(/\/\/[^@]+@/,"//").replace(/x-access-token:[^@]+@/,"");j.set(b[1],a)}});let k=Array.from(j,([a,b])=>({name:a,url:b})),l=d(4).split("\n").filter(Boolean).slice(0,5),m=d(5).split("\n").filter(Boolean).length,n=d(6).split("\n").filter(Boolean),o={staged:0,modified:0,untracked:0};for(let a of n){let b=a[0],c=a[1];"?"===b&&"?"===c?o.untracked++:" "!==b&&"?"!==b&&o.staged++," "!==c&&"?"!==c&&o.modified++}let p=null,q=d(7);if(q){let a=q.match(/(\d+) file/),b=q.match(/(\d+) insertion/),c=q.match(/(\d+) deletion/);p={filesChanged:a?parseInt(a[1],10):0,insertions:b?parseInt(b[1],10):0,deletions:c?parseInt(c[1],10):0}}return{commits:e,branches:i,remotes:k,tags:l,stashCount:m,currentBranch:f,diffStats:p,workingTree:o}}async function i(a,b=10){let c=await h(a,b);return{entries:c.commits,error:c.error}}(0,e.ensureServerEntryExports)([h,i]),(0,b.registerServerReference)(h,"
|
|
1
|
+
module.exports=[35556,a=>{"use strict";var b=a.i(2211),c=a.i(74533),d=a.i(12057),e=a.i(50961);let f=(0,d.promisify)(c.execFile);async function g(a,b){let{stdout:c}=await f("git",b,{cwd:a,timeout:5e3});return c.trim()}async function h(a,b=8){if(!a.trim())return{commits:[],branches:[],remotes:[],tags:[],stashCount:0,currentBranch:"",diffStats:null,workingTree:{staged:0,modified:0,untracked:0},error:"Repository path is required"};let c=await Promise.allSettled([g(a,["log",`--max-count=${b}`,"--format=%H%x00%h%x00%s%x00%an%x00%cr","--no-color"]),g(a,["branch","--show-current"]),g(a,["branch","--sort=-committerdate","--format=%(HEAD)%(refname:short)%00%(committerdate:relative)","--no-color"]),g(a,["remote","-v"]),g(a,["tag","--sort=-creatordate","-l","--format=%(refname:short)"]),g(a,["stash","list"]),g(a,["status","--porcelain"]),g(a,["diff","--shortstat"])]),d=a=>"fulfilled"===c[a].status?c[a].value:"",e=d(0).split("\n").filter(Boolean).map(a=>{let[b,c,d,e,f]=a.split("\0");return{hash:b,shortHash:c,subject:d,author:e,relativeDate:f}}),f=d(1);e.length>0&&f&&(e[0].branch=f);let i=d(2).split("\n").filter(Boolean).slice(0,10).map(a=>{let b=a.startsWith("*"),[c,d]=(b?a.slice(1):a).split("\0");return{name:c.trim(),isCurrent:b,lastCommitDate:d?.trim()??""}}),j=new Map;d(3).split("\n").filter(Boolean).forEach(a=>{let b=a.match(/^(\S+)\s+(\S+)\s+\(fetch\)/);if(b){let a=b[2].replace(/\/\/[^@]+@/,"//").replace(/x-access-token:[^@]+@/,"");j.set(b[1],a)}});let k=Array.from(j,([a,b])=>({name:a,url:b})),l=d(4).split("\n").filter(Boolean).slice(0,5),m=d(5).split("\n").filter(Boolean).length,n=d(6).split("\n").filter(Boolean),o={staged:0,modified:0,untracked:0};for(let a of n){let b=a[0],c=a[1];"?"===b&&"?"===c?o.untracked++:" "!==b&&"?"!==b&&o.staged++," "!==c&&"?"!==c&&o.modified++}let p=null,q=d(7);if(q){let a=q.match(/(\d+) file/),b=q.match(/(\d+) insertion/),c=q.match(/(\d+) deletion/);p={filesChanged:a?parseInt(a[1],10):0,insertions:b?parseInt(b[1],10):0,deletions:c?parseInt(c[1],10):0}}return{commits:e,branches:i,remotes:k,tags:l,stashCount:m,currentBranch:f,diffStats:p,workingTree:o}}async function i(a,b=10){let c=await h(a,b);return{entries:c.commits,error:c.error}}(0,e.ensureServerEntryExports)([h,i]),(0,b.registerServerReference)(h,"60677743b16cef93db184f364ea5d4365577e4ff10",null),(0,b.registerServerReference)(i,"605b636556deda767073e576fa60082cf49d414ba8",null),a.s(["getGitRepoInfo",0,h])},68671,a=>{"use strict";var b=a.i(23504),c=a.i(27900),d=a.i(12513),e=a.i(73101),f=a.i(54775),g=a.i(65324),h=a.i(33841),i=a.i(46646),j=a.i(68670),k=a.i(85321),l=a.i(84095),m=a.i(56799),n=a.i(80496),o=a.i(93225),p=a.i(94691),q=a.i(41872),r=a.i(9959),s=a.i(79124),t=a.i(29207),u=a.i(10528),v=a.i(50845),w=a.i(26604),x=a.i(54723),y=a.i(18942),z=a.i(42886),A=a.i(49560),B=a.i(39353),C=a.i(35556);a.s([],28434),a.i(28434),a.s(["0060e775107df16b7b19d6e47a7415dd6aedad7619",()=>r.checkAgentAuth,"006d6a821da9c521f994872f6661ea6406703cf09d",()=>q.isAgentSetupComplete,"007f77d6c65b2ddc62646c97be4a2683c8426167b6",()=>f.listGitHubOrganizations,"00928d754474788ad4c6fbbffcf4486c641fc91c3c",()=>d.pickFolder,"009df0ec5808a1a338bfdec3c05ddefa2e7406617a",()=>s.checkToolStatus,"00b5162135ada648e72b38230e961529be25dd7bd8",()=>b.getAllAgentModels,"40090d50d2dfeaaa5c021cfb7c005a37c84488a7f7",()=>B.deleteRepository,"401b1c4187ac45173c36e173144ba201fe13d45124",()=>e.listGitHubRepositories,"40217ab39df4c598292e413589a39a03ff1567821b",()=>x.startFeature,"402a5001445d8c354653c4a59447732df930eeeae9",()=>w.resumeFeature,"402daf0bf817e3bbe4129f413ff47d052ad354069c",()=>j.stopDeployment,"40306a89a2c907442e515b25e00379f8fd0b4403d3",()=>t.getFeatureMetadata,"4031454b289e8be2efef97c9616a65533d8a72eb59",()=>o.syncRepository,"403b83d2370ec6d9446fd573f8c6c439e91d1aeca2",()=>h.deployFeature,"405314689dc2fdc3d3267320760cc2912860068706",()=>y.stopFeature,"4056493ad4e1f0b52d9ffb6cd926ce616630546083",()=>z.unarchiveFeature,"406aac6bb69cb2108ce05345c74e9fb7e72dffe3b0",()=>n.openFolder,"40885ae2064e9aa9d12636caabc74c8e36c76939e2",()=>A.addRepository,"408fc9ecc49078119e2600dc1a653a7767b846537c",()=>k.getDeploymentStatus,"409c6a3d317fe8f02d58823e588796a071e81be44f",()=>u.archiveFeature,"40a100fcddf4b7fb563c4be6d841b7aa69d8430016",()=>i.deployRepository,"40b6633f3e7026328d9dcc389e42240cb656b75e9f",()=>p.getDeploymentLogs,"40d1d3605adec88ff2ff834f1d0b048d1128e7ed32",()=>g.importGitHubRepository,"40e1d5fd96662092ef0a2bd4ea2e6d2697f3ab4c6a",()=>l.openIde,"40eb06a9ce08102cf20c1cb5e3a0e0aeb9bd30770b",()=>m.openShell,"6024f64a42883240ffb5ef570aecd9c0dbe3fba237",()=>c.updateAgentAndModel,"60677743b16cef93db184f364ea5d4365577e4ff10",()=>C.getGitRepoInfo,"785f41cd02af89c4b44f8d222d661a4a534b081923",()=>v.deleteFeature],68671)}];
|
|
2
2
|
|
|
3
3
|
//# sourceMappingURL=src_presentation_web_0.e4~xc._.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../../../../../src/presentation/web/app/actions/get-git-log.ts","../../../../../../../src/presentation/web/.next-internal/server/app/%28dashboard%29/repository/%5BrepositoryId%5D/%5Btab%5D/page/actions.js%20%28server%20actions%20loader%29"],"sourcesContent":["'use server';\n\nimport { execFile } from 'node:child_process';\nimport { promisify } from 'node:util';\n\nconst execFileAsync = promisify(execFile);\n\nasync function git(cwd: string, args: string[]): Promise<string> {\n const { stdout } = await execFileAsync('git', args, { cwd, timeout: 5000 });\n return stdout.trim();\n}\n\nexport interface GitLogEntry {\n hash: string;\n shortHash: string;\n subject: string;\n author: string;\n relativeDate: string;\n branch?: string;\n}\n\nexport interface GitBranchInfo {\n name: string;\n isCurrent: boolean;\n lastCommitDate: string;\n}\n\nexport interface GitRemoteInfo {\n name: string;\n url: string;\n}\n\nexport interface GitWorkingTreeStatus {\n staged: number;\n modified: number;\n untracked: number;\n}\n\nexport interface GitDiffStats {\n filesChanged: number;\n insertions: number;\n deletions: number;\n}\n\nexport interface GitRepoInfo {\n commits: GitLogEntry[];\n branches: GitBranchInfo[];\n remotes: GitRemoteInfo[];\n tags: string[];\n stashCount: number;\n currentBranch: string;\n diffStats: GitDiffStats | null;\n workingTree: GitWorkingTreeStatus;\n error?: string;\n}\n\nexport async function getGitRepoInfo(\n repositoryPath: string,\n commitLimit = 8\n): Promise<GitRepoInfo> {\n const empty: GitRepoInfo = {\n commits: [],\n branches: [],\n remotes: [],\n tags: [],\n stashCount: 0,\n currentBranch: '',\n diffStats: null,\n workingTree: { staged: 0, modified: 0, untracked: 0 },\n };\n\n if (!repositoryPath.trim()) {\n return { ...empty, error: 'Repository path is required' };\n }\n\n const results = await Promise.allSettled([\n // 0: commits\n git(repositoryPath, [\n 'log',\n `--max-count=${commitLimit}`,\n '--format=%H%x00%h%x00%s%x00%an%x00%cr',\n '--no-color',\n ]),\n // 1: current branch\n git(repositoryPath, ['branch', '--show-current']),\n // 2: branches with dates\n git(repositoryPath, [\n 'branch',\n '--sort=-committerdate',\n '--format=%(HEAD)%(refname:short)%00%(committerdate:relative)',\n '--no-color',\n ]),\n // 3: remotes\n git(repositoryPath, ['remote', '-v']),\n // 4: tags (recent 5)\n git(repositoryPath, ['tag', '--sort=-creatordate', '-l', '--format=%(refname:short)']),\n // 5: stash count\n git(repositoryPath, ['stash', 'list']),\n // 6: working tree status\n git(repositoryPath, ['status', '--porcelain']),\n // 7: diff stats (uncommitted)\n git(repositoryPath, ['diff', '--shortstat']),\n ]);\n\n const val = (i: number) => (results[i].status === 'fulfilled' ? results[i].value : '');\n\n // Parse commits\n const commits: GitLogEntry[] = val(0)\n .split('\\n')\n .filter(Boolean)\n .map((line: string) => {\n const [hash, shortHash, subject, author, relativeDate] = line.split('\\0');\n return { hash, shortHash, subject, author, relativeDate };\n });\n\n const currentBranch = val(1);\n if (commits.length > 0 && currentBranch) {\n commits[0].branch = currentBranch;\n }\n\n // Parse branches\n const branches: GitBranchInfo[] = val(2)\n .split('\\n')\n .filter(Boolean)\n .slice(0, 10)\n .map((line: string) => {\n const isCurrent = line.startsWith('*');\n const clean = isCurrent ? line.slice(1) : line;\n const [name, lastCommitDate] = clean.split('\\0');\n return { name: name.trim(), isCurrent, lastCommitDate: lastCommitDate?.trim() ?? '' };\n });\n\n // Parse remotes (dedup fetch/push)\n const remoteMap = new Map<string, string>();\n val(3)\n .split('\\n')\n .filter(Boolean)\n .forEach((line: string) => {\n const match = line.match(/^(\\S+)\\s+(\\S+)\\s+\\(fetch\\)/);\n if (match) {\n // Strip credentials/tokens from URL before sending to client\n const sanitized = match[2].replace(/\\/\\/[^@]+@/, '//').replace(/x-access-token:[^@]+@/, '');\n remoteMap.set(match[1], sanitized);\n }\n });\n const remotes: GitRemoteInfo[] = Array.from(remoteMap, ([name, url]) => ({ name, url }));\n\n // Parse tags (top 5)\n const tags = val(4).split('\\n').filter(Boolean).slice(0, 5);\n\n // Stash count\n const stashCount = val(5).split('\\n').filter(Boolean).length;\n\n // Working tree status\n const statusLines = val(6).split('\\n').filter(Boolean);\n const workingTree: GitWorkingTreeStatus = { staged: 0, modified: 0, untracked: 0 };\n for (const line of statusLines) {\n const x = line[0];\n const y = line[1];\n if (x === '?' && y === '?') workingTree.untracked++;\n else if (x !== ' ' && x !== '?') workingTree.staged++;\n if (y !== ' ' && y !== '?') workingTree.modified++;\n }\n\n // Diff stats\n let diffStats: GitDiffStats | null = null;\n const diffLine = val(7);\n if (diffLine) {\n const files = diffLine.match(/(\\d+) file/);\n const ins = diffLine.match(/(\\d+) insertion/);\n const del = diffLine.match(/(\\d+) deletion/);\n diffStats = {\n filesChanged: files ? parseInt(files[1], 10) : 0,\n insertions: ins ? parseInt(ins[1], 10) : 0,\n deletions: del ? parseInt(del[1], 10) : 0,\n };\n }\n\n return { commits, branches, remotes, tags, stashCount, currentBranch, diffStats, workingTree };\n}\n\n// Keep backward compat\nexport async function getGitLog(\n repositoryPath: string,\n limit = 10\n): Promise<{ entries: GitLogEntry[]; error?: string }> {\n const info = await getGitRepoInfo(repositoryPath, limit);\n return { entries: info.commits, error: info.error };\n}\n","export {getAllAgentModels as '00cbc4523bf5566fea2d5cf98477b5bf3adbeabce3'} from 'ACTIONS_MODULE0'\nexport {updateAgentAndModel as '607d27ea5d212b8c03d6b47947a6b15a19782e2a95'} from 'ACTIONS_MODULE1'\nexport {pickFolder as '00ac11c8bac2edb4d3cb6e1bfc7e950957ab6fff05'} from 'ACTIONS_MODULE2'\nexport {listGitHubRepositories as '402dc759d6b9f6ac4d0286821d233beb7586bfd6a1'} from 'ACTIONS_MODULE3'\nexport {listGitHubOrganizations as '007430c6e44658511533da6fc18df6a10a77d8ca2f'} from 'ACTIONS_MODULE4'\nexport {importGitHubRepository as '408951cdf9d60d3b3fcefa97ab36845c975e13a4e4'} from 'ACTIONS_MODULE5'\nexport {deployFeature as '4030d28f42b22fbe5c0deddb5a7fdf7c096fc03066'} from 'ACTIONS_MODULE6'\nexport {deployRepository as '4025d2a75d6d6df7203f8a612ff7cb3355a6c1525e'} from 'ACTIONS_MODULE7'\nexport {stopDeployment as '402bfda1e782b375ba1e7b4350dcb2411f747e7759'} from 'ACTIONS_MODULE8'\nexport {getDeploymentStatus as '40f3651a25e60f770e01fc60830b4911e2491df322'} from 'ACTIONS_MODULE9'\nexport {openIde as '40f3fde3affce8285dca5f685141bda496b2e45e0c'} from 'ACTIONS_MODULE10'\nexport {openShell as '4020eb6cd133a6c3dfd8275d14cd43e83d47a93de2'} from 'ACTIONS_MODULE11'\nexport {openFolder as '401ae5ca5ec169940e604f0271d5b3d0051fb26ffb'} from 'ACTIONS_MODULE12'\nexport {syncRepository as '4050fb410229d1171b522d034c23053da254577270'} from 'ACTIONS_MODULE13'\nexport {getDeploymentLogs as '4046e707d870b26bda43482676a885acbc5efb7687'} from 'ACTIONS_MODULE14'\nexport {isAgentSetupComplete as '00ea2e4aeb96147be0df27de0fb0811dcd46d7b284'} from 'ACTIONS_MODULE15'\nexport {checkAgentAuth as '0095abc4000335aa7827a56915d9196e945df0ab50'} from 'ACTIONS_MODULE16'\nexport {checkToolStatus as '00d00bca5810b627fd7f843fa04a97b6756eac2112'} from 'ACTIONS_MODULE17'\nexport {getFeatureMetadata as '40264230f863970e48854876df9f3fc11a8bf79378'} from 'ACTIONS_MODULE18'\nexport {archiveFeature as '409e7f6d9000f7ab91dd4401f2543b2147adb23f81'} from 'ACTIONS_MODULE19'\nexport {deleteFeature as '78e46dbafd792b86405e361f7de33fab8345767ddd'} from 'ACTIONS_MODULE20'\nexport {resumeFeature as '40a1f322bacc7e0c123d20aab8420e1748e5b64122'} from 'ACTIONS_MODULE21'\nexport {startFeature as '402089d3e112c6b2d2afc8c751dbc87755549d0eae'} from 'ACTIONS_MODULE22'\nexport {stopFeature as '40272f295c9d08be7d27e530f118d68eec736ff09d'} from 'ACTIONS_MODULE23'\nexport {unarchiveFeature as '402537786e22ad05934fa43a551ed5b45acf5ff3c0'} from 'ACTIONS_MODULE24'\nexport {addRepository as '4044ad52bb92a547ac306d28c714498429d7ad0e22'} from 'ACTIONS_MODULE25'\nexport {deleteRepository as '404720e2231380d52c29929a6a219b7cc885ea0502'} from 'ACTIONS_MODULE26'\nexport {getGitRepoInfo as '60ad77c4518b2b9e558bbeec2bd6f655901779956f'} from 'ACTIONS_MODULE27'\n"],"names":["execFileAsync","git","cwd","args","stdout","timeout","trim","getGitRepoInfo","repositoryPath","commitLimit","empty","commits","branches","remotes","tags","stashCount","currentBranch","diffStats","workingTree","staged","modified","untracked","error","results","Promise","allSettled","val","i","status","value","split","filter","Boolean","map","line","hash","shortHash","subject","author","relativeDate","length","branch","slice","isCurrent","startsWith","clean","name","lastCommitDate","remoteMap","Map","forEach","match","sanitized","replace","set","Array","from","url","statusLines","x","y","diffLine","files","ins","del","filesChanged","parseInt","insertions","deletions","getGitLog","limit","info","entries"],"mappings":"uDAEA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,oBAEA,IAAMA,EAAgB,CAAA,EAAA,EAAA,SAAA,AAAS,EAAC,EAAA,QAAQ,EAExC,eAAeC,EAAIC,CAAW,CAAEC,CAAc,EAC5C,GAAM,QAAEC,CAAM,CAAE,CAAG,MAAMJ,EAAc,MAAOG,EAAM,KAAED,EAAKG,QAAS,GAAK,GACzE,OAAOD,EAAOE,IAAI,EACpB,CA8CO,eAAeC,EACpBC,CAAsB,CACtBC,EAAc,CAAC,EAaf,GAAI,CAACD,EAAeF,IAAI,GACtB,CAD0B,KACnB,CAXPK,QAAS,EAAE,CACXC,SAAU,EAAE,CACZC,QAAS,EAAE,CACXC,KAAM,EAAE,CACRC,WAAY,EACZC,cAAe,GACfC,UAAW,KACXC,YAAa,CAAEC,OAAQ,EAAGC,SAAU,EAAGC,UAAW,CAAE,EAIjCC,MAAO,6BAA8B,EAG1D,IAAMC,EAAU,MAAMC,QAAQC,UAAU,CAAC,CAEvCxB,EAAIO,EAAgB,CAClB,MACA,CAAC,YAAY,EAAEC,EAAAA,CAAa,CAC5B,wCACA,aACD,EAEDR,EAAIO,EAAgB,CAAC,SAAU,iBAAiB,EAEhDP,EAAIO,EAAgB,CAClB,SACA,wBACA,+DACA,aACD,EAEDP,EAAIO,EAAgB,CAAC,SAAU,KAAK,EAEpCP,EAAIO,EAAgB,CAAC,MAAO,sBAAuB,KAAM,4BAA4B,EAErFP,EAAIO,EAAgB,CAAC,QAAS,OAAO,EAErCP,EAAIO,EAAgB,CAAC,SAAU,cAAc,EAE7CP,EAAIO,EAAgB,CAAC,OAAQ,cAAc,EAC5C,EAEKkB,EAAM,AAACC,GAAqC,cAAtBJ,CAAO,CAACI,EAAE,CAACC,MAAM,CAAmBL,CAAO,CAACI,EAAE,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DCtLtB,IAAA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,MACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA"}
|
|
1
|
+
{"version":3,"sources":["../../../../../../../src/presentation/web/app/actions/get-git-log.ts","../../../../../../../src/presentation/web/.next-internal/server/app/%28dashboard%29/repository/%5BrepositoryId%5D/%5Btab%5D/page/actions.js%20%28server%20actions%20loader%29"],"sourcesContent":["'use server';\n\nimport { execFile } from 'node:child_process';\nimport { promisify } from 'node:util';\n\nconst execFileAsync = promisify(execFile);\n\nasync function git(cwd: string, args: string[]): Promise<string> {\n const { stdout } = await execFileAsync('git', args, { cwd, timeout: 5000 });\n return stdout.trim();\n}\n\nexport interface GitLogEntry {\n hash: string;\n shortHash: string;\n subject: string;\n author: string;\n relativeDate: string;\n branch?: string;\n}\n\nexport interface GitBranchInfo {\n name: string;\n isCurrent: boolean;\n lastCommitDate: string;\n}\n\nexport interface GitRemoteInfo {\n name: string;\n url: string;\n}\n\nexport interface GitWorkingTreeStatus {\n staged: number;\n modified: number;\n untracked: number;\n}\n\nexport interface GitDiffStats {\n filesChanged: number;\n insertions: number;\n deletions: number;\n}\n\nexport interface GitRepoInfo {\n commits: GitLogEntry[];\n branches: GitBranchInfo[];\n remotes: GitRemoteInfo[];\n tags: string[];\n stashCount: number;\n currentBranch: string;\n diffStats: GitDiffStats | null;\n workingTree: GitWorkingTreeStatus;\n error?: string;\n}\n\nexport async function getGitRepoInfo(\n repositoryPath: string,\n commitLimit = 8\n): Promise<GitRepoInfo> {\n const empty: GitRepoInfo = {\n commits: [],\n branches: [],\n remotes: [],\n tags: [],\n stashCount: 0,\n currentBranch: '',\n diffStats: null,\n workingTree: { staged: 0, modified: 0, untracked: 0 },\n };\n\n if (!repositoryPath.trim()) {\n return { ...empty, error: 'Repository path is required' };\n }\n\n const results = await Promise.allSettled([\n // 0: commits\n git(repositoryPath, [\n 'log',\n `--max-count=${commitLimit}`,\n '--format=%H%x00%h%x00%s%x00%an%x00%cr',\n '--no-color',\n ]),\n // 1: current branch\n git(repositoryPath, ['branch', '--show-current']),\n // 2: branches with dates\n git(repositoryPath, [\n 'branch',\n '--sort=-committerdate',\n '--format=%(HEAD)%(refname:short)%00%(committerdate:relative)',\n '--no-color',\n ]),\n // 3: remotes\n git(repositoryPath, ['remote', '-v']),\n // 4: tags (recent 5)\n git(repositoryPath, ['tag', '--sort=-creatordate', '-l', '--format=%(refname:short)']),\n // 5: stash count\n git(repositoryPath, ['stash', 'list']),\n // 6: working tree status\n git(repositoryPath, ['status', '--porcelain']),\n // 7: diff stats (uncommitted)\n git(repositoryPath, ['diff', '--shortstat']),\n ]);\n\n const val = (i: number) => (results[i].status === 'fulfilled' ? results[i].value : '');\n\n // Parse commits\n const commits: GitLogEntry[] = val(0)\n .split('\\n')\n .filter(Boolean)\n .map((line: string) => {\n const [hash, shortHash, subject, author, relativeDate] = line.split('\\0');\n return { hash, shortHash, subject, author, relativeDate };\n });\n\n const currentBranch = val(1);\n if (commits.length > 0 && currentBranch) {\n commits[0].branch = currentBranch;\n }\n\n // Parse branches\n const branches: GitBranchInfo[] = val(2)\n .split('\\n')\n .filter(Boolean)\n .slice(0, 10)\n .map((line: string) => {\n const isCurrent = line.startsWith('*');\n const clean = isCurrent ? line.slice(1) : line;\n const [name, lastCommitDate] = clean.split('\\0');\n return { name: name.trim(), isCurrent, lastCommitDate: lastCommitDate?.trim() ?? '' };\n });\n\n // Parse remotes (dedup fetch/push)\n const remoteMap = new Map<string, string>();\n val(3)\n .split('\\n')\n .filter(Boolean)\n .forEach((line: string) => {\n const match = line.match(/^(\\S+)\\s+(\\S+)\\s+\\(fetch\\)/);\n if (match) {\n // Strip credentials/tokens from URL before sending to client\n const sanitized = match[2].replace(/\\/\\/[^@]+@/, '//').replace(/x-access-token:[^@]+@/, '');\n remoteMap.set(match[1], sanitized);\n }\n });\n const remotes: GitRemoteInfo[] = Array.from(remoteMap, ([name, url]) => ({ name, url }));\n\n // Parse tags (top 5)\n const tags = val(4).split('\\n').filter(Boolean).slice(0, 5);\n\n // Stash count\n const stashCount = val(5).split('\\n').filter(Boolean).length;\n\n // Working tree status\n const statusLines = val(6).split('\\n').filter(Boolean);\n const workingTree: GitWorkingTreeStatus = { staged: 0, modified: 0, untracked: 0 };\n for (const line of statusLines) {\n const x = line[0];\n const y = line[1];\n if (x === '?' && y === '?') workingTree.untracked++;\n else if (x !== ' ' && x !== '?') workingTree.staged++;\n if (y !== ' ' && y !== '?') workingTree.modified++;\n }\n\n // Diff stats\n let diffStats: GitDiffStats | null = null;\n const diffLine = val(7);\n if (diffLine) {\n const files = diffLine.match(/(\\d+) file/);\n const ins = diffLine.match(/(\\d+) insertion/);\n const del = diffLine.match(/(\\d+) deletion/);\n diffStats = {\n filesChanged: files ? parseInt(files[1], 10) : 0,\n insertions: ins ? parseInt(ins[1], 10) : 0,\n deletions: del ? parseInt(del[1], 10) : 0,\n };\n }\n\n return { commits, branches, remotes, tags, stashCount, currentBranch, diffStats, workingTree };\n}\n\n// Keep backward compat\nexport async function getGitLog(\n repositoryPath: string,\n limit = 10\n): Promise<{ entries: GitLogEntry[]; error?: string }> {\n const info = await getGitRepoInfo(repositoryPath, limit);\n return { entries: info.commits, error: info.error };\n}\n","export {getAllAgentModels as '00b5162135ada648e72b38230e961529be25dd7bd8'} from 'ACTIONS_MODULE0'\nexport {updateAgentAndModel as '6024f64a42883240ffb5ef570aecd9c0dbe3fba237'} from 'ACTIONS_MODULE1'\nexport {pickFolder as '00928d754474788ad4c6fbbffcf4486c641fc91c3c'} from 'ACTIONS_MODULE2'\nexport {listGitHubRepositories as '401b1c4187ac45173c36e173144ba201fe13d45124'} from 'ACTIONS_MODULE3'\nexport {listGitHubOrganizations as '007f77d6c65b2ddc62646c97be4a2683c8426167b6'} from 'ACTIONS_MODULE4'\nexport {importGitHubRepository as '40d1d3605adec88ff2ff834f1d0b048d1128e7ed32'} from 'ACTIONS_MODULE5'\nexport {deployFeature as '403b83d2370ec6d9446fd573f8c6c439e91d1aeca2'} from 'ACTIONS_MODULE6'\nexport {deployRepository as '40a100fcddf4b7fb563c4be6d841b7aa69d8430016'} from 'ACTIONS_MODULE7'\nexport {stopDeployment as '402daf0bf817e3bbe4129f413ff47d052ad354069c'} from 'ACTIONS_MODULE8'\nexport {getDeploymentStatus as '408fc9ecc49078119e2600dc1a653a7767b846537c'} from 'ACTIONS_MODULE9'\nexport {openIde as '40e1d5fd96662092ef0a2bd4ea2e6d2697f3ab4c6a'} from 'ACTIONS_MODULE10'\nexport {openShell as '40eb06a9ce08102cf20c1cb5e3a0e0aeb9bd30770b'} from 'ACTIONS_MODULE11'\nexport {openFolder as '406aac6bb69cb2108ce05345c74e9fb7e72dffe3b0'} from 'ACTIONS_MODULE12'\nexport {syncRepository as '4031454b289e8be2efef97c9616a65533d8a72eb59'} from 'ACTIONS_MODULE13'\nexport {getDeploymentLogs as '40b6633f3e7026328d9dcc389e42240cb656b75e9f'} from 'ACTIONS_MODULE14'\nexport {isAgentSetupComplete as '006d6a821da9c521f994872f6661ea6406703cf09d'} from 'ACTIONS_MODULE15'\nexport {checkAgentAuth as '0060e775107df16b7b19d6e47a7415dd6aedad7619'} from 'ACTIONS_MODULE16'\nexport {checkToolStatus as '009df0ec5808a1a338bfdec3c05ddefa2e7406617a'} from 'ACTIONS_MODULE17'\nexport {getFeatureMetadata as '40306a89a2c907442e515b25e00379f8fd0b4403d3'} from 'ACTIONS_MODULE18'\nexport {archiveFeature as '409c6a3d317fe8f02d58823e588796a071e81be44f'} from 'ACTIONS_MODULE19'\nexport {deleteFeature as '785f41cd02af89c4b44f8d222d661a4a534b081923'} from 'ACTIONS_MODULE20'\nexport {resumeFeature as '402a5001445d8c354653c4a59447732df930eeeae9'} from 'ACTIONS_MODULE21'\nexport {startFeature as '40217ab39df4c598292e413589a39a03ff1567821b'} from 'ACTIONS_MODULE22'\nexport {stopFeature as '405314689dc2fdc3d3267320760cc2912860068706'} from 'ACTIONS_MODULE23'\nexport {unarchiveFeature as '4056493ad4e1f0b52d9ffb6cd926ce616630546083'} from 'ACTIONS_MODULE24'\nexport {addRepository as '40885ae2064e9aa9d12636caabc74c8e36c76939e2'} from 'ACTIONS_MODULE25'\nexport {deleteRepository as '40090d50d2dfeaaa5c021cfb7c005a37c84488a7f7'} from 'ACTIONS_MODULE26'\nexport {getGitRepoInfo as '60677743b16cef93db184f364ea5d4365577e4ff10'} from 'ACTIONS_MODULE27'\n"],"names":["execFileAsync","git","cwd","args","stdout","timeout","trim","getGitRepoInfo","repositoryPath","commitLimit","empty","commits","branches","remotes","tags","stashCount","currentBranch","diffStats","workingTree","staged","modified","untracked","error","results","Promise","allSettled","val","i","status","value","split","filter","Boolean","map","line","hash","shortHash","subject","author","relativeDate","length","branch","slice","isCurrent","startsWith","clean","name","lastCommitDate","remoteMap","Map","forEach","match","sanitized","replace","set","Array","from","url","statusLines","x","y","diffLine","files","ins","del","filesChanged","parseInt","insertions","deletions","getGitLog","limit","info","entries"],"mappings":"uDAEA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,oBAEA,IAAMA,EAAgB,CAAA,EAAA,EAAA,SAAA,AAAS,EAAC,EAAA,QAAQ,EAExC,eAAeC,EAAIC,CAAW,CAAEC,CAAc,EAC5C,GAAM,QAAEC,CAAM,CAAE,CAAG,MAAMJ,EAAc,MAAOG,EAAM,KAAED,EAAKG,QAAS,GAAK,GACzE,OAAOD,EAAOE,IAAI,EACpB,CA8CO,eAAeC,EACpBC,CAAsB,CACtBC,EAAc,CAAC,EAaf,GAAI,CAACD,EAAeF,IAAI,GACtB,CAD0B,KACnB,CAXPK,QAAS,EAAE,CACXC,SAAU,EAAE,CACZC,QAAS,EAAE,CACXC,KAAM,EAAE,CACRC,WAAY,EACZC,cAAe,GACfC,UAAW,KACXC,YAAa,CAAEC,OAAQ,EAAGC,SAAU,EAAGC,UAAW,CAAE,EAIjCC,MAAO,6BAA8B,EAG1D,IAAMC,EAAU,MAAMC,QAAQC,UAAU,CAAC,CAEvCxB,EAAIO,EAAgB,CAClB,MACA,CAAC,YAAY,EAAEC,EAAAA,CAAa,CAC5B,wCACA,aACD,EAEDR,EAAIO,EAAgB,CAAC,SAAU,iBAAiB,EAEhDP,EAAIO,EAAgB,CAClB,SACA,wBACA,+DACA,aACD,EAEDP,EAAIO,EAAgB,CAAC,SAAU,KAAK,EAEpCP,EAAIO,EAAgB,CAAC,MAAO,sBAAuB,KAAM,4BAA4B,EAErFP,EAAIO,EAAgB,CAAC,QAAS,OAAO,EAErCP,EAAIO,EAAgB,CAAC,SAAU,cAAc,EAE7CP,EAAIO,EAAgB,CAAC,OAAQ,cAAc,EAC5C,EAEKkB,EAAM,AAACC,GAAqC,cAAtBJ,CAAO,CAACI,EAAE,CAACC,MAAM,CAAmBL,CAAO,CAACI,EAAE,CAACE,KA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IAAA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,MACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA"}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
module.exports=[35556,a=>{"use strict";var b=a.i(2211),c=a.i(74533),d=a.i(12057),e=a.i(50961);let f=(0,d.promisify)(c.execFile);async function g(a,b){let{stdout:c}=await f("git",b,{cwd:a,timeout:5e3});return c.trim()}async function h(a,b=8){if(!a.trim())return{commits:[],branches:[],remotes:[],tags:[],stashCount:0,currentBranch:"",diffStats:null,workingTree:{staged:0,modified:0,untracked:0},error:"Repository path is required"};let c=await Promise.allSettled([g(a,["log",`--max-count=${b}`,"--format=%H%x00%h%x00%s%x00%an%x00%cr","--no-color"]),g(a,["branch","--show-current"]),g(a,["branch","--sort=-committerdate","--format=%(HEAD)%(refname:short)%00%(committerdate:relative)","--no-color"]),g(a,["remote","-v"]),g(a,["tag","--sort=-creatordate","-l","--format=%(refname:short)"]),g(a,["stash","list"]),g(a,["status","--porcelain"]),g(a,["diff","--shortstat"])]),d=a=>"fulfilled"===c[a].status?c[a].value:"",e=d(0).split("\n").filter(Boolean).map(a=>{let[b,c,d,e,f]=a.split("\0");return{hash:b,shortHash:c,subject:d,author:e,relativeDate:f}}),f=d(1);e.length>0&&f&&(e[0].branch=f);let i=d(2).split("\n").filter(Boolean).slice(0,10).map(a=>{let b=a.startsWith("*"),[c,d]=(b?a.slice(1):a).split("\0");return{name:c.trim(),isCurrent:b,lastCommitDate:d?.trim()??""}}),j=new Map;d(3).split("\n").filter(Boolean).forEach(a=>{let b=a.match(/^(\S+)\s+(\S+)\s+\(fetch\)/);if(b){let a=b[2].replace(/\/\/[^@]+@/,"//").replace(/x-access-token:[^@]+@/,"");j.set(b[1],a)}});let k=Array.from(j,([a,b])=>({name:a,url:b})),l=d(4).split("\n").filter(Boolean).slice(0,5),m=d(5).split("\n").filter(Boolean).length,n=d(6).split("\n").filter(Boolean),o={staged:0,modified:0,untracked:0};for(let a of n){let b=a[0],c=a[1];"?"===b&&"?"===c?o.untracked++:" "!==b&&"?"!==b&&o.staged++," "!==c&&"?"!==c&&o.modified++}let p=null,q=d(7);if(q){let a=q.match(/(\d+) file/),b=q.match(/(\d+) insertion/),c=q.match(/(\d+) deletion/);p={filesChanged:a?parseInt(a[1],10):0,insertions:b?parseInt(b[1],10):0,deletions:c?parseInt(c[1],10):0}}return{commits:e,branches:i,remotes:k,tags:l,stashCount:m,currentBranch:f,diffStats:p,workingTree:o}}async function i(a,b=10){let c=await h(a,b);return{entries:c.commits,error:c.error}}(0,e.ensureServerEntryExports)([h,i]),(0,b.registerServerReference)(h,"
|
|
1
|
+
module.exports=[35556,a=>{"use strict";var b=a.i(2211),c=a.i(74533),d=a.i(12057),e=a.i(50961);let f=(0,d.promisify)(c.execFile);async function g(a,b){let{stdout:c}=await f("git",b,{cwd:a,timeout:5e3});return c.trim()}async function h(a,b=8){if(!a.trim())return{commits:[],branches:[],remotes:[],tags:[],stashCount:0,currentBranch:"",diffStats:null,workingTree:{staged:0,modified:0,untracked:0},error:"Repository path is required"};let c=await Promise.allSettled([g(a,["log",`--max-count=${b}`,"--format=%H%x00%h%x00%s%x00%an%x00%cr","--no-color"]),g(a,["branch","--show-current"]),g(a,["branch","--sort=-committerdate","--format=%(HEAD)%(refname:short)%00%(committerdate:relative)","--no-color"]),g(a,["remote","-v"]),g(a,["tag","--sort=-creatordate","-l","--format=%(refname:short)"]),g(a,["stash","list"]),g(a,["status","--porcelain"]),g(a,["diff","--shortstat"])]),d=a=>"fulfilled"===c[a].status?c[a].value:"",e=d(0).split("\n").filter(Boolean).map(a=>{let[b,c,d,e,f]=a.split("\0");return{hash:b,shortHash:c,subject:d,author:e,relativeDate:f}}),f=d(1);e.length>0&&f&&(e[0].branch=f);let i=d(2).split("\n").filter(Boolean).slice(0,10).map(a=>{let b=a.startsWith("*"),[c,d]=(b?a.slice(1):a).split("\0");return{name:c.trim(),isCurrent:b,lastCommitDate:d?.trim()??""}}),j=new Map;d(3).split("\n").filter(Boolean).forEach(a=>{let b=a.match(/^(\S+)\s+(\S+)\s+\(fetch\)/);if(b){let a=b[2].replace(/\/\/[^@]+@/,"//").replace(/x-access-token:[^@]+@/,"");j.set(b[1],a)}});let k=Array.from(j,([a,b])=>({name:a,url:b})),l=d(4).split("\n").filter(Boolean).slice(0,5),m=d(5).split("\n").filter(Boolean).length,n=d(6).split("\n").filter(Boolean),o={staged:0,modified:0,untracked:0};for(let a of n){let b=a[0],c=a[1];"?"===b&&"?"===c?o.untracked++:" "!==b&&"?"!==b&&o.staged++," "!==c&&"?"!==c&&o.modified++}let p=null,q=d(7);if(q){let a=q.match(/(\d+) file/),b=q.match(/(\d+) insertion/),c=q.match(/(\d+) deletion/);p={filesChanged:a?parseInt(a[1],10):0,insertions:b?parseInt(b[1],10):0,deletions:c?parseInt(c[1],10):0}}return{commits:e,branches:i,remotes:k,tags:l,stashCount:m,currentBranch:f,diffStats:p,workingTree:o}}async function i(a,b=10){let c=await h(a,b);return{entries:c.commits,error:c.error}}(0,e.ensureServerEntryExports)([h,i]),(0,b.registerServerReference)(h,"60677743b16cef93db184f364ea5d4365577e4ff10",null),(0,b.registerServerReference)(i,"605b636556deda767073e576fa60082cf49d414ba8",null),a.s(["getGitRepoInfo",0,h])},59044,a=>{"use strict";var b=a.i(23504),c=a.i(27900),d=a.i(12513),e=a.i(73101),f=a.i(54775),g=a.i(65324),h=a.i(33841),i=a.i(46646),j=a.i(68670),k=a.i(85321),l=a.i(84095),m=a.i(56799),n=a.i(80496),o=a.i(93225),p=a.i(94691),q=a.i(41872),r=a.i(9959),s=a.i(79124),t=a.i(29207),u=a.i(10528),v=a.i(50845),w=a.i(26604),x=a.i(54723),y=a.i(18942),z=a.i(42886),A=a.i(49560),B=a.i(39353),C=a.i(35556);a.s([],93888),a.i(93888),a.s(["0060e775107df16b7b19d6e47a7415dd6aedad7619",()=>r.checkAgentAuth,"006d6a821da9c521f994872f6661ea6406703cf09d",()=>q.isAgentSetupComplete,"007f77d6c65b2ddc62646c97be4a2683c8426167b6",()=>f.listGitHubOrganizations,"00928d754474788ad4c6fbbffcf4486c641fc91c3c",()=>d.pickFolder,"009df0ec5808a1a338bfdec3c05ddefa2e7406617a",()=>s.checkToolStatus,"00b5162135ada648e72b38230e961529be25dd7bd8",()=>b.getAllAgentModels,"40090d50d2dfeaaa5c021cfb7c005a37c84488a7f7",()=>B.deleteRepository,"401b1c4187ac45173c36e173144ba201fe13d45124",()=>e.listGitHubRepositories,"40217ab39df4c598292e413589a39a03ff1567821b",()=>x.startFeature,"402a5001445d8c354653c4a59447732df930eeeae9",()=>w.resumeFeature,"402daf0bf817e3bbe4129f413ff47d052ad354069c",()=>j.stopDeployment,"40306a89a2c907442e515b25e00379f8fd0b4403d3",()=>t.getFeatureMetadata,"4031454b289e8be2efef97c9616a65533d8a72eb59",()=>o.syncRepository,"403b83d2370ec6d9446fd573f8c6c439e91d1aeca2",()=>h.deployFeature,"405314689dc2fdc3d3267320760cc2912860068706",()=>y.stopFeature,"4056493ad4e1f0b52d9ffb6cd926ce616630546083",()=>z.unarchiveFeature,"406aac6bb69cb2108ce05345c74e9fb7e72dffe3b0",()=>n.openFolder,"40885ae2064e9aa9d12636caabc74c8e36c76939e2",()=>A.addRepository,"408fc9ecc49078119e2600dc1a653a7767b846537c",()=>k.getDeploymentStatus,"409c6a3d317fe8f02d58823e588796a071e81be44f",()=>u.archiveFeature,"40a100fcddf4b7fb563c4be6d841b7aa69d8430016",()=>i.deployRepository,"40b6633f3e7026328d9dcc389e42240cb656b75e9f",()=>p.getDeploymentLogs,"40d1d3605adec88ff2ff834f1d0b048d1128e7ed32",()=>g.importGitHubRepository,"40e1d5fd96662092ef0a2bd4ea2e6d2697f3ab4c6a",()=>l.openIde,"40eb06a9ce08102cf20c1cb5e3a0e0aeb9bd30770b",()=>m.openShell,"6024f64a42883240ffb5ef570aecd9c0dbe3fba237",()=>c.updateAgentAndModel,"60677743b16cef93db184f364ea5d4365577e4ff10",()=>C.getGitRepoInfo,"785f41cd02af89c4b44f8d222d661a4a534b081923",()=>v.deleteFeature],59044)}];
|
|
2
2
|
|
|
3
3
|
//# sourceMappingURL=src_presentation_web_00dvh.m._.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../../../../../src/presentation/web/app/actions/get-git-log.ts","../../../../../../../src/presentation/web/.next-internal/server/app/%28dashboard%29/%40drawer/repository/%5BrepositoryId%5D/%5Btab%5D/page/actions.js%20%28server%20actions%20loader%29"],"sourcesContent":["'use server';\n\nimport { execFile } from 'node:child_process';\nimport { promisify } from 'node:util';\n\nconst execFileAsync = promisify(execFile);\n\nasync function git(cwd: string, args: string[]): Promise<string> {\n const { stdout } = await execFileAsync('git', args, { cwd, timeout: 5000 });\n return stdout.trim();\n}\n\nexport interface GitLogEntry {\n hash: string;\n shortHash: string;\n subject: string;\n author: string;\n relativeDate: string;\n branch?: string;\n}\n\nexport interface GitBranchInfo {\n name: string;\n isCurrent: boolean;\n lastCommitDate: string;\n}\n\nexport interface GitRemoteInfo {\n name: string;\n url: string;\n}\n\nexport interface GitWorkingTreeStatus {\n staged: number;\n modified: number;\n untracked: number;\n}\n\nexport interface GitDiffStats {\n filesChanged: number;\n insertions: number;\n deletions: number;\n}\n\nexport interface GitRepoInfo {\n commits: GitLogEntry[];\n branches: GitBranchInfo[];\n remotes: GitRemoteInfo[];\n tags: string[];\n stashCount: number;\n currentBranch: string;\n diffStats: GitDiffStats | null;\n workingTree: GitWorkingTreeStatus;\n error?: string;\n}\n\nexport async function getGitRepoInfo(\n repositoryPath: string,\n commitLimit = 8\n): Promise<GitRepoInfo> {\n const empty: GitRepoInfo = {\n commits: [],\n branches: [],\n remotes: [],\n tags: [],\n stashCount: 0,\n currentBranch: '',\n diffStats: null,\n workingTree: { staged: 0, modified: 0, untracked: 0 },\n };\n\n if (!repositoryPath.trim()) {\n return { ...empty, error: 'Repository path is required' };\n }\n\n const results = await Promise.allSettled([\n // 0: commits\n git(repositoryPath, [\n 'log',\n `--max-count=${commitLimit}`,\n '--format=%H%x00%h%x00%s%x00%an%x00%cr',\n '--no-color',\n ]),\n // 1: current branch\n git(repositoryPath, ['branch', '--show-current']),\n // 2: branches with dates\n git(repositoryPath, [\n 'branch',\n '--sort=-committerdate',\n '--format=%(HEAD)%(refname:short)%00%(committerdate:relative)',\n '--no-color',\n ]),\n // 3: remotes\n git(repositoryPath, ['remote', '-v']),\n // 4: tags (recent 5)\n git(repositoryPath, ['tag', '--sort=-creatordate', '-l', '--format=%(refname:short)']),\n // 5: stash count\n git(repositoryPath, ['stash', 'list']),\n // 6: working tree status\n git(repositoryPath, ['status', '--porcelain']),\n // 7: diff stats (uncommitted)\n git(repositoryPath, ['diff', '--shortstat']),\n ]);\n\n const val = (i: number) => (results[i].status === 'fulfilled' ? results[i].value : '');\n\n // Parse commits\n const commits: GitLogEntry[] = val(0)\n .split('\\n')\n .filter(Boolean)\n .map((line: string) => {\n const [hash, shortHash, subject, author, relativeDate] = line.split('\\0');\n return { hash, shortHash, subject, author, relativeDate };\n });\n\n const currentBranch = val(1);\n if (commits.length > 0 && currentBranch) {\n commits[0].branch = currentBranch;\n }\n\n // Parse branches\n const branches: GitBranchInfo[] = val(2)\n .split('\\n')\n .filter(Boolean)\n .slice(0, 10)\n .map((line: string) => {\n const isCurrent = line.startsWith('*');\n const clean = isCurrent ? line.slice(1) : line;\n const [name, lastCommitDate] = clean.split('\\0');\n return { name: name.trim(), isCurrent, lastCommitDate: lastCommitDate?.trim() ?? '' };\n });\n\n // Parse remotes (dedup fetch/push)\n const remoteMap = new Map<string, string>();\n val(3)\n .split('\\n')\n .filter(Boolean)\n .forEach((line: string) => {\n const match = line.match(/^(\\S+)\\s+(\\S+)\\s+\\(fetch\\)/);\n if (match) {\n // Strip credentials/tokens from URL before sending to client\n const sanitized = match[2].replace(/\\/\\/[^@]+@/, '//').replace(/x-access-token:[^@]+@/, '');\n remoteMap.set(match[1], sanitized);\n }\n });\n const remotes: GitRemoteInfo[] = Array.from(remoteMap, ([name, url]) => ({ name, url }));\n\n // Parse tags (top 5)\n const tags = val(4).split('\\n').filter(Boolean).slice(0, 5);\n\n // Stash count\n const stashCount = val(5).split('\\n').filter(Boolean).length;\n\n // Working tree status\n const statusLines = val(6).split('\\n').filter(Boolean);\n const workingTree: GitWorkingTreeStatus = { staged: 0, modified: 0, untracked: 0 };\n for (const line of statusLines) {\n const x = line[0];\n const y = line[1];\n if (x === '?' && y === '?') workingTree.untracked++;\n else if (x !== ' ' && x !== '?') workingTree.staged++;\n if (y !== ' ' && y !== '?') workingTree.modified++;\n }\n\n // Diff stats\n let diffStats: GitDiffStats | null = null;\n const diffLine = val(7);\n if (diffLine) {\n const files = diffLine.match(/(\\d+) file/);\n const ins = diffLine.match(/(\\d+) insertion/);\n const del = diffLine.match(/(\\d+) deletion/);\n diffStats = {\n filesChanged: files ? parseInt(files[1], 10) : 0,\n insertions: ins ? parseInt(ins[1], 10) : 0,\n deletions: del ? parseInt(del[1], 10) : 0,\n };\n }\n\n return { commits, branches, remotes, tags, stashCount, currentBranch, diffStats, workingTree };\n}\n\n// Keep backward compat\nexport async function getGitLog(\n repositoryPath: string,\n limit = 10\n): Promise<{ entries: GitLogEntry[]; error?: string }> {\n const info = await getGitRepoInfo(repositoryPath, limit);\n return { entries: info.commits, error: info.error };\n}\n","export {getAllAgentModels as '00cbc4523bf5566fea2d5cf98477b5bf3adbeabce3'} from 'ACTIONS_MODULE0'\nexport {updateAgentAndModel as '607d27ea5d212b8c03d6b47947a6b15a19782e2a95'} from 'ACTIONS_MODULE1'\nexport {pickFolder as '00ac11c8bac2edb4d3cb6e1bfc7e950957ab6fff05'} from 'ACTIONS_MODULE2'\nexport {listGitHubRepositories as '402dc759d6b9f6ac4d0286821d233beb7586bfd6a1'} from 'ACTIONS_MODULE3'\nexport {listGitHubOrganizations as '007430c6e44658511533da6fc18df6a10a77d8ca2f'} from 'ACTIONS_MODULE4'\nexport {importGitHubRepository as '408951cdf9d60d3b3fcefa97ab36845c975e13a4e4'} from 'ACTIONS_MODULE5'\nexport {deployFeature as '4030d28f42b22fbe5c0deddb5a7fdf7c096fc03066'} from 'ACTIONS_MODULE6'\nexport {deployRepository as '4025d2a75d6d6df7203f8a612ff7cb3355a6c1525e'} from 'ACTIONS_MODULE7'\nexport {stopDeployment as '402bfda1e782b375ba1e7b4350dcb2411f747e7759'} from 'ACTIONS_MODULE8'\nexport {getDeploymentStatus as '40f3651a25e60f770e01fc60830b4911e2491df322'} from 'ACTIONS_MODULE9'\nexport {openIde as '40f3fde3affce8285dca5f685141bda496b2e45e0c'} from 'ACTIONS_MODULE10'\nexport {openShell as '4020eb6cd133a6c3dfd8275d14cd43e83d47a93de2'} from 'ACTIONS_MODULE11'\nexport {openFolder as '401ae5ca5ec169940e604f0271d5b3d0051fb26ffb'} from 'ACTIONS_MODULE12'\nexport {syncRepository as '4050fb410229d1171b522d034c23053da254577270'} from 'ACTIONS_MODULE13'\nexport {getDeploymentLogs as '4046e707d870b26bda43482676a885acbc5efb7687'} from 'ACTIONS_MODULE14'\nexport {isAgentSetupComplete as '00ea2e4aeb96147be0df27de0fb0811dcd46d7b284'} from 'ACTIONS_MODULE15'\nexport {checkAgentAuth as '0095abc4000335aa7827a56915d9196e945df0ab50'} from 'ACTIONS_MODULE16'\nexport {checkToolStatus as '00d00bca5810b627fd7f843fa04a97b6756eac2112'} from 'ACTIONS_MODULE17'\nexport {getFeatureMetadata as '40264230f863970e48854876df9f3fc11a8bf79378'} from 'ACTIONS_MODULE18'\nexport {archiveFeature as '409e7f6d9000f7ab91dd4401f2543b2147adb23f81'} from 'ACTIONS_MODULE19'\nexport {deleteFeature as '78e46dbafd792b86405e361f7de33fab8345767ddd'} from 'ACTIONS_MODULE20'\nexport {resumeFeature as '40a1f322bacc7e0c123d20aab8420e1748e5b64122'} from 'ACTIONS_MODULE21'\nexport {startFeature as '402089d3e112c6b2d2afc8c751dbc87755549d0eae'} from 'ACTIONS_MODULE22'\nexport {stopFeature as '40272f295c9d08be7d27e530f118d68eec736ff09d'} from 'ACTIONS_MODULE23'\nexport {unarchiveFeature as '402537786e22ad05934fa43a551ed5b45acf5ff3c0'} from 'ACTIONS_MODULE24'\nexport {addRepository as '4044ad52bb92a547ac306d28c714498429d7ad0e22'} from 'ACTIONS_MODULE25'\nexport {deleteRepository as '404720e2231380d52c29929a6a219b7cc885ea0502'} from 'ACTIONS_MODULE26'\nexport {getGitRepoInfo as '60ad77c4518b2b9e558bbeec2bd6f655901779956f'} from 'ACTIONS_MODULE27'\n"],"names":["execFileAsync","git","cwd","args","stdout","timeout","trim","getGitRepoInfo","repositoryPath","commitLimit","empty","commits","branches","remotes","tags","stashCount","currentBranch","diffStats","workingTree","staged","modified","untracked","error","results","Promise","allSettled","val","i","status","value","split","filter","Boolean","map","line","hash","shortHash","subject","author","relativeDate","length","branch","slice","isCurrent","startsWith","clean","name","lastCommitDate","remoteMap","Map","forEach","match","sanitized","replace","set","Array","from","url","statusLines","x","y","diffLine","files","ins","del","filesChanged","parseInt","insertions","deletions","getGitLog","limit","info","entries"],"mappings":"uDAEA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,oBAEA,IAAMA,EAAgB,CAAA,EAAA,EAAA,SAAA,AAAS,EAAC,EAAA,QAAQ,EAExC,eAAeC,EAAIC,CAAW,CAAEC,CAAc,EAC5C,GAAM,QAAEC,CAAM,CAAE,CAAG,MAAMJ,EAAc,MAAOG,EAAM,KAAED,EAAKG,QAAS,GAAK,GACzE,OAAOD,EAAOE,IAAI,EACpB,CA8CO,eAAeC,EACpBC,CAAsB,CACtBC,EAAc,CAAC,EAaf,GAAI,CAACD,EAAeF,IAAI,GACtB,CAD0B,KACnB,CAXPK,QAAS,EAAE,CACXC,SAAU,EAAE,CACZC,QAAS,EAAE,CACXC,KAAM,EAAE,CACRC,WAAY,EACZC,cAAe,GACfC,UAAW,KACXC,YAAa,CAAEC,OAAQ,EAAGC,SAAU,EAAGC,UAAW,CAAE,EAIjCC,MAAO,6BAA8B,EAG1D,IAAMC,EAAU,MAAMC,QAAQC,UAAU,CAAC,CAEvCxB,EAAIO,EAAgB,CAClB,MACA,CAAC,YAAY,EAAEC,EAAAA,CAAa,CAC5B,wCACA,aACD,EAEDR,EAAIO,EAAgB,CAAC,SAAU,iBAAiB,EAEhDP,EAAIO,EAAgB,CAClB,SACA,wBACA,+DACA,aACD,EAEDP,EAAIO,EAAgB,CAAC,SAAU,KAAK,EAEpCP,EAAIO,EAAgB,CAAC,MAAO,sBAAuB,KAAM,4BAA4B,EAErFP,EAAIO,EAAgB,CAAC,QAAS,OAAO,EAErCP,EAAIO,EAAgB,CAAC,SAAU,cAAc,EAE7CP,EAAIO,EAAgB,CAAC,OAAQ,cAAc,EAC5C,EAEKkB,EAAM,AAACC,GAAqC,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A,MA8HA8D,CAAAA,EAAAA,EAAAA,uBAAAA,EAAAA,EAAAA,6CAAAA,0DCtLtB,IAAA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,MACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA"}
|
|
1
|
+
{"version":3,"sources":["../../../../../../../src/presentation/web/app/actions/get-git-log.ts","../../../../../../../src/presentation/web/.next-internal/server/app/%28dashboard%29/%40drawer/repository/%5BrepositoryId%5D/%5Btab%5D/page/actions.js%20%28server%20actions%20loader%29"],"sourcesContent":["'use server';\n\nimport { execFile } from 'node:child_process';\nimport { promisify } from 'node:util';\n\nconst execFileAsync = promisify(execFile);\n\nasync function git(cwd: string, args: string[]): Promise<string> {\n const { stdout } = await execFileAsync('git', args, { cwd, timeout: 5000 });\n return stdout.trim();\n}\n\nexport interface GitLogEntry {\n hash: string;\n shortHash: string;\n subject: string;\n author: string;\n relativeDate: string;\n branch?: string;\n}\n\nexport interface GitBranchInfo {\n name: string;\n isCurrent: boolean;\n lastCommitDate: string;\n}\n\nexport interface GitRemoteInfo {\n name: string;\n url: string;\n}\n\nexport interface GitWorkingTreeStatus {\n staged: number;\n modified: number;\n untracked: number;\n}\n\nexport interface GitDiffStats {\n filesChanged: number;\n insertions: number;\n deletions: number;\n}\n\nexport interface GitRepoInfo {\n commits: GitLogEntry[];\n branches: GitBranchInfo[];\n remotes: GitRemoteInfo[];\n tags: string[];\n stashCount: number;\n currentBranch: string;\n diffStats: GitDiffStats | null;\n workingTree: GitWorkingTreeStatus;\n error?: string;\n}\n\nexport async function getGitRepoInfo(\n repositoryPath: string,\n commitLimit = 8\n): Promise<GitRepoInfo> {\n const empty: GitRepoInfo = {\n commits: [],\n branches: [],\n remotes: [],\n tags: [],\n stashCount: 0,\n currentBranch: '',\n diffStats: null,\n workingTree: { staged: 0, modified: 0, untracked: 0 },\n };\n\n if (!repositoryPath.trim()) {\n return { ...empty, error: 'Repository path is required' };\n }\n\n const results = await Promise.allSettled([\n // 0: commits\n git(repositoryPath, [\n 'log',\n `--max-count=${commitLimit}`,\n '--format=%H%x00%h%x00%s%x00%an%x00%cr',\n '--no-color',\n ]),\n // 1: current branch\n git(repositoryPath, ['branch', '--show-current']),\n // 2: branches with dates\n git(repositoryPath, [\n 'branch',\n '--sort=-committerdate',\n '--format=%(HEAD)%(refname:short)%00%(committerdate:relative)',\n '--no-color',\n ]),\n // 3: remotes\n git(repositoryPath, ['remote', '-v']),\n // 4: tags (recent 5)\n git(repositoryPath, ['tag', '--sort=-creatordate', '-l', '--format=%(refname:short)']),\n // 5: stash count\n git(repositoryPath, ['stash', 'list']),\n // 6: working tree status\n git(repositoryPath, ['status', '--porcelain']),\n // 7: diff stats (uncommitted)\n git(repositoryPath, ['diff', '--shortstat']),\n ]);\n\n const val = (i: number) => (results[i].status === 'fulfilled' ? results[i].value : '');\n\n // Parse commits\n const commits: GitLogEntry[] = val(0)\n .split('\\n')\n .filter(Boolean)\n .map((line: string) => {\n const [hash, shortHash, subject, author, relativeDate] = line.split('\\0');\n return { hash, shortHash, subject, author, relativeDate };\n });\n\n const currentBranch = val(1);\n if (commits.length > 0 && currentBranch) {\n commits[0].branch = currentBranch;\n }\n\n // Parse branches\n const branches: GitBranchInfo[] = val(2)\n .split('\\n')\n .filter(Boolean)\n .slice(0, 10)\n .map((line: string) => {\n const isCurrent = line.startsWith('*');\n const clean = isCurrent ? line.slice(1) : line;\n const [name, lastCommitDate] = clean.split('\\0');\n return { name: name.trim(), isCurrent, lastCommitDate: lastCommitDate?.trim() ?? '' };\n });\n\n // Parse remotes (dedup fetch/push)\n const remoteMap = new Map<string, string>();\n val(3)\n .split('\\n')\n .filter(Boolean)\n .forEach((line: string) => {\n const match = line.match(/^(\\S+)\\s+(\\S+)\\s+\\(fetch\\)/);\n if (match) {\n // Strip credentials/tokens from URL before sending to client\n const sanitized = match[2].replace(/\\/\\/[^@]+@/, '//').replace(/x-access-token:[^@]+@/, '');\n remoteMap.set(match[1], sanitized);\n }\n });\n const remotes: GitRemoteInfo[] = Array.from(remoteMap, ([name, url]) => ({ name, url }));\n\n // Parse tags (top 5)\n const tags = val(4).split('\\n').filter(Boolean).slice(0, 5);\n\n // Stash count\n const stashCount = val(5).split('\\n').filter(Boolean).length;\n\n // Working tree status\n const statusLines = val(6).split('\\n').filter(Boolean);\n const workingTree: GitWorkingTreeStatus = { staged: 0, modified: 0, untracked: 0 };\n for (const line of statusLines) {\n const x = line[0];\n const y = line[1];\n if (x === '?' && y === '?') workingTree.untracked++;\n else if (x !== ' ' && x !== '?') workingTree.staged++;\n if (y !== ' ' && y !== '?') workingTree.modified++;\n }\n\n // Diff stats\n let diffStats: GitDiffStats | null = null;\n const diffLine = val(7);\n if (diffLine) {\n const files = diffLine.match(/(\\d+) file/);\n const ins = diffLine.match(/(\\d+) insertion/);\n const del = diffLine.match(/(\\d+) deletion/);\n diffStats = {\n filesChanged: files ? parseInt(files[1], 10) : 0,\n insertions: ins ? parseInt(ins[1], 10) : 0,\n deletions: del ? parseInt(del[1], 10) : 0,\n };\n }\n\n return { commits, branches, remotes, tags, stashCount, currentBranch, diffStats, workingTree };\n}\n\n// Keep backward compat\nexport async function getGitLog(\n repositoryPath: string,\n limit = 10\n): Promise<{ entries: GitLogEntry[]; error?: string }> {\n const info = await getGitRepoInfo(repositoryPath, limit);\n return { entries: info.commits, error: info.error };\n}\n","export {getAllAgentModels as '00b5162135ada648e72b38230e961529be25dd7bd8'} from 'ACTIONS_MODULE0'\nexport {updateAgentAndModel as '6024f64a42883240ffb5ef570aecd9c0dbe3fba237'} from 'ACTIONS_MODULE1'\nexport {pickFolder as '00928d754474788ad4c6fbbffcf4486c641fc91c3c'} from 'ACTIONS_MODULE2'\nexport {listGitHubRepositories as '401b1c4187ac45173c36e173144ba201fe13d45124'} from 'ACTIONS_MODULE3'\nexport {listGitHubOrganizations as '007f77d6c65b2ddc62646c97be4a2683c8426167b6'} from 'ACTIONS_MODULE4'\nexport {importGitHubRepository as '40d1d3605adec88ff2ff834f1d0b048d1128e7ed32'} from 'ACTIONS_MODULE5'\nexport {deployFeature as '403b83d2370ec6d9446fd573f8c6c439e91d1aeca2'} from 'ACTIONS_MODULE6'\nexport {deployRepository as '40a100fcddf4b7fb563c4be6d841b7aa69d8430016'} from 'ACTIONS_MODULE7'\nexport {stopDeployment as '402daf0bf817e3bbe4129f413ff47d052ad354069c'} from 'ACTIONS_MODULE8'\nexport {getDeploymentStatus as '408fc9ecc49078119e2600dc1a653a7767b846537c'} from 'ACTIONS_MODULE9'\nexport {openIde as '40e1d5fd96662092ef0a2bd4ea2e6d2697f3ab4c6a'} from 'ACTIONS_MODULE10'\nexport {openShell as '40eb06a9ce08102cf20c1cb5e3a0e0aeb9bd30770b'} from 'ACTIONS_MODULE11'\nexport {openFolder as '406aac6bb69cb2108ce05345c74e9fb7e72dffe3b0'} from 'ACTIONS_MODULE12'\nexport {syncRepository as '4031454b289e8be2efef97c9616a65533d8a72eb59'} from 'ACTIONS_MODULE13'\nexport {getDeploymentLogs as '40b6633f3e7026328d9dcc389e42240cb656b75e9f'} from 'ACTIONS_MODULE14'\nexport {isAgentSetupComplete as '006d6a821da9c521f994872f6661ea6406703cf09d'} from 'ACTIONS_MODULE15'\nexport {checkAgentAuth as '0060e775107df16b7b19d6e47a7415dd6aedad7619'} from 'ACTIONS_MODULE16'\nexport {checkToolStatus as '009df0ec5808a1a338bfdec3c05ddefa2e7406617a'} from 'ACTIONS_MODULE17'\nexport {getFeatureMetadata as '40306a89a2c907442e515b25e00379f8fd0b4403d3'} from 'ACTIONS_MODULE18'\nexport {archiveFeature as '409c6a3d317fe8f02d58823e588796a071e81be44f'} from 'ACTIONS_MODULE19'\nexport {deleteFeature as '785f41cd02af89c4b44f8d222d661a4a534b081923'} from 'ACTIONS_MODULE20'\nexport {resumeFeature as '402a5001445d8c354653c4a59447732df930eeeae9'} from 'ACTIONS_MODULE21'\nexport {startFeature as '40217ab39df4c598292e413589a39a03ff1567821b'} from 'ACTIONS_MODULE22'\nexport {stopFeature as '405314689dc2fdc3d3267320760cc2912860068706'} from 'ACTIONS_MODULE23'\nexport {unarchiveFeature as '4056493ad4e1f0b52d9ffb6cd926ce616630546083'} from 'ACTIONS_MODULE24'\nexport {addRepository as '40885ae2064e9aa9d12636caabc74c8e36c76939e2'} from 'ACTIONS_MODULE25'\nexport {deleteRepository as '40090d50d2dfeaaa5c021cfb7c005a37c84488a7f7'} from 'ACTIONS_MODULE26'\nexport {getGitRepoInfo as '60677743b16cef93db184f364ea5d4365577e4ff10'} from 'ACTIONS_MODULE27'\n"],"names":["execFileAsync","git","cwd","args","stdout","timeout","trim","getGitRepoInfo","repositoryPath","commitLimit","empty","commits","branches","remotes","tags","stashCount","currentBranch","diffStats","workingTree","staged","modified","untracked","error","results","Promise","allSettled","val","i","status","value","split","filter","Boolean","map","line","hash","shortHash","subject","author","relativeDate","length","branch","slice","isCurrent","startsWith","clean","name","lastCommitDate","remoteMap","Map","forEach","match","sanitized","replace","set","Array","from","url","statusLines","x","y","diffLine","files","ins","del","filesChanged","parseInt","insertions","deletions","getGitLog","limit","info","entries"],"mappings":"uDAEA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,oBAEA,IAAMA,EAAgB,CAAA,EAAA,EAAA,SAAA,AAAS,EAAC,EAAA,QAAQ,EAExC,eAAeC,EAAIC,CAAW,CAAEC,CAAc,EAC5C,GAAM,QAAEC,CAAM,CAAE,CAAG,MAAMJ,EAAc,MAAOG,EAAM,KAAED,EAAKG,QAAS,GAAK,GACzE,OAAOD,EAAOE,IAAI,EACpB,CA8CO,eAAeC,EACpBC,CAAsB,CACtBC,EAAc,CAAC,EAaf,GAAI,CAACD,EAAeF,IAAI,GACtB,CAD0B,KACnB,CAXPK,QAAS,EAAE,CACXC,SAAU,EAAE,CACZC,QAAS,EAAE,CACXC,KAAM,EAAE,CACRC,WAAY,EACZC,cAAe,GACfC,UAAW,KACXC,YAAa,CAAEC,OAAQ,EAAGC,SAAU,EAAGC,UAAW,CAAE,EAIjCC,MAAO,6BAA8B,EAG1D,IAAMC,EAAU,MAAMC,QAAQC,UAAU,CAAC,CAEvCxB,EAAIO,EAAgB,CAClB,MACA,CAAC,YAAY,EAAEC,EAAAA,CAAa,CAC5B,wCACA,aACD,EAEDR,EAAIO,EAAgB,CAAC,SAAU,iBAAiB,EAEhDP,EAAIO,EAAgB,CAClB,SACA,wBACA,+DACA,aACD,EAEDP,EAAIO,EAAgB,CAAC,SAAU,KAAK,EAEpCP,EAAIO,EAAgB,CAAC,MAAO,sBAAuB,KAAM,4BAA4B,EAErFP,EAAIO,EAAgB,CAAC,QAAS,OAAO,EAErCP,EAAIO,EAAgB,CAAC,SAAU,cAAc,EAE7CP,EAAIO,EAAgB,CAAC,OAAQ,cAAc,EAC5C,EAEKkB,EAAM,AAACC,GAAqC,c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,MA8HA8D,CAAAA,EAAAA,EAAAA,uBAAAA,EAAAA,EAAAA,6CAAAA,0DCtLtB,IAAA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,MACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
module.exports=[21447,19720,a=>{"use strict";var b=a.i(2211),c=a.i(96380),d=a.i(50961);async function e(){let a=(0,c.resolve)("LoadSettingsUseCase"),{workflow:b}=await a.execute();return{approvalGates:{allowPrd:b.approvalGateDefaults.allowPrd,allowPlan:b.approvalGateDefaults.allowPlan,allowMerge:b.approvalGateDefaults.allowMerge},push:b.approvalGateDefaults.pushOnImplementationComplete,openPr:b.openPrOnImplementationComplete,ciWatchEnabled:b.ciWatchEnabled,enableEvidence:b.enableEvidence,commitEvidence:b.commitEvidence,fast:b.defaultFastMode}}(0,d.ensureServerEntryExports)([e]),(0,b.registerServerReference)(e,"
|
|
1
|
+
module.exports=[21447,19720,a=>{"use strict";var b=a.i(2211),c=a.i(96380),d=a.i(50961);async function e(){let a=(0,c.resolve)("LoadSettingsUseCase"),{workflow:b}=await a.execute();return{approvalGates:{allowPrd:b.approvalGateDefaults.allowPrd,allowPlan:b.approvalGateDefaults.allowPlan,allowMerge:b.approvalGateDefaults.allowMerge},push:b.approvalGateDefaults.pushOnImplementationComplete,openPr:b.openPrOnImplementationComplete,ciWatchEnabled:b.ciWatchEnabled,enableEvidence:b.enableEvidence,commitEvidence:b.commitEvidence,fast:b.defaultFastMode}}(0,d.ensureServerEntryExports)([e]),(0,b.registerServerReference)(e,"00ba11698977e5c1f222772698c01947686d97227d",null),a.s(["getWorkflowDefaults",0,e],21447);let f=new Set(["ADMIN","MAINTAIN","WRITE"]);async function g(a){try{let b=(0,c.resolve)("IGitHubRepositoryService"),d=await b.getViewerPermission(a);return{canPushDirectly:f.has(d)}}catch{return{canPushDirectly:!1}}}(0,d.ensureServerEntryExports)([g]),(0,b.registerServerReference)(g,"40cc24fe72db422b72baa8d6e887613cb12b3b2b75",null),a.s(["getViewerPermission",0,g],19720)},77605,a=>{"use strict";var b=a.i(2211),c=a.i(96380);async function d(a){let{description:b,repositoryPath:d,attachments:e,sessionId:f,approvalGates:g,push:h,openPr:i,parentId:j,fast:k,pending:l,forkAndPr:m,commitSpecs:n,ciWatchEnabled:o,enableEvidence:p,commitEvidence:q,agentType:r,model:s,rebaseBeforeBranch:t}=a;if(!b?.trim())return{error:"description is required"};if(!d?.trim())return{error:"repositoryPath is required"};let u=function(a,b){if(!b||0===b.length)return a;let c=b.map(a=>a.notes?.trim()?`@${a.path} [Note: ${a.notes.trim()}]`:`@${a.path}`).join(" ");return`${a}
|
|
2
2
|
|
|
3
|
-
${c}`}(b,e),v={allowPrd:g?.allowPrd??!1,allowPlan:g?.allowPlan??!1,allowMerge:g?.allowMerge??!1};try{let a=(0,c.resolve)("CreateFeatureUseCase"),{feature:e,shouldSpawn:g}=await a.createRecord({userInput:u,repositoryPath:d,approvalGates:v,push:h??!1,openPr:i??!1,...j?{parentId:j}:{},description:b,...k?{fast:k}:{},...l?{pending:l}:{},...null!=m?{forkAndPr:m}:{},...null!=n?{commitSpecs:n}:{},...null!=o?{ciWatchEnabled:o}:{},...null!=p?{enableEvidence:p}:{},...null!=q?{commitEvidence:q}:{},...r?{agentType:r}:{},...s?{model:s}:{},...null!=t?{rebaseBeforeBranch:t}:{}});return a.initializeAndSpawn(e,{userInput:u,repositoryPath:d,approvalGates:v,push:h??!1,openPr:i??!1,...j?{parentId:j}:{},...k?{fast:k}:{},...l?{pending:l}:{},...null!=m?{forkAndPr:m}:{},...null!=n?{commitSpecs:n}:{},...null!=o?{ciWatchEnabled:o}:{},...null!=p?{enableEvidence:p}:{},...null!=q?{commitEvidence:q}:{},...r?{agentType:r}:{},...s?{model:s}:{},...f?{sessionId:f}:{},...null!=t?{rebaseBeforeBranch:t}:{}},g).catch(a=>{console.error("[createFeature] initializeAndSpawn failed:",a)}),{feature:e}}catch(a){return{error:a instanceof Error?a.message:"Failed to create feature"}}}(0,a.i(50961).ensureServerEntryExports)([d]),(0,b.registerServerReference)(d,"
|
|
3
|
+
${c}`}(b,e),v={allowPrd:g?.allowPrd??!1,allowPlan:g?.allowPlan??!1,allowMerge:g?.allowMerge??!1};try{let a=(0,c.resolve)("CreateFeatureUseCase"),{feature:e,shouldSpawn:g}=await a.createRecord({userInput:u,repositoryPath:d,approvalGates:v,push:h??!1,openPr:i??!1,...j?{parentId:j}:{},description:b,...k?{fast:k}:{},...l?{pending:l}:{},...null!=m?{forkAndPr:m}:{},...null!=n?{commitSpecs:n}:{},...null!=o?{ciWatchEnabled:o}:{},...null!=p?{enableEvidence:p}:{},...null!=q?{commitEvidence:q}:{},...r?{agentType:r}:{},...s?{model:s}:{},...null!=t?{rebaseBeforeBranch:t}:{}});return a.initializeAndSpawn(e,{userInput:u,repositoryPath:d,approvalGates:v,push:h??!1,openPr:i??!1,...j?{parentId:j}:{},...k?{fast:k}:{},...l?{pending:l}:{},...null!=m?{forkAndPr:m}:{},...null!=n?{commitSpecs:n}:{},...null!=o?{ciWatchEnabled:o}:{},...null!=p?{enableEvidence:p}:{},...null!=q?{commitEvidence:q}:{},...r?{agentType:r}:{},...s?{model:s}:{},...f?{sessionId:f}:{},...null!=t?{rebaseBeforeBranch:t}:{}},g).catch(a=>{console.error("[createFeature] initializeAndSpawn failed:",a)}),{feature:e}}catch(a){return{error:a instanceof Error?a.message:"Failed to create feature"}}}(0,a.i(50961).ensureServerEntryExports)([d]),(0,b.registerServerReference)(d,"401128c86a50540ecb3f59feb73171107a7dc8726d",null),a.s(["createFeature",0,d],77605)},71100,a=>{"use strict";var b=a.i(23504),c=a.i(27900),d=a.i(12513),e=a.i(73101),f=a.i(54775),g=a.i(65324),h=a.i(33841),i=a.i(46646),j=a.i(68670),k=a.i(85321),l=a.i(84095),m=a.i(56799),n=a.i(80496),o=a.i(93225),p=a.i(94691),q=a.i(41872),r=a.i(9959),s=a.i(79124),t=a.i(29207),u=a.i(10528),v=a.i(50845),w=a.i(26604),x=a.i(54723),y=a.i(18942),z=a.i(42886),A=a.i(49560),B=a.i(39353),C=a.i(21447),D=a.i(19720),E=a.i(77605);a.s([],82094),a.i(82094),a.s(["0060e775107df16b7b19d6e47a7415dd6aedad7619",()=>r.checkAgentAuth,"006d6a821da9c521f994872f6661ea6406703cf09d",()=>q.isAgentSetupComplete,"007f77d6c65b2ddc62646c97be4a2683c8426167b6",()=>f.listGitHubOrganizations,"00928d754474788ad4c6fbbffcf4486c641fc91c3c",()=>d.pickFolder,"009df0ec5808a1a338bfdec3c05ddefa2e7406617a",()=>s.checkToolStatus,"00b5162135ada648e72b38230e961529be25dd7bd8",()=>b.getAllAgentModels,"00ba11698977e5c1f222772698c01947686d97227d",()=>C.getWorkflowDefaults,"40090d50d2dfeaaa5c021cfb7c005a37c84488a7f7",()=>B.deleteRepository,"401128c86a50540ecb3f59feb73171107a7dc8726d",()=>E.createFeature,"401b1c4187ac45173c36e173144ba201fe13d45124",()=>e.listGitHubRepositories,"40217ab39df4c598292e413589a39a03ff1567821b",()=>x.startFeature,"402a5001445d8c354653c4a59447732df930eeeae9",()=>w.resumeFeature,"402daf0bf817e3bbe4129f413ff47d052ad354069c",()=>j.stopDeployment,"40306a89a2c907442e515b25e00379f8fd0b4403d3",()=>t.getFeatureMetadata,"4031454b289e8be2efef97c9616a65533d8a72eb59",()=>o.syncRepository,"403b83d2370ec6d9446fd573f8c6c439e91d1aeca2",()=>h.deployFeature,"405314689dc2fdc3d3267320760cc2912860068706",()=>y.stopFeature,"4056493ad4e1f0b52d9ffb6cd926ce616630546083",()=>z.unarchiveFeature,"406aac6bb69cb2108ce05345c74e9fb7e72dffe3b0",()=>n.openFolder,"40885ae2064e9aa9d12636caabc74c8e36c76939e2",()=>A.addRepository,"408fc9ecc49078119e2600dc1a653a7767b846537c",()=>k.getDeploymentStatus,"409c6a3d317fe8f02d58823e588796a071e81be44f",()=>u.archiveFeature,"40a100fcddf4b7fb563c4be6d841b7aa69d8430016",()=>i.deployRepository,"40b6633f3e7026328d9dcc389e42240cb656b75e9f",()=>p.getDeploymentLogs,"40cc24fe72db422b72baa8d6e887613cb12b3b2b75",()=>D.getViewerPermission,"40d1d3605adec88ff2ff834f1d0b048d1128e7ed32",()=>g.importGitHubRepository,"40e1d5fd96662092ef0a2bd4ea2e6d2697f3ab4c6a",()=>l.openIde,"40eb06a9ce08102cf20c1cb5e3a0e0aeb9bd30770b",()=>m.openShell,"6024f64a42883240ffb5ef570aecd9c0dbe3fba237",()=>c.updateAgentAndModel,"785f41cd02af89c4b44f8d222d661a4a534b081923",()=>v.deleteFeature],71100)}];
|
|
4
4
|
|
|
5
5
|
//# sourceMappingURL=src_presentation_web_06b6~lt._.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../../../../../src/presentation/web/app/actions/get-workflow-defaults.ts","../../../../../../../src/presentation/web/app/actions/get-viewer-permission.ts","../../../../../../../src/presentation/web/app/actions/create-feature.ts","../../../../../../../src/presentation/web/app/actions/compose-user-input.ts","../../../../../../../src/presentation/web/.next-internal/server/app/%28dashboard%29/%40drawer/create/page/actions.js%20%28server%20actions%20loader%29"],"sourcesContent":["'use server';\n\nimport { resolve } from '@/lib/server-container';\nimport type { LoadSettingsUseCase } from '@shipit-ai/core/application/use-cases/settings/load-settings.use-case';\n\nexport interface WorkflowDefaults {\n approvalGates: {\n allowPrd: boolean;\n allowPlan: boolean;\n allowMerge: boolean;\n };\n push: boolean;\n openPr: boolean;\n ciWatchEnabled: boolean;\n enableEvidence: boolean;\n commitEvidence: boolean;\n fast: boolean;\n}\n\nexport async function getWorkflowDefaults(): Promise<WorkflowDefaults> {\n const loadSettings = resolve<LoadSettingsUseCase>('LoadSettingsUseCase');\n const settings = await loadSettings.execute();\n const { workflow } = settings;\n\n return {\n approvalGates: {\n allowPrd: workflow.approvalGateDefaults.allowPrd,\n allowPlan: workflow.approvalGateDefaults.allowPlan,\n allowMerge: workflow.approvalGateDefaults.allowMerge,\n },\n push: workflow.approvalGateDefaults.pushOnImplementationComplete,\n openPr: workflow.openPrOnImplementationComplete,\n ciWatchEnabled: workflow.ciWatchEnabled,\n enableEvidence: workflow.enableEvidence,\n commitEvidence: workflow.commitEvidence,\n fast: workflow.defaultFastMode,\n };\n}\n","'use server';\n\nimport { resolve } from '@/lib/server-container';\nimport type { IGitHubRepositoryService } from '@shipit-ai/core/application/ports/output/services/github-repository-service.interface';\n\n/** Permissions that grant direct push access to a repository. */\nconst PUSH_PERMISSIONS = new Set(['ADMIN', 'MAINTAIN', 'WRITE']);\n\nexport async function getViewerPermission(repoPath: string): Promise<{ canPushDirectly: boolean }> {\n try {\n const service = resolve<IGitHubRepositoryService>('IGitHubRepositoryService');\n const permission = await service.getViewerPermission(repoPath);\n return { canPushDirectly: PUSH_PERMISSIONS.has(permission) };\n } catch {\n return { canPushDirectly: false };\n }\n}\n","'use server';\n\nimport { resolve } from '@/lib/server-container';\nimport type { CreateFeatureUseCase } from '@shipit-ai/core/application/use-cases/features/create/create-feature.use-case';\nimport type { Feature } from '@shipit-ai/core/domain/generated/output';\nimport { composeUserInput } from './compose-user-input';\n\ninterface Attachment {\n path: string;\n name: string;\n notes?: string;\n}\n\ninterface ApprovalGates {\n allowPrd: boolean;\n allowPlan: boolean;\n allowMerge: boolean;\n}\n\ninterface CreateFeatureInput {\n description: string;\n repositoryPath: string;\n attachments?: Attachment[];\n sessionId?: string;\n approvalGates?: {\n allowPrd: boolean;\n allowPlan: boolean;\n allowMerge?: boolean;\n };\n push?: boolean;\n openPr?: boolean;\n parentId?: string;\n /** When true, skip SDLC phases and implement directly from the prompt. */\n fast?: boolean;\n /** When true, create the feature in pending state (no agent spawned). */\n pending?: boolean;\n /** Fork repo and create PR to upstream at merge time. */\n forkAndPr?: boolean;\n /** Commit specs/evidences into the repo (default: true, auto-false when forkAndPr). */\n commitSpecs?: boolean;\n /** Enable CI watch/fix loop after push. */\n ciWatchEnabled?: boolean;\n /** Enable evidence collection after implementation. */\n enableEvidence?: boolean;\n /** Commit evidence to PR. */\n commitEvidence?: boolean;\n /** Optional agent type override for this feature run */\n agentType?: string;\n /** Optional model identifier for this feature run */\n model?: string;\n /** Sync main from remote before creating the feature branch (default: true). */\n rebaseBeforeBranch?: boolean;\n}\n\nexport async function createFeature(\n input: CreateFeatureInput\n): Promise<{ feature?: Feature; error?: string }> {\n const {\n description,\n repositoryPath,\n attachments,\n sessionId,\n approvalGates,\n push,\n openPr,\n parentId,\n fast,\n pending,\n forkAndPr,\n commitSpecs,\n ciWatchEnabled,\n enableEvidence,\n commitEvidence,\n agentType,\n model,\n rebaseBeforeBranch,\n } = input;\n\n if (!description?.trim()) {\n return { error: 'description is required' };\n }\n\n if (!repositoryPath?.trim()) {\n return { error: 'repositoryPath is required' };\n }\n\n const userInput = composeUserInput(description, attachments);\n const gates: ApprovalGates = {\n allowPrd: approvalGates?.allowPrd ?? false,\n allowPlan: approvalGates?.allowPlan ?? false,\n allowMerge: approvalGates?.allowMerge ?? false,\n };\n\n try {\n const createFeatureUseCase = resolve<CreateFeatureUseCase>('CreateFeatureUseCase');\n\n // Phase 1 (fast): create DB record with real UUID — returns immediately\n const { feature, shouldSpawn } = await createFeatureUseCase.createRecord({\n userInput,\n repositoryPath,\n approvalGates: gates,\n push: push ?? false,\n openPr: openPr ?? false,\n ...(parentId ? { parentId } : {}),\n description,\n ...(fast ? { fast } : {}),\n ...(pending ? { pending } : {}),\n ...(forkAndPr != null ? { forkAndPr } : {}),\n ...(commitSpecs != null ? { commitSpecs } : {}),\n ...(ciWatchEnabled != null ? { ciWatchEnabled } : {}),\n ...(enableEvidence != null ? { enableEvidence } : {}),\n ...(commitEvidence != null ? { commitEvidence } : {}),\n ...(agentType ? { agentType } : {}),\n ...(model ? { model } : {}),\n ...(rebaseBeforeBranch != null ? { rebaseBeforeBranch } : {}),\n });\n\n // Phase 2 (background): metadata generation, worktree, spec, agent spawn\n // Fire-and-forget — the UI gets the real feature ID immediately\n createFeatureUseCase\n .initializeAndSpawn(\n feature,\n {\n userInput,\n repositoryPath,\n approvalGates: gates,\n push: push ?? false,\n openPr: openPr ?? false,\n ...(parentId ? { parentId } : {}),\n ...(fast ? { fast } : {}),\n ...(pending ? { pending } : {}),\n ...(forkAndPr != null ? { forkAndPr } : {}),\n ...(commitSpecs != null ? { commitSpecs } : {}),\n ...(ciWatchEnabled != null ? { ciWatchEnabled } : {}),\n ...(enableEvidence != null ? { enableEvidence } : {}),\n ...(commitEvidence != null ? { commitEvidence } : {}),\n ...(agentType ? { agentType } : {}),\n ...(model ? { model } : {}),\n ...(sessionId ? { sessionId } : {}),\n ...(rebaseBeforeBranch != null ? { rebaseBeforeBranch } : {}),\n },\n shouldSpawn\n )\n .catch((err: unknown) => {\n // eslint-disable-next-line no-console\n console.error('[createFeature] initializeAndSpawn failed:', err);\n });\n\n return { feature };\n } catch (error: unknown) {\n const message = error instanceof Error ? error.message : 'Failed to create feature';\n return { error: message };\n }\n}\n","interface Attachment {\n path: string;\n name: string;\n notes?: string;\n}\n\nexport function composeUserInput(\n description: string,\n attachments: Attachment[] | undefined\n): string {\n if (!attachments || attachments.length === 0) {\n return description;\n }\n\n const refs = attachments\n .map((a) => (a.notes?.trim() ? `@${a.path} [Note: ${a.notes.trim()}]` : `@${a.path}`))\n .join(' ');\n return `${description}\\n\\n${refs}`;\n}\n","export {getAllAgentModels as '00cbc4523bf5566fea2d5cf98477b5bf3adbeabce3'} from 'ACTIONS_MODULE0'\nexport {updateAgentAndModel as '607d27ea5d212b8c03d6b47947a6b15a19782e2a95'} from 'ACTIONS_MODULE1'\nexport {pickFolder as '00ac11c8bac2edb4d3cb6e1bfc7e950957ab6fff05'} from 'ACTIONS_MODULE2'\nexport {listGitHubRepositories as '402dc759d6b9f6ac4d0286821d233beb7586bfd6a1'} from 'ACTIONS_MODULE3'\nexport {listGitHubOrganizations as '007430c6e44658511533da6fc18df6a10a77d8ca2f'} from 'ACTIONS_MODULE4'\nexport {importGitHubRepository as '408951cdf9d60d3b3fcefa97ab36845c975e13a4e4'} from 'ACTIONS_MODULE5'\nexport {deployFeature as '4030d28f42b22fbe5c0deddb5a7fdf7c096fc03066'} from 'ACTIONS_MODULE6'\nexport {deployRepository as '4025d2a75d6d6df7203f8a612ff7cb3355a6c1525e'} from 'ACTIONS_MODULE7'\nexport {stopDeployment as '402bfda1e782b375ba1e7b4350dcb2411f747e7759'} from 'ACTIONS_MODULE8'\nexport {getDeploymentStatus as '40f3651a25e60f770e01fc60830b4911e2491df322'} from 'ACTIONS_MODULE9'\nexport {openIde as '40f3fde3affce8285dca5f685141bda496b2e45e0c'} from 'ACTIONS_MODULE10'\nexport {openShell as '4020eb6cd133a6c3dfd8275d14cd43e83d47a93de2'} from 'ACTIONS_MODULE11'\nexport {openFolder as '401ae5ca5ec169940e604f0271d5b3d0051fb26ffb'} from 'ACTIONS_MODULE12'\nexport {syncRepository as '4050fb410229d1171b522d034c23053da254577270'} from 'ACTIONS_MODULE13'\nexport {getDeploymentLogs as '4046e707d870b26bda43482676a885acbc5efb7687'} from 'ACTIONS_MODULE14'\nexport {isAgentSetupComplete as '00ea2e4aeb96147be0df27de0fb0811dcd46d7b284'} from 'ACTIONS_MODULE15'\nexport {checkAgentAuth as '0095abc4000335aa7827a56915d9196e945df0ab50'} from 'ACTIONS_MODULE16'\nexport {checkToolStatus as '00d00bca5810b627fd7f843fa04a97b6756eac2112'} from 'ACTIONS_MODULE17'\nexport {getFeatureMetadata as '40264230f863970e48854876df9f3fc11a8bf79378'} from 'ACTIONS_MODULE18'\nexport {archiveFeature as '409e7f6d9000f7ab91dd4401f2543b2147adb23f81'} from 'ACTIONS_MODULE19'\nexport {deleteFeature as '78e46dbafd792b86405e361f7de33fab8345767ddd'} from 'ACTIONS_MODULE20'\nexport {resumeFeature as '40a1f322bacc7e0c123d20aab8420e1748e5b64122'} from 'ACTIONS_MODULE21'\nexport {startFeature as '402089d3e112c6b2d2afc8c751dbc87755549d0eae'} from 'ACTIONS_MODULE22'\nexport {stopFeature as '40272f295c9d08be7d27e530f118d68eec736ff09d'} from 'ACTIONS_MODULE23'\nexport {unarchiveFeature as '402537786e22ad05934fa43a551ed5b45acf5ff3c0'} from 'ACTIONS_MODULE24'\nexport {addRepository as '4044ad52bb92a547ac306d28c714498429d7ad0e22'} from 'ACTIONS_MODULE25'\nexport {deleteRepository as '404720e2231380d52c29929a6a219b7cc885ea0502'} from 'ACTIONS_MODULE26'\nexport {getWorkflowDefaults as '003ab86bf75e7c3d4253f0673197688f673df5c8d7'} from 'ACTIONS_MODULE27'\nexport {getViewerPermission as '4039b04ad46b9f7fcf1d1d6944ceb81f67b3e99322'} from 'ACTIONS_MODULE28'\nexport {createFeature as '408f8dde9886e951ba8fdf4440a9f500717070d580'} from 'ACTIONS_MODULE29'\nexport {getViewerPermission as '4039b04ad46b9f7fcf1d1d6944ceb81f67b3e99322'} from 'ACTIONS_MODULE28'\n"],"names":["getWorkflowDefaults","loadSettings","settings","execute","workflow","approvalGates","allowPrd","approvalGateDefaults","allowPlan","allowMerge","push","pushOnImplementationComplete","openPr","openPrOnImplementationComplete","ciWatchEnabled","enableEvidence","commitEvidence","fast","defaultFastMode","composeUserInput","description","attachments","length","refs","map","a","notes","trim","path","join"],"mappings":"6DAEA,EAAA,EAAA,CAAA,CAAA,oBAiBO,eAAeA,IACpB,IAAMC,EAAe,CAAA,EAAA,EAAA,OAAA,AAAO,EAAsB,uBAE5C,UAAEG,CAAQ,CAAE,CADD,EACIF,IADED,EAAaE,OAAO,GAG3C,MAAO,CACLE,cAAe,CACbC,SAAUF,EAASG,oBAAoB,CAACD,QAAQ,CAChDE,UAAWJ,EAASG,oBAAoB,CAACC,SAAS,CAClDC,WAAYL,EAASG,oBAAoB,CAACE,UAAU,AACtD,EACAC,KAAMN,EAASG,oBAAoB,CAACI,4BAA4B,CAChEC,OAAQR,EAASS,8BAA8B,CAC/CC,eAAgBV,EAASU,cAAc,CACvCC,eAAgBX,EAASW,cAAc,CACvCC,eAAgBZ,EAASY,cAAc,CACvCC,KAAMb,EAASc,eAAe,AAChC,CACF,iCAlBsBlB,IAAAA,CAAAA,EAAAA,EAAAA,uBAAAA,EAAAA,EAAAA,6CAAAA,6CCbtB,IAAM,EAAmB,IAAI,IAAI,CAAC,QAAS,WAAY,QAAQ,EAExD,eAAe,EAAoB,CAAgB,EACxD,GAAI,CACF,IAAM,EAAU,CAAA,EAAA,EAAA,OAAA,AAAO,EAA2B,4BAC5C,EAAa,MAAM,EAAQ,mBAAmB,CAAC,GACrD,MAAO,CAAE,gBAAiB,EAAiB,GAAG,CAAC,EAAYI,CAC7D,CAAE,KAAMF,CACN,MAAO,CAAE,iBAAiB,CAAM,CAClC,CACF,iCARsB,IAAA,CAAA,EAAA,EAAA,uBAAA,EAAA,EAAA,6CAAA,qFCNtB,EAAA,EAAA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ts","../../../../../../../src/presentation/web/app/actions/get-viewer-permission.ts","../../../../../../../src/presentation/web/app/actions/create-feature.ts","../../../../../../../src/presentation/web/app/actions/compose-user-input.ts","../../../../../../../src/presentation/web/.next-internal/server/app/%28dashboard%29/%40drawer/create/page/actions.js%20%28server%20actions%20loader%29"],"sourcesContent":["'use server';\n\nimport { resolve } from '@/lib/server-container';\nimport type { LoadSettingsUseCase } from '@shipit-ai/core/application/use-cases/settings/load-settings.use-case';\n\nexport interface WorkflowDefaults {\n approvalGates: {\n allowPrd: boolean;\n allowPlan: boolean;\n allowMerge: boolean;\n };\n push: boolean;\n openPr: boolean;\n ciWatchEnabled: boolean;\n enableEvidence: boolean;\n commitEvidence: boolean;\n fast: boolean;\n}\n\nexport async function getWorkflowDefaults(): Promise<WorkflowDefaults> {\n const loadSettings = resolve<LoadSettingsUseCase>('LoadSettingsUseCase');\n const settings = await loadSettings.execute();\n const { workflow } = settings;\n\n return {\n approvalGates: {\n allowPrd: workflow.approvalGateDefaults.allowPrd,\n allowPlan: workflow.approvalGateDefaults.allowPlan,\n allowMerge: workflow.approvalGateDefaults.allowMerge,\n },\n push: workflow.approvalGateDefaults.pushOnImplementationComplete,\n openPr: workflow.openPrOnImplementationComplete,\n ciWatchEnabled: workflow.ciWatchEnabled,\n enableEvidence: workflow.enableEvidence,\n commitEvidence: workflow.commitEvidence,\n fast: workflow.defaultFastMode,\n };\n}\n","'use server';\n\nimport { resolve } from '@/lib/server-container';\nimport type { IGitHubRepositoryService } from '@shipit-ai/core/application/ports/output/services/github-repository-service.interface';\n\n/** Permissions that grant direct push access to a repository. */\nconst PUSH_PERMISSIONS = new Set(['ADMIN', 'MAINTAIN', 'WRITE']);\n\nexport async function getViewerPermission(repoPath: string): Promise<{ canPushDirectly: boolean }> {\n try {\n const service = resolve<IGitHubRepositoryService>('IGitHubRepositoryService');\n const permission = await service.getViewerPermission(repoPath);\n return { canPushDirectly: PUSH_PERMISSIONS.has(permission) };\n } catch {\n return { canPushDirectly: false };\n }\n}\n","'use server';\n\nimport { resolve } from '@/lib/server-container';\nimport type { CreateFeatureUseCase } from '@shipit-ai/core/application/use-cases/features/create/create-feature.use-case';\nimport type { Feature } from '@shipit-ai/core/domain/generated/output';\nimport { composeUserInput } from './compose-user-input';\n\ninterface Attachment {\n path: string;\n name: string;\n notes?: string;\n}\n\ninterface ApprovalGates {\n allowPrd: boolean;\n allowPlan: boolean;\n allowMerge: boolean;\n}\n\ninterface CreateFeatureInput {\n description: string;\n repositoryPath: string;\n attachments?: Attachment[];\n sessionId?: string;\n approvalGates?: {\n allowPrd: boolean;\n allowPlan: boolean;\n allowMerge?: boolean;\n };\n push?: boolean;\n openPr?: boolean;\n parentId?: string;\n /** When true, skip SDLC phases and implement directly from the prompt. */\n fast?: boolean;\n /** When true, create the feature in pending state (no agent spawned). */\n pending?: boolean;\n /** Fork repo and create PR to upstream at merge time. */\n forkAndPr?: boolean;\n /** Commit specs/evidences into the repo (default: true, auto-false when forkAndPr). */\n commitSpecs?: boolean;\n /** Enable CI watch/fix loop after push. */\n ciWatchEnabled?: boolean;\n /** Enable evidence collection after implementation. */\n enableEvidence?: boolean;\n /** Commit evidence to PR. */\n commitEvidence?: boolean;\n /** Optional agent type override for this feature run */\n agentType?: string;\n /** Optional model identifier for this feature run */\n model?: string;\n /** Sync main from remote before creating the feature branch (default: true). */\n rebaseBeforeBranch?: boolean;\n}\n\nexport async function createFeature(\n input: CreateFeatureInput\n): Promise<{ feature?: Feature; error?: string }> {\n const {\n description,\n repositoryPath,\n attachments,\n sessionId,\n approvalGates,\n push,\n openPr,\n parentId,\n fast,\n pending,\n forkAndPr,\n commitSpecs,\n ciWatchEnabled,\n enableEvidence,\n commitEvidence,\n agentType,\n model,\n rebaseBeforeBranch,\n } = input;\n\n if (!description?.trim()) {\n return { error: 'description is required' };\n }\n\n if (!repositoryPath?.trim()) {\n return { error: 'repositoryPath is required' };\n }\n\n const userInput = composeUserInput(description, attachments);\n const gates: ApprovalGates = {\n allowPrd: approvalGates?.allowPrd ?? false,\n allowPlan: approvalGates?.allowPlan ?? false,\n allowMerge: approvalGates?.allowMerge ?? false,\n };\n\n try {\n const createFeatureUseCase = resolve<CreateFeatureUseCase>('CreateFeatureUseCase');\n\n // Phase 1 (fast): create DB record with real UUID — returns immediately\n const { feature, shouldSpawn } = await createFeatureUseCase.createRecord({\n userInput,\n repositoryPath,\n approvalGates: gates,\n push: push ?? false,\n openPr: openPr ?? false,\n ...(parentId ? { parentId } : {}),\n description,\n ...(fast ? { fast } : {}),\n ...(pending ? { pending } : {}),\n ...(forkAndPr != null ? { forkAndPr } : {}),\n ...(commitSpecs != null ? { commitSpecs } : {}),\n ...(ciWatchEnabled != null ? { ciWatchEnabled } : {}),\n ...(enableEvidence != null ? { enableEvidence } : {}),\n ...(commitEvidence != null ? { commitEvidence } : {}),\n ...(agentType ? { agentType } : {}),\n ...(model ? { model } : {}),\n ...(rebaseBeforeBranch != null ? { rebaseBeforeBranch } : {}),\n });\n\n // Phase 2 (background): metadata generation, worktree, spec, agent spawn\n // Fire-and-forget — the UI gets the real feature ID immediately\n createFeatureUseCase\n .initializeAndSpawn(\n feature,\n {\n userInput,\n repositoryPath,\n approvalGates: gates,\n push: push ?? false,\n openPr: openPr ?? false,\n ...(parentId ? { parentId } : {}),\n ...(fast ? { fast } : {}),\n ...(pending ? { pending } : {}),\n ...(forkAndPr != null ? { forkAndPr } : {}),\n ...(commitSpecs != null ? { commitSpecs } : {}),\n ...(ciWatchEnabled != null ? { ciWatchEnabled } : {}),\n ...(enableEvidence != null ? { enableEvidence } : {}),\n ...(commitEvidence != null ? { commitEvidence } : {}),\n ...(agentType ? { agentType } : {}),\n ...(model ? { model } : {}),\n ...(sessionId ? { sessionId } : {}),\n ...(rebaseBeforeBranch != null ? { rebaseBeforeBranch } : {}),\n },\n shouldSpawn\n )\n .catch((err: unknown) => {\n // eslint-disable-next-line no-console\n console.error('[createFeature] initializeAndSpawn failed:', err);\n });\n\n return { feature };\n } catch (error: unknown) {\n const message = error instanceof Error ? error.message : 'Failed to create feature';\n return { error: message };\n }\n}\n","interface Attachment {\n path: string;\n name: string;\n notes?: string;\n}\n\nexport function composeUserInput(\n description: string,\n attachments: Attachment[] | undefined\n): string {\n if (!attachments || attachments.length === 0) {\n return description;\n }\n\n const refs = attachments\n .map((a) => (a.notes?.trim() ? `@${a.path} [Note: ${a.notes.trim()}]` : `@${a.path}`))\n .join(' ');\n return `${description}\\n\\n${refs}`;\n}\n","export {getAllAgentModels as '00b5162135ada648e72b38230e961529be25dd7bd8'} from 'ACTIONS_MODULE0'\nexport {updateAgentAndModel as '6024f64a42883240ffb5ef570aecd9c0dbe3fba237'} from 'ACTIONS_MODULE1'\nexport {pickFolder as '00928d754474788ad4c6fbbffcf4486c641fc91c3c'} from 'ACTIONS_MODULE2'\nexport {listGitHubRepositories as '401b1c4187ac45173c36e173144ba201fe13d45124'} from 'ACTIONS_MODULE3'\nexport {listGitHubOrganizations as '007f77d6c65b2ddc62646c97be4a2683c8426167b6'} from 'ACTIONS_MODULE4'\nexport {importGitHubRepository as '40d1d3605adec88ff2ff834f1d0b048d1128e7ed32'} from 'ACTIONS_MODULE5'\nexport {deployFeature as '403b83d2370ec6d9446fd573f8c6c439e91d1aeca2'} from 'ACTIONS_MODULE6'\nexport {deployRepository as '40a100fcddf4b7fb563c4be6d841b7aa69d8430016'} from 'ACTIONS_MODULE7'\nexport {stopDeployment as '402daf0bf817e3bbe4129f413ff47d052ad354069c'} from 'ACTIONS_MODULE8'\nexport {getDeploymentStatus as '408fc9ecc49078119e2600dc1a653a7767b846537c'} from 'ACTIONS_MODULE9'\nexport {openIde as '40e1d5fd96662092ef0a2bd4ea2e6d2697f3ab4c6a'} from 'ACTIONS_MODULE10'\nexport {openShell as '40eb06a9ce08102cf20c1cb5e3a0e0aeb9bd30770b'} from 'ACTIONS_MODULE11'\nexport {openFolder as '406aac6bb69cb2108ce05345c74e9fb7e72dffe3b0'} from 'ACTIONS_MODULE12'\nexport {syncRepository as '4031454b289e8be2efef97c9616a65533d8a72eb59'} from 'ACTIONS_MODULE13'\nexport {getDeploymentLogs as '40b6633f3e7026328d9dcc389e42240cb656b75e9f'} from 'ACTIONS_MODULE14'\nexport {isAgentSetupComplete as '006d6a821da9c521f994872f6661ea6406703cf09d'} from 'ACTIONS_MODULE15'\nexport {checkAgentAuth as '0060e775107df16b7b19d6e47a7415dd6aedad7619'} from 'ACTIONS_MODULE16'\nexport {checkToolStatus as '009df0ec5808a1a338bfdec3c05ddefa2e7406617a'} from 'ACTIONS_MODULE17'\nexport {getFeatureMetadata as '40306a89a2c907442e515b25e00379f8fd0b4403d3'} from 'ACTIONS_MODULE18'\nexport {archiveFeature as '409c6a3d317fe8f02d58823e588796a071e81be44f'} from 'ACTIONS_MODULE19'\nexport {deleteFeature as '785f41cd02af89c4b44f8d222d661a4a534b081923'} from 'ACTIONS_MODULE20'\nexport {resumeFeature as '402a5001445d8c354653c4a59447732df930eeeae9'} from 'ACTIONS_MODULE21'\nexport {startFeature as '40217ab39df4c598292e413589a39a03ff1567821b'} from 'ACTIONS_MODULE22'\nexport {stopFeature as '405314689dc2fdc3d3267320760cc2912860068706'} from 'ACTIONS_MODULE23'\nexport {unarchiveFeature as '4056493ad4e1f0b52d9ffb6cd926ce616630546083'} from 'ACTIONS_MODULE24'\nexport {addRepository as '40885ae2064e9aa9d12636caabc74c8e36c76939e2'} from 'ACTIONS_MODULE25'\nexport {deleteRepository as '40090d50d2dfeaaa5c021cfb7c005a37c84488a7f7'} from 'ACTIONS_MODULE26'\nexport {getWorkflowDefaults as '00ba11698977e5c1f222772698c01947686d97227d'} from 'ACTIONS_MODULE27'\nexport {getViewerPermission as '40cc24fe72db422b72baa8d6e887613cb12b3b2b75'} from 'ACTIONS_MODULE28'\nexport {createFeature as '401128c86a50540ecb3f59feb73171107a7dc8726d'} from 'ACTIONS_MODULE29'\nexport {getViewerPermission as '40cc24fe72db422b72baa8d6e887613cb12b3b2b75'} from 'ACTIONS_MODULE28'\n"],"names":["getWorkflowDefaults","loadSettings","settings","execute","workflow","approvalGates","allowPrd","approvalGateDefaults","allowPlan","allowMerge","push","pushOnImplementationComplete","openPr","openPrOnImplementationComplete","ciWatchEnabled","enableEvidence","commitEvidence","fast","defaultFastMode","composeUserInput","description","attachments","length","refs","map","a","notes","trim","path","join"],"mappings":"6DAEA,EAAA,EAAA,CAAA,CAAA,oBAiBO,eAAeA,IACpB,IAAMC,EAAe,CAAA,EAAA,EAAA,OAAA,AAAO,EAAsB,uBAE5C,UAAEG,CAAQ,CAAE,CADD,EACIF,IADED,EAAaE,OAAO,GAG3C,MAAO,CACLE,cAAe,CACbC,SAAUF,EAASG,oBAAoB,CAACD,QAAQ,CAChDE,UAAWJ,EAASG,oBAAoB,CAACC,SAAS,CAClDC,WAAYL,EAASG,oBAAoB,CAACE,UAAU,AACtD,EACAC,KAAMN,EAASG,oBAAoB,CAACI,4BAA4B,CAChEC,OAAQR,EAASS,8BAA8B,CAC/CC,eAAgBV,EAASU,cAAc,CACvCC,eAAgBX,EAASW,cAAc,CACvCC,eAAgBZ,EAASY,cAAc,CACvCC,KAAMb,EAASc,eAAe,AAChC,CACF,iCAlBsBlB,IAAAA,CAAAA,EAAAA,EAAAA,uBAAAA,EAAAA,EAAAA,6CAAAA,6CCbtB,IAAM,EAAmB,IAAI,IAAI,CAAC,QAAS,WAAY,QAAQ,EAExD,eAAe,EAAoB,CAAgB,EACxD,GAAI,CACF,IAAM,EAAU,CAAA,EAAA,EAAA,OAAA,AAAO,EAA2B,4BAC5C,EAAa,MAAM,EAAQ,mBAAmB,CAAC,GACrD,MAAO,CAAE,gBAAiB,EAAiB,GAAG,CAAC,EAAYI,CAC7D,CAAE,KAAMF,CACN,MAAO,CAAE,iBAAiB,CAAM,CAClC,CACF,iCARsB,IAAA,CAAA,EAAA,EAAA,uBAAA,EAAA,EAAA,6CAAA,qFCNtB,EAAA,EAAA,CAAA,CAAA,OAoDO,eAAe,EACpB,CAAyB,EAEzB,GAAM,aACJ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c.execFile);async function g(a,b){let{stdout:c}=await f("git",b,{cwd:a,timeout:5e3});return c.trim()}async function h(a,b=8){if(!a.trim())return{commits:[],branches:[],remotes:[],tags:[],stashCount:0,currentBranch:"",diffStats:null,workingTree:{staged:0,modified:0,untracked:0},error:"Repository path is required"};let c=await Promise.allSettled([g(a,["log",`--max-count=${b}`,"--format=%H%x00%h%x00%s%x00%an%x00%cr","--no-color"]),g(a,["branch","--show-current"]),g(a,["branch","--sort=-committerdate","--format=%(HEAD)%(refname:short)%00%(committerdate:relative)","--no-color"]),g(a,["remote","-v"]),g(a,["tag","--sort=-creatordate","-l","--format=%(refname:short)"]),g(a,["stash","list"]),g(a,["status","--porcelain"]),g(a,["diff","--shortstat"])]),d=a=>"fulfilled"===c[a].status?c[a].value:"",e=d(0).split("\n").filter(Boolean).map(a=>{let[b,c,d,e,f]=a.split("\0");return{hash:b,shortHash:c,subject:d,author:e,relativeDate:f}}),f=d(1);e.length>0&&f&&(e[0].branch=f);let i=d(2).split("\n").filter(Boolean).slice(0,10).map(a=>{let b=a.startsWith("*"),[c,d]=(b?a.slice(1):a).split("\0");return{name:c.trim(),isCurrent:b,lastCommitDate:d?.trim()??""}}),j=new Map;d(3).split("\n").filter(Boolean).forEach(a=>{let b=a.match(/^(\S+)\s+(\S+)\s+\(fetch\)/);if(b){let a=b[2].replace(/\/\/[^@]+@/,"//").replace(/x-access-token:[^@]+@/,"");j.set(b[1],a)}});let k=Array.from(j,([a,b])=>({name:a,url:b})),l=d(4).split("\n").filter(Boolean).slice(0,5),m=d(5).split("\n").filter(Boolean).length,n=d(6).split("\n").filter(Boolean),o={staged:0,modified:0,untracked:0};for(let a of n){let b=a[0],c=a[1];"?"===b&&"?"===c?o.untracked++:" "!==b&&"?"!==b&&o.staged++," "!==c&&"?"!==c&&o.modified++}let p=null,q=d(7);if(q){let a=q.match(/(\d+) file/),b=q.match(/(\d+) insertion/),c=q.match(/(\d+) deletion/);p={filesChanged:a?parseInt(a[1],10):0,insertions:b?parseInt(b[1],10):0,deletions:c?parseInt(c[1],10):0}}return{commits:e,branches:i,remotes:k,tags:l,stashCount:m,currentBranch:f,diffStats:p,workingTree:o}}async function i(a,b=10){let c=await h(a,b);return{entries:c.commits,error:c.error}}(0,e.ensureServerEntryExports)([h,i]),(0,b.registerServerReference)(h,"
|
|
1
|
+
module.exports=[35556,a=>{"use strict";var b=a.i(2211),c=a.i(74533),d=a.i(12057),e=a.i(50961);let f=(0,d.promisify)(c.execFile);async function g(a,b){let{stdout:c}=await f("git",b,{cwd:a,timeout:5e3});return c.trim()}async function h(a,b=8){if(!a.trim())return{commits:[],branches:[],remotes:[],tags:[],stashCount:0,currentBranch:"",diffStats:null,workingTree:{staged:0,modified:0,untracked:0},error:"Repository path is required"};let c=await Promise.allSettled([g(a,["log",`--max-count=${b}`,"--format=%H%x00%h%x00%s%x00%an%x00%cr","--no-color"]),g(a,["branch","--show-current"]),g(a,["branch","--sort=-committerdate","--format=%(HEAD)%(refname:short)%00%(committerdate:relative)","--no-color"]),g(a,["remote","-v"]),g(a,["tag","--sort=-creatordate","-l","--format=%(refname:short)"]),g(a,["stash","list"]),g(a,["status","--porcelain"]),g(a,["diff","--shortstat"])]),d=a=>"fulfilled"===c[a].status?c[a].value:"",e=d(0).split("\n").filter(Boolean).map(a=>{let[b,c,d,e,f]=a.split("\0");return{hash:b,shortHash:c,subject:d,author:e,relativeDate:f}}),f=d(1);e.length>0&&f&&(e[0].branch=f);let i=d(2).split("\n").filter(Boolean).slice(0,10).map(a=>{let b=a.startsWith("*"),[c,d]=(b?a.slice(1):a).split("\0");return{name:c.trim(),isCurrent:b,lastCommitDate:d?.trim()??""}}),j=new Map;d(3).split("\n").filter(Boolean).forEach(a=>{let b=a.match(/^(\S+)\s+(\S+)\s+\(fetch\)/);if(b){let a=b[2].replace(/\/\/[^@]+@/,"//").replace(/x-access-token:[^@]+@/,"");j.set(b[1],a)}});let k=Array.from(j,([a,b])=>({name:a,url:b})),l=d(4).split("\n").filter(Boolean).slice(0,5),m=d(5).split("\n").filter(Boolean).length,n=d(6).split("\n").filter(Boolean),o={staged:0,modified:0,untracked:0};for(let a of n){let b=a[0],c=a[1];"?"===b&&"?"===c?o.untracked++:" "!==b&&"?"!==b&&o.staged++," "!==c&&"?"!==c&&o.modified++}let p=null,q=d(7);if(q){let a=q.match(/(\d+) file/),b=q.match(/(\d+) insertion/),c=q.match(/(\d+) deletion/);p={filesChanged:a?parseInt(a[1],10):0,insertions:b?parseInt(b[1],10):0,deletions:c?parseInt(c[1],10):0}}return{commits:e,branches:i,remotes:k,tags:l,stashCount:m,currentBranch:f,diffStats:p,workingTree:o}}async function i(a,b=10){let c=await h(a,b);return{entries:c.commits,error:c.error}}(0,e.ensureServerEntryExports)([h,i]),(0,b.registerServerReference)(h,"60677743b16cef93db184f364ea5d4365577e4ff10",null),(0,b.registerServerReference)(i,"605b636556deda767073e576fa60082cf49d414ba8",null),a.s(["getGitRepoInfo",0,h])},29507,a=>{"use strict";var b=a.i(23504),c=a.i(27900),d=a.i(12513),e=a.i(73101),f=a.i(54775),g=a.i(65324),h=a.i(33841),i=a.i(46646),j=a.i(68670),k=a.i(85321),l=a.i(84095),m=a.i(56799),n=a.i(80496),o=a.i(93225),p=a.i(94691),q=a.i(41872),r=a.i(9959),s=a.i(79124),t=a.i(29207),u=a.i(10528),v=a.i(50845),w=a.i(26604),x=a.i(54723),y=a.i(18942),z=a.i(42886),A=a.i(49560),B=a.i(39353),C=a.i(35556);a.s([],37447),a.i(37447),a.s(["0060e775107df16b7b19d6e47a7415dd6aedad7619",()=>r.checkAgentAuth,"006d6a821da9c521f994872f6661ea6406703cf09d",()=>q.isAgentSetupComplete,"007f77d6c65b2ddc62646c97be4a2683c8426167b6",()=>f.listGitHubOrganizations,"00928d754474788ad4c6fbbffcf4486c641fc91c3c",()=>d.pickFolder,"009df0ec5808a1a338bfdec3c05ddefa2e7406617a",()=>s.checkToolStatus,"00b5162135ada648e72b38230e961529be25dd7bd8",()=>b.getAllAgentModels,"40090d50d2dfeaaa5c021cfb7c005a37c84488a7f7",()=>B.deleteRepository,"401b1c4187ac45173c36e173144ba201fe13d45124",()=>e.listGitHubRepositories,"40217ab39df4c598292e413589a39a03ff1567821b",()=>x.startFeature,"402a5001445d8c354653c4a59447732df930eeeae9",()=>w.resumeFeature,"402daf0bf817e3bbe4129f413ff47d052ad354069c",()=>j.stopDeployment,"40306a89a2c907442e515b25e00379f8fd0b4403d3",()=>t.getFeatureMetadata,"4031454b289e8be2efef97c9616a65533d8a72eb59",()=>o.syncRepository,"403b83d2370ec6d9446fd573f8c6c439e91d1aeca2",()=>h.deployFeature,"405314689dc2fdc3d3267320760cc2912860068706",()=>y.stopFeature,"4056493ad4e1f0b52d9ffb6cd926ce616630546083",()=>z.unarchiveFeature,"406aac6bb69cb2108ce05345c74e9fb7e72dffe3b0",()=>n.openFolder,"40885ae2064e9aa9d12636caabc74c8e36c76939e2",()=>A.addRepository,"408fc9ecc49078119e2600dc1a653a7767b846537c",()=>k.getDeploymentStatus,"409c6a3d317fe8f02d58823e588796a071e81be44f",()=>u.archiveFeature,"40a100fcddf4b7fb563c4be6d841b7aa69d8430016",()=>i.deployRepository,"40b6633f3e7026328d9dcc389e42240cb656b75e9f",()=>p.getDeploymentLogs,"40d1d3605adec88ff2ff834f1d0b048d1128e7ed32",()=>g.importGitHubRepository,"40e1d5fd96662092ef0a2bd4ea2e6d2697f3ab4c6a",()=>l.openIde,"40eb06a9ce08102cf20c1cb5e3a0e0aeb9bd30770b",()=>m.openShell,"6024f64a42883240ffb5ef570aecd9c0dbe3fba237",()=>c.updateAgentAndModel,"60677743b16cef93db184f364ea5d4365577e4ff10",()=>C.getGitRepoInfo,"785f41cd02af89c4b44f8d222d661a4a534b081923",()=>v.deleteFeature],29507)}];
|
|
2
2
|
|
|
3
3
|
//# sourceMappingURL=src_presentation_web_08fy2mf._.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../../../../../src/presentation/web/app/actions/get-git-log.ts","../../../../../../../src/presentation/web/.next-internal/server/app/%28dashboard%29/%40drawer/repository/%5BrepositoryId%5D/page/actions.js%20%28server%20actions%20loader%29"],"sourcesContent":["'use server';\n\nimport { execFile } from 'node:child_process';\nimport { promisify } from 'node:util';\n\nconst execFileAsync = promisify(execFile);\n\nasync function git(cwd: string, args: string[]): Promise<string> {\n const { stdout } = await execFileAsync('git', args, { cwd, timeout: 5000 });\n return stdout.trim();\n}\n\nexport interface GitLogEntry {\n hash: string;\n shortHash: string;\n subject: string;\n author: string;\n relativeDate: string;\n branch?: string;\n}\n\nexport interface GitBranchInfo {\n name: string;\n isCurrent: boolean;\n lastCommitDate: string;\n}\n\nexport interface GitRemoteInfo {\n name: string;\n url: string;\n}\n\nexport interface GitWorkingTreeStatus {\n staged: number;\n modified: number;\n untracked: number;\n}\n\nexport interface GitDiffStats {\n filesChanged: number;\n insertions: number;\n deletions: number;\n}\n\nexport interface GitRepoInfo {\n commits: GitLogEntry[];\n branches: GitBranchInfo[];\n remotes: GitRemoteInfo[];\n tags: string[];\n stashCount: number;\n currentBranch: string;\n diffStats: GitDiffStats | null;\n workingTree: GitWorkingTreeStatus;\n error?: string;\n}\n\nexport async function getGitRepoInfo(\n repositoryPath: string,\n commitLimit = 8\n): Promise<GitRepoInfo> {\n const empty: GitRepoInfo = {\n commits: [],\n branches: [],\n remotes: [],\n tags: [],\n stashCount: 0,\n currentBranch: '',\n diffStats: null,\n workingTree: { staged: 0, modified: 0, untracked: 0 },\n };\n\n if (!repositoryPath.trim()) {\n return { ...empty, error: 'Repository path is required' };\n }\n\n const results = await Promise.allSettled([\n // 0: commits\n git(repositoryPath, [\n 'log',\n `--max-count=${commitLimit}`,\n '--format=%H%x00%h%x00%s%x00%an%x00%cr',\n '--no-color',\n ]),\n // 1: current branch\n git(repositoryPath, ['branch', '--show-current']),\n // 2: branches with dates\n git(repositoryPath, [\n 'branch',\n '--sort=-committerdate',\n '--format=%(HEAD)%(refname:short)%00%(committerdate:relative)',\n '--no-color',\n ]),\n // 3: remotes\n git(repositoryPath, ['remote', '-v']),\n // 4: tags (recent 5)\n git(repositoryPath, ['tag', '--sort=-creatordate', '-l', '--format=%(refname:short)']),\n // 5: stash count\n git(repositoryPath, ['stash', 'list']),\n // 6: working tree status\n git(repositoryPath, ['status', '--porcelain']),\n // 7: diff stats (uncommitted)\n git(repositoryPath, ['diff', '--shortstat']),\n ]);\n\n const val = (i: number) => (results[i].status === 'fulfilled' ? results[i].value : '');\n\n // Parse commits\n const commits: GitLogEntry[] = val(0)\n .split('\\n')\n .filter(Boolean)\n .map((line: string) => {\n const [hash, shortHash, subject, author, relativeDate] = line.split('\\0');\n return { hash, shortHash, subject, author, relativeDate };\n });\n\n const currentBranch = val(1);\n if (commits.length > 0 && currentBranch) {\n commits[0].branch = currentBranch;\n }\n\n // Parse branches\n const branches: GitBranchInfo[] = val(2)\n .split('\\n')\n .filter(Boolean)\n .slice(0, 10)\n .map((line: string) => {\n const isCurrent = line.startsWith('*');\n const clean = isCurrent ? line.slice(1) : line;\n const [name, lastCommitDate] = clean.split('\\0');\n return { name: name.trim(), isCurrent, lastCommitDate: lastCommitDate?.trim() ?? '' };\n });\n\n // Parse remotes (dedup fetch/push)\n const remoteMap = new Map<string, string>();\n val(3)\n .split('\\n')\n .filter(Boolean)\n .forEach((line: string) => {\n const match = line.match(/^(\\S+)\\s+(\\S+)\\s+\\(fetch\\)/);\n if (match) {\n // Strip credentials/tokens from URL before sending to client\n const sanitized = match[2].replace(/\\/\\/[^@]+@/, '//').replace(/x-access-token:[^@]+@/, '');\n remoteMap.set(match[1], sanitized);\n }\n });\n const remotes: GitRemoteInfo[] = Array.from(remoteMap, ([name, url]) => ({ name, url }));\n\n // Parse tags (top 5)\n const tags = val(4).split('\\n').filter(Boolean).slice(0, 5);\n\n // Stash count\n const stashCount = val(5).split('\\n').filter(Boolean).length;\n\n // Working tree status\n const statusLines = val(6).split('\\n').filter(Boolean);\n const workingTree: GitWorkingTreeStatus = { staged: 0, modified: 0, untracked: 0 };\n for (const line of statusLines) {\n const x = line[0];\n const y = line[1];\n if (x === '?' && y === '?') workingTree.untracked++;\n else if (x !== ' ' && x !== '?') workingTree.staged++;\n if (y !== ' ' && y !== '?') workingTree.modified++;\n }\n\n // Diff stats\n let diffStats: GitDiffStats | null = null;\n const diffLine = val(7);\n if (diffLine) {\n const files = diffLine.match(/(\\d+) file/);\n const ins = diffLine.match(/(\\d+) insertion/);\n const del = diffLine.match(/(\\d+) deletion/);\n diffStats = {\n filesChanged: files ? parseInt(files[1], 10) : 0,\n insertions: ins ? parseInt(ins[1], 10) : 0,\n deletions: del ? parseInt(del[1], 10) : 0,\n };\n }\n\n return { commits, branches, remotes, tags, stashCount, currentBranch, diffStats, workingTree };\n}\n\n// Keep backward compat\nexport async function getGitLog(\n repositoryPath: string,\n limit = 10\n): Promise<{ entries: GitLogEntry[]; error?: string }> {\n const info = await getGitRepoInfo(repositoryPath, limit);\n return { entries: info.commits, error: info.error };\n}\n","export {getAllAgentModels as '00cbc4523bf5566fea2d5cf98477b5bf3adbeabce3'} from 'ACTIONS_MODULE0'\nexport {updateAgentAndModel as '607d27ea5d212b8c03d6b47947a6b15a19782e2a95'} from 'ACTIONS_MODULE1'\nexport {pickFolder as '00ac11c8bac2edb4d3cb6e1bfc7e950957ab6fff05'} from 'ACTIONS_MODULE2'\nexport {listGitHubRepositories as '402dc759d6b9f6ac4d0286821d233beb7586bfd6a1'} from 'ACTIONS_MODULE3'\nexport {listGitHubOrganizations as '007430c6e44658511533da6fc18df6a10a77d8ca2f'} from 'ACTIONS_MODULE4'\nexport {importGitHubRepository as '408951cdf9d60d3b3fcefa97ab36845c975e13a4e4'} from 'ACTIONS_MODULE5'\nexport {deployFeature as '4030d28f42b22fbe5c0deddb5a7fdf7c096fc03066'} from 'ACTIONS_MODULE6'\nexport {deployRepository as '4025d2a75d6d6df7203f8a612ff7cb3355a6c1525e'} from 'ACTIONS_MODULE7'\nexport {stopDeployment as '402bfda1e782b375ba1e7b4350dcb2411f747e7759'} from 'ACTIONS_MODULE8'\nexport {getDeploymentStatus as '40f3651a25e60f770e01fc60830b4911e2491df322'} from 'ACTIONS_MODULE9'\nexport {openIde as '40f3fde3affce8285dca5f685141bda496b2e45e0c'} from 'ACTIONS_MODULE10'\nexport {openShell as '4020eb6cd133a6c3dfd8275d14cd43e83d47a93de2'} from 'ACTIONS_MODULE11'\nexport {openFolder as '401ae5ca5ec169940e604f0271d5b3d0051fb26ffb'} from 'ACTIONS_MODULE12'\nexport {syncRepository as '4050fb410229d1171b522d034c23053da254577270'} from 'ACTIONS_MODULE13'\nexport {getDeploymentLogs as '4046e707d870b26bda43482676a885acbc5efb7687'} from 'ACTIONS_MODULE14'\nexport {isAgentSetupComplete as '00ea2e4aeb96147be0df27de0fb0811dcd46d7b284'} from 'ACTIONS_MODULE15'\nexport {checkAgentAuth as '0095abc4000335aa7827a56915d9196e945df0ab50'} from 'ACTIONS_MODULE16'\nexport {checkToolStatus as '00d00bca5810b627fd7f843fa04a97b6756eac2112'} from 'ACTIONS_MODULE17'\nexport {getFeatureMetadata as '40264230f863970e48854876df9f3fc11a8bf79378'} from 'ACTIONS_MODULE18'\nexport {archiveFeature as '409e7f6d9000f7ab91dd4401f2543b2147adb23f81'} from 'ACTIONS_MODULE19'\nexport {deleteFeature as '78e46dbafd792b86405e361f7de33fab8345767ddd'} from 'ACTIONS_MODULE20'\nexport {resumeFeature as '40a1f322bacc7e0c123d20aab8420e1748e5b64122'} from 'ACTIONS_MODULE21'\nexport {startFeature as '402089d3e112c6b2d2afc8c751dbc87755549d0eae'} from 'ACTIONS_MODULE22'\nexport {stopFeature as '40272f295c9d08be7d27e530f118d68eec736ff09d'} from 'ACTIONS_MODULE23'\nexport {unarchiveFeature as '402537786e22ad05934fa43a551ed5b45acf5ff3c0'} from 'ACTIONS_MODULE24'\nexport {addRepository as '4044ad52bb92a547ac306d28c714498429d7ad0e22'} from 'ACTIONS_MODULE25'\nexport {deleteRepository as '404720e2231380d52c29929a6a219b7cc885ea0502'} from 'ACTIONS_MODULE26'\nexport {getGitRepoInfo as '60ad77c4518b2b9e558bbeec2bd6f655901779956f'} from 'ACTIONS_MODULE27'\n"],"names":["execFileAsync","git","cwd","args","stdout","timeout","trim","getGitRepoInfo","repositoryPath","commitLimit","empty","commits","branches","remotes","tags","stashCount","currentBranch","diffStats","workingTree","staged","modified","untracked","error","results","Promise","allSettled","val","i","status","value","split","filter","Boolean","map","line","hash","shortHash","subject","author","relativeDate","length","branch","slice","isCurrent","startsWith","clean","name","lastCommitDate","remoteMap","Map","forEach","match","sanitized","replace","set","Array","from","url","statusLines","x","y","diffLine","files","ins","del","filesChanged","parseInt","insertions","deletions","getGitLog","limit","info","entries"],"mappings":"uDAEA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,oBAEA,IAAMA,EAAgB,CAAA,EAAA,EAAA,SAAA,AAAS,EAAC,EAAA,QAAQ,EAExC,eAAeC,EAAIC,CAAW,CAAEC,CAAc,EAC5C,GAAM,QAAEC,CAAM,CAAE,CAAG,MAAMJ,EAAc,MAAOG,EAAM,KAAED,EAAKG,QAAS,GAAK,GACzE,OAAOD,EAAOE,IAAI,EACpB,CA8CO,eAAeC,EACpBC,CAAsB,CACtBC,EAAc,CAAC,EAaf,GAAI,CAACD,EAAeF,IAAI,GACtB,CAD0B,KACnB,CAXPK,QAAS,EAAE,CACXC,SAAU,EAAE,CACZC,QAAS,EAAE,CACXC,KAAM,EAAE,CACRC,WAAY,EACZC,cAAe,GACfC,UAAW,KACXC,YAAa,CAAEC,OAAQ,EAAGC,SAAU,EAAGC,UAAW,CAAE,EAIjCC,MAAO,6BAA8B,EAG1D,IAAMC,EAAU,MAAMC,QAAQC,UAAU,CAAC,CAEvCxB,EAAIO,EAAgB,CAClB,MACA,CAAC,YAAY,EAAEC,EAAAA,CAAa,CAC5B,wCACA,aACD,EAEDR,EAAIO,EAAgB,CAAC,SAAU,iBAAiB,EAEhDP,EAAIO,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ts","../../../../../../../src/presentation/web/.next-internal/server/app/%28dashboard%29/%40drawer/repository/%5BrepositoryId%5D/page/actions.js%20%28server%20actions%20loader%29"],"sourcesContent":["'use server';\n\nimport { execFile } from 'node:child_process';\nimport { promisify } from 'node:util';\n\nconst execFileAsync = promisify(execFile);\n\nasync function git(cwd: string, args: string[]): Promise<string> {\n const { stdout } = await execFileAsync('git', args, { cwd, timeout: 5000 });\n return stdout.trim();\n}\n\nexport interface GitLogEntry {\n hash: string;\n shortHash: string;\n subject: string;\n author: string;\n relativeDate: string;\n branch?: string;\n}\n\nexport interface GitBranchInfo {\n name: string;\n isCurrent: boolean;\n lastCommitDate: string;\n}\n\nexport interface GitRemoteInfo {\n name: string;\n url: string;\n}\n\nexport interface GitWorkingTreeStatus {\n staged: number;\n modified: number;\n untracked: number;\n}\n\nexport interface GitDiffStats {\n filesChanged: number;\n insertions: number;\n deletions: number;\n}\n\nexport interface GitRepoInfo {\n commits: GitLogEntry[];\n branches: GitBranchInfo[];\n remotes: GitRemoteInfo[];\n tags: string[];\n stashCount: number;\n currentBranch: string;\n diffStats: GitDiffStats | null;\n workingTree: GitWorkingTreeStatus;\n error?: string;\n}\n\nexport async function getGitRepoInfo(\n repositoryPath: string,\n commitLimit = 8\n): Promise<GitRepoInfo> {\n const empty: GitRepoInfo = {\n commits: [],\n branches: [],\n remotes: [],\n tags: [],\n stashCount: 0,\n currentBranch: '',\n diffStats: null,\n workingTree: { staged: 0, modified: 0, untracked: 0 },\n };\n\n if (!repositoryPath.trim()) {\n return { ...empty, error: 'Repository path is required' };\n }\n\n const results = await Promise.allSettled([\n // 0: commits\n git(repositoryPath, [\n 'log',\n `--max-count=${commitLimit}`,\n '--format=%H%x00%h%x00%s%x00%an%x00%cr',\n '--no-color',\n ]),\n // 1: current branch\n git(repositoryPath, ['branch', '--show-current']),\n // 2: branches with dates\n git(repositoryPath, [\n 'branch',\n '--sort=-committerdate',\n '--format=%(HEAD)%(refname:short)%00%(committerdate:relative)',\n '--no-color',\n ]),\n // 3: remotes\n git(repositoryPath, ['remote', '-v']),\n // 4: tags (recent 5)\n git(repositoryPath, ['tag', '--sort=-creatordate', '-l', '--format=%(refname:short)']),\n // 5: stash count\n git(repositoryPath, ['stash', 'list']),\n // 6: working tree status\n git(repositoryPath, ['status', '--porcelain']),\n // 7: diff stats (uncommitted)\n git(repositoryPath, ['diff', '--shortstat']),\n ]);\n\n const val = (i: number) => (results[i].status === 'fulfilled' ? results[i].value : '');\n\n // Parse commits\n const commits: GitLogEntry[] = val(0)\n .split('\\n')\n .filter(Boolean)\n .map((line: string) => {\n const [hash, shortHash, subject, author, relativeDate] = line.split('\\0');\n return { hash, shortHash, subject, author, relativeDate };\n });\n\n const currentBranch = val(1);\n if (commits.length > 0 && currentBranch) {\n commits[0].branch = currentBranch;\n }\n\n // Parse branches\n const branches: GitBranchInfo[] = val(2)\n .split('\\n')\n .filter(Boolean)\n .slice(0, 10)\n .map((line: string) => {\n const isCurrent = line.startsWith('*');\n const clean = isCurrent ? line.slice(1) : line;\n const [name, lastCommitDate] = clean.split('\\0');\n return { name: name.trim(), isCurrent, lastCommitDate: lastCommitDate?.trim() ?? '' };\n });\n\n // Parse remotes (dedup fetch/push)\n const remoteMap = new Map<string, string>();\n val(3)\n .split('\\n')\n .filter(Boolean)\n .forEach((line: string) => {\n const match = line.match(/^(\\S+)\\s+(\\S+)\\s+\\(fetch\\)/);\n if (match) {\n // Strip credentials/tokens from URL before sending to client\n const sanitized = match[2].replace(/\\/\\/[^@]+@/, '//').replace(/x-access-token:[^@]+@/, '');\n remoteMap.set(match[1], sanitized);\n }\n });\n const remotes: GitRemoteInfo[] = Array.from(remoteMap, ([name, url]) => ({ name, url }));\n\n // Parse tags (top 5)\n const tags = val(4).split('\\n').filter(Boolean).slice(0, 5);\n\n // Stash count\n const stashCount = val(5).split('\\n').filter(Boolean).length;\n\n // Working tree status\n const statusLines = val(6).split('\\n').filter(Boolean);\n const workingTree: GitWorkingTreeStatus = { staged: 0, modified: 0, untracked: 0 };\n for (const line of statusLines) {\n const x = line[0];\n const y = line[1];\n if (x === '?' && y === '?') workingTree.untracked++;\n else if (x !== ' ' && x !== '?') workingTree.staged++;\n if (y !== ' ' && y !== '?') workingTree.modified++;\n }\n\n // Diff stats\n let diffStats: GitDiffStats | null = null;\n const diffLine = val(7);\n if (diffLine) {\n const files = diffLine.match(/(\\d+) file/);\n const ins = diffLine.match(/(\\d+) insertion/);\n const del = diffLine.match(/(\\d+) deletion/);\n diffStats = {\n filesChanged: files ? parseInt(files[1], 10) : 0,\n insertions: ins ? parseInt(ins[1], 10) : 0,\n deletions: del ? parseInt(del[1], 10) : 0,\n };\n }\n\n return { commits, branches, remotes, tags, stashCount, currentBranch, diffStats, workingTree };\n}\n\n// Keep backward compat\nexport async function getGitLog(\n repositoryPath: string,\n limit = 10\n): Promise<{ entries: GitLogEntry[]; error?: string }> {\n const info = await getGitRepoInfo(repositoryPath, limit);\n return { entries: info.commits, error: info.error };\n}\n","export {getAllAgentModels as '00b5162135ada648e72b38230e961529be25dd7bd8'} from 'ACTIONS_MODULE0'\nexport {updateAgentAndModel as '6024f64a42883240ffb5ef570aecd9c0dbe3fba237'} from 'ACTIONS_MODULE1'\nexport {pickFolder as '00928d754474788ad4c6fbbffcf4486c641fc91c3c'} from 'ACTIONS_MODULE2'\nexport {listGitHubRepositories as '401b1c4187ac45173c36e173144ba201fe13d45124'} from 'ACTIONS_MODULE3'\nexport {listGitHubOrganizations as '007f77d6c65b2ddc62646c97be4a2683c8426167b6'} from 'ACTIONS_MODULE4'\nexport {importGitHubRepository as '40d1d3605adec88ff2ff834f1d0b048d1128e7ed32'} from 'ACTIONS_MODULE5'\nexport {deployFeature as '403b83d2370ec6d9446fd573f8c6c439e91d1aeca2'} from 'ACTIONS_MODULE6'\nexport {deployRepository as '40a100fcddf4b7fb563c4be6d841b7aa69d8430016'} from 'ACTIONS_MODULE7'\nexport {stopDeployment as '402daf0bf817e3bbe4129f413ff47d052ad354069c'} from 'ACTIONS_MODULE8'\nexport {getDeploymentStatus as '408fc9ecc49078119e2600dc1a653a7767b846537c'} from 'ACTIONS_MODULE9'\nexport {openIde as '40e1d5fd96662092ef0a2bd4ea2e6d2697f3ab4c6a'} from 'ACTIONS_MODULE10'\nexport {openShell as '40eb06a9ce08102cf20c1cb5e3a0e0aeb9bd30770b'} from 'ACTIONS_MODULE11'\nexport {openFolder as '406aac6bb69cb2108ce05345c74e9fb7e72dffe3b0'} from 'ACTIONS_MODULE12'\nexport {syncRepository as '4031454b289e8be2efef97c9616a65533d8a72eb59'} from 'ACTIONS_MODULE13'\nexport {getDeploymentLogs as '40b6633f3e7026328d9dcc389e42240cb656b75e9f'} from 'ACTIONS_MODULE14'\nexport {isAgentSetupComplete as '006d6a821da9c521f994872f6661ea6406703cf09d'} from 'ACTIONS_MODULE15'\nexport {checkAgentAuth as '0060e775107df16b7b19d6e47a7415dd6aedad7619'} from 'ACTIONS_MODULE16'\nexport {checkToolStatus as '009df0ec5808a1a338bfdec3c05ddefa2e7406617a'} from 'ACTIONS_MODULE17'\nexport {getFeatureMetadata as '40306a89a2c907442e515b25e00379f8fd0b4403d3'} from 'ACTIONS_MODULE18'\nexport {archiveFeature as '409c6a3d317fe8f02d58823e588796a071e81be44f'} from 'ACTIONS_MODULE19'\nexport {deleteFeature as '785f41cd02af89c4b44f8d222d661a4a534b081923'} from 'ACTIONS_MODULE20'\nexport {resumeFeature as '402a5001445d8c354653c4a59447732df930eeeae9'} from 'ACTIONS_MODULE21'\nexport {startFeature as '40217ab39df4c598292e413589a39a03ff1567821b'} from 'ACTIONS_MODULE22'\nexport {stopFeature as '405314689dc2fdc3d3267320760cc2912860068706'} from 'ACTIONS_MODULE23'\nexport {unarchiveFeature as '4056493ad4e1f0b52d9ffb6cd926ce616630546083'} from 'ACTIONS_MODULE24'\nexport {addRepository as '40885ae2064e9aa9d12636caabc74c8e36c76939e2'} from 'ACTIONS_MODULE25'\nexport {deleteRepository as '40090d50d2dfeaaa5c021cfb7c005a37c84488a7f7'} from 'ACTIONS_MODULE26'\nexport {getGitRepoInfo as '60677743b16cef93db184f364ea5d4365577e4ff10'} from 'ACTIONS_MODULE27'\n"],"names":["execFileAsync","git","cwd","args","stdout","timeout","trim","getGitRepoInfo","repositoryPath","commitLimit","empty","commits","branches","remotes","tags","stashCount","currentBranch","diffStats","workingTree","staged","modified","untracked","error","results","Promise","allSettled","val","i","status","value","split","filter","Boolean","map","line","hash","shortHash","subject","author","relativeDate","length","branch","slice","isCurrent","startsWith","clean","name","lastCommitDate","remoteMap","Map","forEach","match","sanitized","replace","set","Array","from","url","statusLines","x","y","diffLine","files","ins","del","filesChanged","parseInt","insertions","deletions","getGitLog","limit","info","entries"],"mappings":"uDAEA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,oBAEA,IAAMA,EAAgB,CAAA,EAAA,EAAA,SAAA,AAAS,EAAC,EAAA,QAAQ,EAExC,eAAeC,EAAIC,CAAW,CAAEC,CAAc,EAC5C,GAAM,QAAEC,CAAM,CAAE,CAAG,MAAMJ,EAAc,MAAOG,EAAM,KAAED,EAAKG,QAAS,GAAK,GACzE,OAAOD,EAAOE,IAAI,EACpB,CA8CO,eAAeC,EACpBC,CAAsB,CACtBC,EAAc,CAAC,EAaf,GAAI,CAACD,EAAeF,IAAI,GACtB,CAD0B,KACnB,CAXPK,QAAS,EAAE,CACXC,SAAU,EAAE,CACZC,QAAS,EAAE,CACXC,KAAM,EAAE,CACRC,WAAY,EACZC,cAAe,GACfC,UAAW,KACXC,YAAa,CAAEC,OAAQ,EAAGC,SAAU,EAAGC,UAAW,CAAE,EAIjCC,MAAO,6BAA8B,EAG1D,IAAMC,EAAU,MAAMC,QAAQC,UAAU,CAAC,CAEvCxB,EAAIO,EAAgB,CAClB,MACA,CAAC,YAAY,EAAEC,EAAAA,CAAa,CAC5B,wCACA,aACD,EAEDR,EAAIO,EAAgB,CAAC,SAAU,iBAAiB,EAEhDP,EAAIO,EAAgB,CAClB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2211),c=a.i(74533),d=a.i(12057),e=a.i(50961);let f=(0,d.promisify)(c.execFile);async function g(a,b){let{stdout:c}=await f("git",b,{cwd:a,timeout:5e3});return c.trim()}async function h(a,b=8){if(!a.trim())return{commits:[],branches:[],remotes:[],tags:[],stashCount:0,currentBranch:"",diffStats:null,workingTree:{staged:0,modified:0,untracked:0},error:"Repository path is required"};let c=await Promise.allSettled([g(a,["log",`--max-count=${b}`,"--format=%H%x00%h%x00%s%x00%an%x00%cr","--no-color"]),g(a,["branch","--show-current"]),g(a,["branch","--sort=-committerdate","--format=%(HEAD)%(refname:short)%00%(committerdate:relative)","--no-color"]),g(a,["remote","-v"]),g(a,["tag","--sort=-creatordate","-l","--format=%(refname:short)"]),g(a,["stash","list"]),g(a,["status","--porcelain"]),g(a,["diff","--shortstat"])]),d=a=>"fulfilled"===c[a].status?c[a].value:"",e=d(0).split("\n").filter(Boolean).map(a=>{let[b,c,d,e,f]=a.split("\0");return{hash:b,shortHash:c,subject:d,author:e,relativeDate:f}}),f=d(1);e.length>0&&f&&(e[0].branch=f);let i=d(2).split("\n").filter(Boolean).slice(0,10).map(a=>{let b=a.startsWith("*"),[c,d]=(b?a.slice(1):a).split("\0");return{name:c.trim(),isCurrent:b,lastCommitDate:d?.trim()??""}}),j=new Map;d(3).split("\n").filter(Boolean).forEach(a=>{let b=a.match(/^(\S+)\s+(\S+)\s+\(fetch\)/);if(b){let a=b[2].replace(/\/\/[^@]+@/,"//").replace(/x-access-token:[^@]+@/,"");j.set(b[1],a)}});let k=Array.from(j,([a,b])=>({name:a,url:b})),l=d(4).split("\n").filter(Boolean).slice(0,5),m=d(5).split("\n").filter(Boolean).length,n=d(6).split("\n").filter(Boolean),o={staged:0,modified:0,untracked:0};for(let a of n){let b=a[0],c=a[1];"?"===b&&"?"===c?o.untracked++:" "!==b&&"?"!==b&&o.staged++," "!==c&&"?"!==c&&o.modified++}let p=null,q=d(7);if(q){let a=q.match(/(\d+) file/),b=q.match(/(\d+) insertion/),c=q.match(/(\d+) deletion/);p={filesChanged:a?parseInt(a[1],10):0,insertions:b?parseInt(b[1],10):0,deletions:c?parseInt(c[1],10):0}}return{commits:e,branches:i,remotes:k,tags:l,stashCount:m,currentBranch:f,diffStats:p,workingTree:o}}async function i(a,b=10){let c=await h(a,b);return{entries:c.commits,error:c.error}}(0,e.ensureServerEntryExports)([h,i]),(0,b.registerServerReference)(h,"
|
|
1
|
+
module.exports=[35556,a=>{"use strict";var b=a.i(2211),c=a.i(74533),d=a.i(12057),e=a.i(50961);let f=(0,d.promisify)(c.execFile);async function g(a,b){let{stdout:c}=await f("git",b,{cwd:a,timeout:5e3});return c.trim()}async function h(a,b=8){if(!a.trim())return{commits:[],branches:[],remotes:[],tags:[],stashCount:0,currentBranch:"",diffStats:null,workingTree:{staged:0,modified:0,untracked:0},error:"Repository path is required"};let c=await Promise.allSettled([g(a,["log",`--max-count=${b}`,"--format=%H%x00%h%x00%s%x00%an%x00%cr","--no-color"]),g(a,["branch","--show-current"]),g(a,["branch","--sort=-committerdate","--format=%(HEAD)%(refname:short)%00%(committerdate:relative)","--no-color"]),g(a,["remote","-v"]),g(a,["tag","--sort=-creatordate","-l","--format=%(refname:short)"]),g(a,["stash","list"]),g(a,["status","--porcelain"]),g(a,["diff","--shortstat"])]),d=a=>"fulfilled"===c[a].status?c[a].value:"",e=d(0).split("\n").filter(Boolean).map(a=>{let[b,c,d,e,f]=a.split("\0");return{hash:b,shortHash:c,subject:d,author:e,relativeDate:f}}),f=d(1);e.length>0&&f&&(e[0].branch=f);let i=d(2).split("\n").filter(Boolean).slice(0,10).map(a=>{let b=a.startsWith("*"),[c,d]=(b?a.slice(1):a).split("\0");return{name:c.trim(),isCurrent:b,lastCommitDate:d?.trim()??""}}),j=new Map;d(3).split("\n").filter(Boolean).forEach(a=>{let b=a.match(/^(\S+)\s+(\S+)\s+\(fetch\)/);if(b){let a=b[2].replace(/\/\/[^@]+@/,"//").replace(/x-access-token:[^@]+@/,"");j.set(b[1],a)}});let k=Array.from(j,([a,b])=>({name:a,url:b})),l=d(4).split("\n").filter(Boolean).slice(0,5),m=d(5).split("\n").filter(Boolean).length,n=d(6).split("\n").filter(Boolean),o={staged:0,modified:0,untracked:0};for(let a of n){let b=a[0],c=a[1];"?"===b&&"?"===c?o.untracked++:" "!==b&&"?"!==b&&o.staged++," "!==c&&"?"!==c&&o.modified++}let p=null,q=d(7);if(q){let a=q.match(/(\d+) file/),b=q.match(/(\d+) insertion/),c=q.match(/(\d+) deletion/);p={filesChanged:a?parseInt(a[1],10):0,insertions:b?parseInt(b[1],10):0,deletions:c?parseInt(c[1],10):0}}return{commits:e,branches:i,remotes:k,tags:l,stashCount:m,currentBranch:f,diffStats:p,workingTree:o}}async function i(a,b=10){let c=await h(a,b);return{entries:c.commits,error:c.error}}(0,e.ensureServerEntryExports)([h,i]),(0,b.registerServerReference)(h,"60677743b16cef93db184f364ea5d4365577e4ff10",null),(0,b.registerServerReference)(i,"605b636556deda767073e576fa60082cf49d414ba8",null),a.s(["getGitRepoInfo",0,h])},5357,a=>{"use strict";var b=a.i(23504),c=a.i(27900),d=a.i(12513),e=a.i(73101),f=a.i(54775),g=a.i(65324),h=a.i(33841),i=a.i(46646),j=a.i(68670),k=a.i(85321),l=a.i(84095),m=a.i(56799),n=a.i(80496),o=a.i(93225),p=a.i(94691),q=a.i(41872),r=a.i(9959),s=a.i(79124),t=a.i(29207),u=a.i(10528),v=a.i(50845),w=a.i(26604),x=a.i(54723),y=a.i(18942),z=a.i(42886),A=a.i(49560),B=a.i(39353),C=a.i(35556);a.s([],3748),a.i(3748),a.s(["0060e775107df16b7b19d6e47a7415dd6aedad7619",()=>r.checkAgentAuth,"006d6a821da9c521f994872f6661ea6406703cf09d",()=>q.isAgentSetupComplete,"007f77d6c65b2ddc62646c97be4a2683c8426167b6",()=>f.listGitHubOrganizations,"00928d754474788ad4c6fbbffcf4486c641fc91c3c",()=>d.pickFolder,"009df0ec5808a1a338bfdec3c05ddefa2e7406617a",()=>s.checkToolStatus,"00b5162135ada648e72b38230e961529be25dd7bd8",()=>b.getAllAgentModels,"40090d50d2dfeaaa5c021cfb7c005a37c84488a7f7",()=>B.deleteRepository,"401b1c4187ac45173c36e173144ba201fe13d45124",()=>e.listGitHubRepositories,"40217ab39df4c598292e413589a39a03ff1567821b",()=>x.startFeature,"402a5001445d8c354653c4a59447732df930eeeae9",()=>w.resumeFeature,"402daf0bf817e3bbe4129f413ff47d052ad354069c",()=>j.stopDeployment,"40306a89a2c907442e515b25e00379f8fd0b4403d3",()=>t.getFeatureMetadata,"4031454b289e8be2efef97c9616a65533d8a72eb59",()=>o.syncRepository,"403b83d2370ec6d9446fd573f8c6c439e91d1aeca2",()=>h.deployFeature,"405314689dc2fdc3d3267320760cc2912860068706",()=>y.stopFeature,"4056493ad4e1f0b52d9ffb6cd926ce616630546083",()=>z.unarchiveFeature,"406aac6bb69cb2108ce05345c74e9fb7e72dffe3b0",()=>n.openFolder,"40885ae2064e9aa9d12636caabc74c8e36c76939e2",()=>A.addRepository,"408fc9ecc49078119e2600dc1a653a7767b846537c",()=>k.getDeploymentStatus,"409c6a3d317fe8f02d58823e588796a071e81be44f",()=>u.archiveFeature,"40a100fcddf4b7fb563c4be6d841b7aa69d8430016",()=>i.deployRepository,"40b6633f3e7026328d9dcc389e42240cb656b75e9f",()=>p.getDeploymentLogs,"40d1d3605adec88ff2ff834f1d0b048d1128e7ed32",()=>g.importGitHubRepository,"40e1d5fd96662092ef0a2bd4ea2e6d2697f3ab4c6a",()=>l.openIde,"40eb06a9ce08102cf20c1cb5e3a0e0aeb9bd30770b",()=>m.openShell,"6024f64a42883240ffb5ef570aecd9c0dbe3fba237",()=>c.updateAgentAndModel,"60677743b16cef93db184f364ea5d4365577e4ff10",()=>C.getGitRepoInfo,"785f41cd02af89c4b44f8d222d661a4a534b081923",()=>v.deleteFeature],5357)}];
|
|
2
2
|
|
|
3
3
|
//# sourceMappingURL=src_presentation_web_0f~udu1._.js.map
|