@shepai/cli 1.174.0 → 1.175.0-pr530.44b3d3f

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (315) hide show
  1. package/apis/json-schema/Repository.yaml +6 -0
  2. package/dist/eslint.config.mjs +2 -0
  3. package/dist/packages/core/src/application/ports/output/repositories/repository-repository.interface.d.ts +3 -1
  4. package/dist/packages/core/src/application/ports/output/repositories/repository-repository.interface.d.ts.map +1 -1
  5. package/dist/packages/core/src/application/ports/output/services/git-pr-service.interface.d.ts +28 -0
  6. package/dist/packages/core/src/application/ports/output/services/git-pr-service.interface.d.ts.map +1 -1
  7. package/dist/packages/core/src/application/ports/output/services/git-pr-service.interface.js +2 -0
  8. package/dist/packages/core/src/application/ports/output/services/github-repository-service.interface.d.ts +47 -0
  9. package/dist/packages/core/src/application/ports/output/services/github-repository-service.interface.d.ts.map +1 -1
  10. package/dist/packages/core/src/application/ports/output/services/github-repository-service.interface.js +12 -0
  11. package/dist/packages/core/src/application/ports/output/services/i-browser-opener.d.ts +28 -0
  12. package/dist/packages/core/src/application/ports/output/services/i-browser-opener.d.ts.map +1 -0
  13. package/dist/packages/core/src/application/ports/output/services/i-browser-opener.js +13 -0
  14. package/dist/packages/core/src/application/ports/output/services/i-desktop-notifier.d.ts +29 -0
  15. package/dist/packages/core/src/application/ports/output/services/i-desktop-notifier.d.ts.map +1 -0
  16. package/dist/packages/core/src/application/ports/output/services/i-desktop-notifier.js +13 -0
  17. package/dist/packages/core/src/application/ports/output/services/index.d.ts +2 -0
  18. package/dist/packages/core/src/application/ports/output/services/index.d.ts.map +1 -1
  19. package/dist/packages/core/src/application/use-cases/features/create/create-feature-from-remote.use-case.d.ts +67 -0
  20. package/dist/packages/core/src/application/use-cases/features/create/create-feature-from-remote.use-case.d.ts.map +1 -0
  21. package/dist/packages/core/src/application/use-cases/features/create/create-feature-from-remote.use-case.js +128 -0
  22. package/dist/packages/core/src/application/use-cases/repositories/import-github-repository.use-case.d.ts +16 -5
  23. package/dist/packages/core/src/application/use-cases/repositories/import-github-repository.use-case.d.ts.map +1 -1
  24. package/dist/packages/core/src/application/use-cases/repositories/import-github-repository.use-case.js +76 -14
  25. package/dist/packages/core/src/application/use-cases/repositories/init-remote-repository.use-case.d.ts +30 -0
  26. package/dist/packages/core/src/application/use-cases/repositories/init-remote-repository.use-case.d.ts.map +1 -0
  27. package/dist/packages/core/src/application/use-cases/repositories/init-remote-repository.use-case.js +51 -0
  28. package/dist/packages/core/src/domain/generated/output.d.ts +8 -0
  29. package/dist/packages/core/src/domain/generated/output.d.ts.map +1 -1
  30. package/dist/packages/core/src/infrastructure/di/container.d.ts.map +1 -1
  31. package/dist/packages/core/src/infrastructure/di/container.js +15 -0
  32. package/dist/packages/core/src/infrastructure/persistence/sqlite/mappers/repository.mapper.d.ts +2 -0
  33. package/dist/packages/core/src/infrastructure/persistence/sqlite/mappers/repository.mapper.d.ts.map +1 -1
  34. package/dist/packages/core/src/infrastructure/persistence/sqlite/mappers/repository.mapper.js +4 -0
  35. package/dist/packages/core/src/infrastructure/persistence/sqlite/migrations/055-add-repository-fork-fields.d.ts +12 -0
  36. package/dist/packages/core/src/infrastructure/persistence/sqlite/migrations/055-add-repository-fork-fields.d.ts.map +1 -0
  37. package/dist/packages/core/src/infrastructure/persistence/sqlite/migrations/055-add-repository-fork-fields.js +26 -0
  38. package/dist/packages/core/src/infrastructure/repositories/sqlite-repository.repository.d.ts +2 -1
  39. package/dist/packages/core/src/infrastructure/repositories/sqlite-repository.repository.d.ts.map +1 -1
  40. package/dist/packages/core/src/infrastructure/repositories/sqlite-repository.repository.js +14 -0
  41. package/dist/packages/core/src/infrastructure/services/browser-opener.service.d.ts +2 -1
  42. package/dist/packages/core/src/infrastructure/services/browser-opener.service.d.ts.map +1 -1
  43. package/dist/packages/core/src/infrastructure/services/external/github-repository.service.d.ts +4 -1
  44. package/dist/packages/core/src/infrastructure/services/external/github-repository.service.d.ts.map +1 -1
  45. package/dist/packages/core/src/infrastructure/services/external/github-repository.service.js +55 -1
  46. package/dist/packages/core/src/infrastructure/services/git/git-pr.service.d.ts +15 -0
  47. package/dist/packages/core/src/infrastructure/services/git/git-pr.service.d.ts.map +1 -1
  48. package/dist/packages/core/src/infrastructure/services/git/git-pr.service.js +62 -0
  49. package/dist/packages/core/src/infrastructure/services/notifications/desktop-notifier.d.ts +2 -1
  50. package/dist/packages/core/src/infrastructure/services/notifications/desktop-notifier.d.ts.map +1 -1
  51. package/dist/src/presentation/cli/commands/daemon/start-daemon.d.ts +1 -1
  52. package/dist/src/presentation/cli/commands/daemon/start-daemon.js +2 -3
  53. package/dist/src/presentation/cli/commands/feat/new.command.d.ts.map +1 -1
  54. package/dist/src/presentation/cli/commands/feat/new.command.js +32 -6
  55. package/dist/src/presentation/cli/commands/repo/index.d.ts.map +1 -1
  56. package/dist/src/presentation/cli/commands/repo/index.js +3 -1
  57. package/dist/src/presentation/cli/commands/repo/init-remote.command.d.ts +15 -0
  58. package/dist/src/presentation/cli/commands/repo/init-remote.command.d.ts.map +1 -0
  59. package/dist/src/presentation/cli/commands/repo/init-remote.command.js +44 -0
  60. package/dist/src/presentation/cli/commands/ui.command.js +1 -2
  61. package/dist/src/presentation/web/app/actions/create-feature-from-remote.d.ts +31 -0
  62. package/dist/src/presentation/web/app/actions/create-feature-from-remote.d.ts.map +1 -0
  63. package/dist/src/presentation/web/app/actions/create-feature-from-remote.js +69 -0
  64. package/dist/src/presentation/web/app/actions/import-github-repository.d.ts +1 -0
  65. package/dist/src/presentation/web/app/actions/import-github-repository.d.ts.map +1 -1
  66. package/dist/src/presentation/web/app/actions/import-github-repository.js +1 -1
  67. package/dist/src/presentation/web/components/common/feature-create-drawer/feature-create-drawer.d.ts +2 -0
  68. package/dist/src/presentation/web/components/common/feature-create-drawer/feature-create-drawer.d.ts.map +1 -1
  69. package/dist/src/presentation/web/components/common/feature-create-drawer/feature-create-drawer.js +1 -1
  70. package/dist/src/presentation/web/components/common/feature-create-drawer/repository-combobox.stories.d.ts +2 -0
  71. package/dist/src/presentation/web/components/common/feature-create-drawer/repository-combobox.stories.d.ts.map +1 -1
  72. package/dist/src/presentation/web/components/common/feature-create-drawer/repository-combobox.stories.js +22 -0
  73. package/dist/src/presentation/web/lib/feature-flags.js +1 -1
  74. package/dist/translations/ar/cli.json +12 -0
  75. package/dist/translations/de/cli.json +12 -0
  76. package/dist/translations/en/cli.json +12 -0
  77. package/dist/translations/es/cli.json +12 -0
  78. package/dist/translations/fr/cli.json +12 -0
  79. package/dist/translations/he/cli.json +12 -0
  80. package/dist/translations/pt/cli.json +12 -0
  81. package/dist/translations/ru/cli.json +12 -0
  82. package/dist/tsconfig.build.tsbuildinfo +1 -1
  83. package/package.json +10 -2
  84. package/web/.next/BUILD_ID +1 -1
  85. package/web/.next/build-manifest.json +2 -2
  86. package/web/.next/fallback-build-manifest.json +2 -2
  87. package/web/.next/prerender-manifest.json +3 -3
  88. package/web/.next/required-server-files.js +3 -3
  89. package/web/.next/required-server-files.json +3 -3
  90. package/web/.next/server/app/(dashboard)/@drawer/adopt/page/server-reference-manifest.json +29 -29
  91. package/web/.next/server/app/(dashboard)/@drawer/adopt/page.js +2 -1
  92. package/web/.next/server/app/(dashboard)/@drawer/adopt/page.js.nft.json +1 -1
  93. package/web/.next/server/app/(dashboard)/@drawer/adopt/page_client-reference-manifest.js +1 -1
  94. package/web/.next/server/app/(dashboard)/@drawer/chat/page/server-reference-manifest.json +27 -27
  95. package/web/.next/server/app/(dashboard)/@drawer/chat/page.js +2 -1
  96. package/web/.next/server/app/(dashboard)/@drawer/chat/page.js.nft.json +1 -1
  97. package/web/.next/server/app/(dashboard)/@drawer/chat/page_client-reference-manifest.js +1 -1
  98. package/web/.next/server/app/(dashboard)/@drawer/create/page/server-reference-manifest.json +30 -30
  99. package/web/.next/server/app/(dashboard)/@drawer/create/page.js +2 -1
  100. package/web/.next/server/app/(dashboard)/@drawer/create/page.js.nft.json +1 -1
  101. package/web/.next/server/app/(dashboard)/@drawer/create/page_client-reference-manifest.js +1 -1
  102. package/web/.next/server/app/(dashboard)/@drawer/feature/[featureId]/[tab]/page/server-reference-manifest.json +38 -38
  103. package/web/.next/server/app/(dashboard)/@drawer/feature/[featureId]/[tab]/page.js +2 -1
  104. package/web/.next/server/app/(dashboard)/@drawer/feature/[featureId]/[tab]/page.js.nft.json +1 -1
  105. package/web/.next/server/app/(dashboard)/@drawer/feature/[featureId]/[tab]/page_client-reference-manifest.js +1 -1
  106. package/web/.next/server/app/(dashboard)/@drawer/feature/[featureId]/page/server-reference-manifest.json +38 -38
  107. package/web/.next/server/app/(dashboard)/@drawer/feature/[featureId]/page.js +2 -1
  108. package/web/.next/server/app/(dashboard)/@drawer/feature/[featureId]/page.js.nft.json +1 -1
  109. package/web/.next/server/app/(dashboard)/@drawer/feature/[featureId]/page_client-reference-manifest.js +1 -1
  110. package/web/.next/server/app/(dashboard)/@drawer/repository/[repositoryId]/[tab]/page/server-reference-manifest.json +28 -28
  111. package/web/.next/server/app/(dashboard)/@drawer/repository/[repositoryId]/[tab]/page.js +2 -1
  112. package/web/.next/server/app/(dashboard)/@drawer/repository/[repositoryId]/[tab]/page.js.nft.json +1 -1
  113. package/web/.next/server/app/(dashboard)/@drawer/repository/[repositoryId]/[tab]/page_client-reference-manifest.js +1 -1
  114. package/web/.next/server/app/(dashboard)/@drawer/repository/[repositoryId]/page/server-reference-manifest.json +28 -28
  115. package/web/.next/server/app/(dashboard)/@drawer/repository/[repositoryId]/page.js +2 -1
  116. package/web/.next/server/app/(dashboard)/@drawer/repository/[repositoryId]/page.js.nft.json +1 -1
  117. package/web/.next/server/app/(dashboard)/@drawer/repository/[repositoryId]/page_client-reference-manifest.js +1 -1
  118. package/web/.next/server/app/(dashboard)/chat/page/server-reference-manifest.json +27 -27
  119. package/web/.next/server/app/(dashboard)/chat/page.js +2 -1
  120. package/web/.next/server/app/(dashboard)/chat/page.js.nft.json +1 -1
  121. package/web/.next/server/app/(dashboard)/chat/page_client-reference-manifest.js +1 -1
  122. package/web/.next/server/app/(dashboard)/create/page/server-reference-manifest.json +30 -30
  123. package/web/.next/server/app/(dashboard)/create/page.js +2 -1
  124. package/web/.next/server/app/(dashboard)/create/page.js.nft.json +1 -1
  125. package/web/.next/server/app/(dashboard)/create/page_client-reference-manifest.js +1 -1
  126. package/web/.next/server/app/(dashboard)/feature/[featureId]/[tab]/page/server-reference-manifest.json +38 -38
  127. package/web/.next/server/app/(dashboard)/feature/[featureId]/[tab]/page.js +2 -1
  128. package/web/.next/server/app/(dashboard)/feature/[featureId]/[tab]/page.js.nft.json +1 -1
  129. package/web/.next/server/app/(dashboard)/feature/[featureId]/[tab]/page_client-reference-manifest.js +1 -1
  130. package/web/.next/server/app/(dashboard)/feature/[featureId]/page/server-reference-manifest.json +38 -38
  131. package/web/.next/server/app/(dashboard)/feature/[featureId]/page.js +2 -1
  132. package/web/.next/server/app/(dashboard)/feature/[featureId]/page.js.nft.json +1 -1
  133. package/web/.next/server/app/(dashboard)/feature/[featureId]/page_client-reference-manifest.js +1 -1
  134. package/web/.next/server/app/(dashboard)/page/server-reference-manifest.json +27 -27
  135. package/web/.next/server/app/(dashboard)/page.js +2 -1
  136. package/web/.next/server/app/(dashboard)/page.js.nft.json +1 -1
  137. package/web/.next/server/app/(dashboard)/page_client-reference-manifest.js +1 -1
  138. package/web/.next/server/app/(dashboard)/repository/[repositoryId]/[tab]/page/server-reference-manifest.json +28 -28
  139. package/web/.next/server/app/(dashboard)/repository/[repositoryId]/[tab]/page.js +2 -1
  140. package/web/.next/server/app/(dashboard)/repository/[repositoryId]/[tab]/page.js.nft.json +1 -1
  141. package/web/.next/server/app/(dashboard)/repository/[repositoryId]/[tab]/page_client-reference-manifest.js +1 -1
  142. package/web/.next/server/app/(dashboard)/repository/[repositoryId]/page/server-reference-manifest.json +28 -28
  143. package/web/.next/server/app/(dashboard)/repository/[repositoryId]/page.js +2 -1
  144. package/web/.next/server/app/(dashboard)/repository/[repositoryId]/page.js.nft.json +1 -1
  145. package/web/.next/server/app/(dashboard)/repository/[repositoryId]/page_client-reference-manifest.js +1 -1
  146. package/web/.next/server/app/_global-error.html +2 -2
  147. package/web/.next/server/app/_global-error.rsc +1 -1
  148. package/web/.next/server/app/_global-error.segments/__PAGE__.segment.rsc +1 -1
  149. package/web/.next/server/app/_global-error.segments/_full.segment.rsc +1 -1
  150. package/web/.next/server/app/_global-error.segments/_head.segment.rsc +1 -1
  151. package/web/.next/server/app/_global-error.segments/_index.segment.rsc +1 -1
  152. package/web/.next/server/app/_global-error.segments/_tree.segment.rsc +1 -1
  153. package/web/.next/server/app/_not-found/page/server-reference-manifest.json +6 -6
  154. package/web/.next/server/app/_not-found/page.js.nft.json +1 -1
  155. package/web/.next/server/app/_not-found/page_client-reference-manifest.js +1 -1
  156. package/web/.next/server/app/api/attachments/preview/route.js.nft.json +1 -1
  157. package/web/.next/server/app/api/evidence/route.js.nft.json +1 -1
  158. package/web/.next/server/app/api/graph-data/route.js.nft.json +1 -1
  159. package/web/.next/server/app/api/interactive/chat/[featureId]/messages/route.js.nft.json +1 -1
  160. package/web/.next/server/app/features/page/server-reference-manifest.json +6 -6
  161. package/web/.next/server/app/features/page.js.nft.json +1 -1
  162. package/web/.next/server/app/features/page_client-reference-manifest.js +1 -1
  163. package/web/.next/server/app/settings/page/server-reference-manifest.json +9 -9
  164. package/web/.next/server/app/settings/page.js.nft.json +1 -1
  165. package/web/.next/server/app/settings/page_client-reference-manifest.js +1 -1
  166. package/web/.next/server/app/skills/page/server-reference-manifest.json +13 -13
  167. package/web/.next/server/app/skills/page.js +2 -1
  168. package/web/.next/server/app/skills/page.js.nft.json +1 -1
  169. package/web/.next/server/app/skills/page_client-reference-manifest.js +1 -1
  170. package/web/.next/server/app/tools/page/server-reference-manifest.json +11 -11
  171. package/web/.next/server/app/tools/page.js +2 -1
  172. package/web/.next/server/app/tools/page.js.nft.json +1 -1
  173. package/web/.next/server/app/tools/page_client-reference-manifest.js +1 -1
  174. package/web/.next/server/app/version/page/server-reference-manifest.json +6 -6
  175. package/web/.next/server/app/version/page.js.nft.json +1 -1
  176. package/web/.next/server/app/version/page_client-reference-manifest.js +1 -1
  177. package/web/.next/server/chunks/[root-of-the-server]__a402b567._.js +1 -1
  178. package/web/.next/server/chunks/[root-of-the-server]__c78383b1._.js.map +1 -1
  179. package/web/.next/server/chunks/[root-of-the-server]__cd67a84c._.js.map +1 -1
  180. package/web/.next/server/chunks/ssr/744ca_web__next-internal_server_app_(dashboard)_@drawer_adopt_page_actions_ad0071c9.js +3 -0
  181. package/web/.next/server/chunks/ssr/744ca_web__next-internal_server_app_(dashboard)_@drawer_adopt_page_actions_ad0071c9.js.map +1 -0
  182. package/web/.next/server/chunks/ssr/744ca_web__next-internal_server_app_(dashboard)_@drawer_chat_page_actions_90d98b2b.js +3 -0
  183. package/web/.next/server/chunks/ssr/744ca_web__next-internal_server_app_(dashboard)_@drawer_chat_page_actions_90d98b2b.js.map +1 -0
  184. package/web/.next/server/chunks/ssr/744ca_web__next-internal_server_app_(dashboard)_chat_page_actions_d3828105.js +3 -0
  185. package/web/.next/server/chunks/ssr/744ca_web__next-internal_server_app_(dashboard)_chat_page_actions_d3828105.js.map +1 -0
  186. package/web/.next/server/chunks/ssr/744ca_web_components_common_control-center-drawer_create-drawer-client_tsx_5e26fc0a._.js +1 -1
  187. package/web/.next/server/chunks/ssr/744ca_web_components_common_control-center-drawer_create-drawer-client_tsx_5e26fc0a._.js.map +1 -1
  188. package/web/.next/server/chunks/ssr/744ca_web_components_common_control-center-drawer_feature-drawer-client_tsx_e9755fc8._.js +2 -2
  189. package/web/.next/server/chunks/ssr/744ca_web_components_common_control-center-drawer_feature-drawer-client_tsx_e9755fc8._.js.map +1 -1
  190. package/web/.next/server/chunks/ssr/[root-of-the-server]__1cd4327c._.js +1 -1
  191. package/web/.next/server/chunks/ssr/[root-of-the-server]__1cd4327c._.js.map +1 -1
  192. package/web/.next/server/chunks/ssr/[root-of-the-server]__1f389e5d._.js +1 -1
  193. package/web/.next/server/chunks/ssr/[root-of-the-server]__1f389e5d._.js.map +1 -1
  194. package/web/.next/server/chunks/ssr/[root-of-the-server]__357d99f9._.js +1 -1
  195. package/web/.next/server/chunks/ssr/[root-of-the-server]__51ec77a8._.js +3 -0
  196. package/web/.next/server/chunks/ssr/[root-of-the-server]__51ec77a8._.js.map +1 -0
  197. package/web/.next/server/chunks/ssr/{[root-of-the-server]__b020c17d._.js → [root-of-the-server]__540c615f._.js} +3 -3
  198. package/web/.next/server/chunks/ssr/[root-of-the-server]__540c615f._.js.map +1 -0
  199. package/web/.next/server/chunks/ssr/[root-of-the-server]__66047a1b._.js +3 -0
  200. package/web/.next/server/chunks/ssr/[root-of-the-server]__66047a1b._.js.map +1 -0
  201. package/web/.next/server/chunks/ssr/[root-of-the-server]__6c7d3936._.js +1 -1
  202. package/web/.next/server/chunks/ssr/[root-of-the-server]__6c7d3936._.js.map +1 -1
  203. package/web/.next/server/chunks/ssr/[root-of-the-server]__a932cd3a._.js +3 -0
  204. package/web/.next/server/chunks/ssr/[root-of-the-server]__a932cd3a._.js.map +1 -0
  205. package/web/.next/server/chunks/ssr/[root-of-the-server]__aa72e794._.js +3 -0
  206. package/web/.next/server/chunks/ssr/[root-of-the-server]__aa72e794._.js.map +1 -0
  207. package/web/.next/server/chunks/ssr/[root-of-the-server]__b7b96453._.js +1 -1
  208. package/web/.next/server/chunks/ssr/[root-of-the-server]__b7b96453._.js.map +1 -1
  209. package/web/.next/server/chunks/ssr/_05c23ad9._.js +1 -1
  210. package/web/.next/server/chunks/ssr/_05c23ad9._.js.map +1 -1
  211. package/web/.next/server/chunks/ssr/_16eb4fec._.js +1 -1
  212. package/web/.next/server/chunks/ssr/_16eb4fec._.js.map +1 -1
  213. package/web/.next/server/chunks/ssr/_295fffde._.js.map +1 -1
  214. package/web/.next/server/chunks/ssr/_45496654._.js +1 -1
  215. package/web/.next/server/chunks/ssr/_45496654._.js.map +1 -1
  216. package/web/.next/server/chunks/ssr/_4cbb7f95._.js +1 -1
  217. package/web/.next/server/chunks/ssr/_4cbb7f95._.js.map +1 -1
  218. package/web/.next/server/chunks/ssr/{_fd595af2._.js → _4f2b44c0._.js} +2 -2
  219. package/web/.next/server/chunks/ssr/{_fd595af2._.js.map → _4f2b44c0._.js.map} +1 -1
  220. package/web/.next/server/chunks/ssr/_56b9d60f._.js +1 -1
  221. package/web/.next/server/chunks/ssr/_56b9d60f._.js.map +1 -1
  222. package/web/.next/server/chunks/ssr/_6abfa39e._.js +1 -1
  223. package/web/.next/server/chunks/ssr/_6abfa39e._.js.map +1 -1
  224. package/web/.next/server/chunks/ssr/{_7953be4d._.js → _d3833dd3._.js} +2 -2
  225. package/web/.next/server/chunks/ssr/{_7953be4d._.js.map → _d3833dd3._.js.map} +1 -1
  226. package/web/.next/server/chunks/ssr/{_3a71f39b._.js → _f2f1bb99._.js} +2 -2
  227. package/web/.next/server/chunks/ssr/{_3a71f39b._.js.map → _f2f1bb99._.js.map} +1 -1
  228. package/web/.next/server/chunks/ssr/_f8c55130._.js +4 -0
  229. package/web/.next/server/chunks/ssr/_f8c55130._.js.map +1 -0
  230. package/web/.next/server/chunks/ssr/b1a17_presentation_web_components_features_settings_settings-page-client_tsx_6ed9d5f8._.js +1 -1
  231. package/web/.next/server/chunks/ssr/b1a17_presentation_web_components_features_settings_settings-page-client_tsx_6ed9d5f8._.js.map +1 -1
  232. package/web/.next/server/chunks/ssr/f3a1f_components_common_control-center-drawer_repository-drawer-client_tsx_39a00c03._.js +1 -1
  233. package/web/.next/server/chunks/ssr/f3a1f_components_common_control-center-drawer_repository-drawer-client_tsx_39a00c03._.js.map +1 -1
  234. package/web/.next/server/chunks/ssr/src_presentation_web_17d39233._.js +3 -0
  235. package/web/.next/server/chunks/ssr/src_presentation_web_17d39233._.js.map +1 -0
  236. package/web/.next/server/chunks/ssr/src_presentation_web_54b02639._.js +5 -0
  237. package/web/.next/server/chunks/ssr/src_presentation_web_54b02639._.js.map +1 -0
  238. package/web/.next/server/chunks/ssr/src_presentation_web_7b7b9e3b._.js +5 -0
  239. package/web/.next/server/chunks/ssr/src_presentation_web_7b7b9e3b._.js.map +1 -0
  240. package/web/.next/server/chunks/ssr/src_presentation_web_807cba76._.js +3 -0
  241. package/web/.next/server/chunks/ssr/src_presentation_web_807cba76._.js.map +1 -0
  242. package/web/.next/server/chunks/ssr/src_presentation_web__next-internal_server_app_(dashboard)_page_actions_90b5e66e.js +3 -0
  243. package/web/.next/server/chunks/ssr/src_presentation_web__next-internal_server_app_(dashboard)_page_actions_90b5e66e.js.map +1 -0
  244. package/web/.next/server/chunks/ssr/src_presentation_web__next-internal_server_app_skills_page_actions_4ce30db7.js +3 -0
  245. package/web/.next/server/chunks/ssr/src_presentation_web__next-internal_server_app_skills_page_actions_4ce30db7.js.map +1 -0
  246. package/web/.next/server/chunks/ssr/src_presentation_web__next-internal_server_app_tools_page_actions_e4032193.js +3 -0
  247. package/web/.next/server/chunks/ssr/src_presentation_web__next-internal_server_app_tools_page_actions_e4032193.js.map +1 -0
  248. package/web/.next/server/chunks/ssr/src_presentation_web_app_actions_open-ide_ts_baaca5d5._.js +1 -1
  249. package/web/.next/server/chunks/ssr/src_presentation_web_components_895e5bfa._.js +1 -1
  250. package/web/.next/server/chunks/ssr/src_presentation_web_components_895e5bfa._.js.map +1 -1
  251. package/web/.next/server/chunks/ssr/src_presentation_web_components_features_control-center_7ac3562e._.js +1 -1
  252. package/web/.next/server/chunks/ssr/src_presentation_web_components_features_control-center_7ac3562e._.js.map +1 -1
  253. package/web/.next/server/chunks/ssr/src_presentation_web_components_features_skills_8a174cac._.js +1 -1
  254. package/web/.next/server/chunks/ssr/src_presentation_web_components_features_skills_8a174cac._.js.map +1 -1
  255. package/web/.next/server/chunks/ssr/src_presentation_web_e1cd1869._.js +3 -0
  256. package/web/.next/server/chunks/ssr/src_presentation_web_e1cd1869._.js.map +1 -0
  257. package/web/.next/server/chunks/ssr/src_presentation_web_e3a30e30._.js +3 -0
  258. package/web/.next/server/chunks/ssr/src_presentation_web_e3a30e30._.js.map +1 -0
  259. package/web/.next/server/pages/500.html +2 -2
  260. package/web/.next/server/server-reference-manifest.js +1 -1
  261. package/web/.next/server/server-reference-manifest.json +50 -50
  262. package/web/.next/static/chunks/{393b27ab5de6c454.js → 1500ae4caae7ab8a.js} +1 -1
  263. package/web/.next/static/chunks/{534194b584a151ed.js → 2670ec1d2e2e55d2.js} +1 -1
  264. package/web/.next/static/chunks/2ceebcc839ee0d4b.js +1 -0
  265. package/web/.next/static/chunks/{6bc240cd4ae43267.js → 3fb211d4ea30acb5.js} +1 -1
  266. package/web/.next/static/chunks/{ad47bc6ddec7508e.js → 6c7f0a73c0873fab.js} +1 -1
  267. package/web/.next/static/chunks/9a829b853e2e89f7.js +1 -0
  268. package/web/.next/static/chunks/9de7f8e1dd758f7a.js +1 -0
  269. package/web/.next/static/chunks/{a060ad1bb509687f.js → 9ebe6617c1687993.js} +1 -1
  270. package/web/.next/static/chunks/{d9c9db1823b4dffd.js → a0f3ae7198e8fb87.js} +1 -1
  271. package/web/.next/static/chunks/a20f2d6f76f469b7.css +1 -0
  272. package/web/.next/static/chunks/{6dc0a23d333274ae.js → a88aa07f3cbb7567.js} +3 -3
  273. package/web/.next/static/chunks/{a2a03ecb10000974.js → badc97045a6c414d.js} +1 -1
  274. package/web/.next/static/chunks/{e30aa6d2cf824fa1.js → bbcb1154726b6b99.js} +1 -1
  275. package/web/.next/static/chunks/{0baf5a2e56d191cf.js → d8e739ad177860ed.js} +1 -1
  276. package/web/.next/static/chunks/{c164b157638b2a8b.js → e8b36e95e26924d5.js} +1 -1
  277. package/web/.next/static/chunks/ec7dc9f7942577c7.js +3 -0
  278. package/web/.next/server/chunks/ssr/[root-of-the-server]__4fb81977._.js +0 -4
  279. package/web/.next/server/chunks/ssr/[root-of-the-server]__4fb81977._.js.map +0 -1
  280. package/web/.next/server/chunks/ssr/[root-of-the-server]__7dcd0917._.js +0 -4
  281. package/web/.next/server/chunks/ssr/[root-of-the-server]__7dcd0917._.js.map +0 -1
  282. package/web/.next/server/chunks/ssr/[root-of-the-server]__92ffd5ee._.js +0 -4
  283. package/web/.next/server/chunks/ssr/[root-of-the-server]__92ffd5ee._.js.map +0 -1
  284. package/web/.next/server/chunks/ssr/[root-of-the-server]__b020c17d._.js.map +0 -1
  285. package/web/.next/server/chunks/ssr/[root-of-the-server]__ba7f5873._.js +0 -4
  286. package/web/.next/server/chunks/ssr/[root-of-the-server]__ba7f5873._.js.map +0 -1
  287. package/web/.next/server/chunks/ssr/[root-of-the-server]__c5e09f6f._.js +0 -4
  288. package/web/.next/server/chunks/ssr/[root-of-the-server]__c5e09f6f._.js.map +0 -1
  289. package/web/.next/server/chunks/ssr/_02e01240._.js +0 -4
  290. package/web/.next/server/chunks/ssr/_02e01240._.js.map +0 -1
  291. package/web/.next/server/chunks/ssr/_18886033._.js +0 -4
  292. package/web/.next/server/chunks/ssr/_18886033._.js.map +0 -1
  293. package/web/.next/server/chunks/ssr/_22e00a14._.js +0 -4
  294. package/web/.next/server/chunks/ssr/_22e00a14._.js.map +0 -1
  295. package/web/.next/server/chunks/ssr/_a5a5901d._.js +0 -4
  296. package/web/.next/server/chunks/ssr/_a5a5901d._.js.map +0 -1
  297. package/web/.next/server/chunks/ssr/_ad09f271._.js +0 -4
  298. package/web/.next/server/chunks/ssr/_ad09f271._.js.map +0 -1
  299. package/web/.next/server/chunks/ssr/_c3f595c6._.js +0 -4
  300. package/web/.next/server/chunks/ssr/_c3f595c6._.js.map +0 -1
  301. package/web/.next/server/chunks/ssr/_ea9e1556._.js +0 -4
  302. package/web/.next/server/chunks/ssr/_ea9e1556._.js.map +0 -1
  303. package/web/.next/server/chunks/ssr/_f1ba9be6._.js +0 -6
  304. package/web/.next/server/chunks/ssr/_f1ba9be6._.js.map +0 -1
  305. package/web/.next/server/chunks/ssr/_f33cd07e._.js +0 -6
  306. package/web/.next/server/chunks/ssr/_f33cd07e._.js.map +0 -1
  307. package/web/.next/server/chunks/ssr/_f8b45233._.js +0 -4
  308. package/web/.next/server/chunks/ssr/_f8b45233._.js.map +0 -1
  309. package/web/.next/static/chunks/32c46154c31c58fc.js +0 -1
  310. package/web/.next/static/chunks/5a2e1c8699897c26.js +0 -3
  311. package/web/.next/static/chunks/84b480808bd74fa9.css +0 -1
  312. package/web/.next/static/chunks/f5abbc495d496f5b.js +0 -1
  313. /package/web/.next/static/{nLYXtW5TIrvQiMl1yyD4O → O8LQNkKaww1r4JKbHgBGo}/_buildManifest.js +0 -0
  314. /package/web/.next/static/{nLYXtW5TIrvQiMl1yyD4O → O8LQNkKaww1r4JKbHgBGo}/_clientMiddlewareManifest.json +0 -0
  315. /package/web/.next/static/{nLYXtW5TIrvQiMl1yyD4O → O8LQNkKaww1r4JKbHgBGo}/_ssgManifest.js +0 -0
@@ -11,6 +11,12 @@ properties:
11
11
  remoteUrl:
12
12
  type: string
13
13
  description: "Remote GitHub URL this repository was cloned from (normalized: lowercase, no .git suffix)"
14
+ isFork:
15
+ type: boolean
16
+ description: Whether this repository was auto-forked by shep because the user lacked push access
17
+ upstreamUrl:
18
+ type: string
19
+ description: "Original upstream URL when isFork is true (normalized: lowercase, no .git suffix)"
14
20
  required:
15
21
  - name
16
22
  - path
@@ -27,6 +27,8 @@ export default tseslint.config(
27
27
  ignores: [
28
28
  // Build outputs
29
29
  'dist/**',
30
+ 'packages/*/dist/**',
31
+ 'packages/*/release/**',
30
32
  'build/**',
31
33
  'web/**',
32
34
  '**/.next/**',
@@ -12,12 +12,14 @@ export interface IRepositoryRepository {
12
12
  findByPathIncludingDeleted(path: string): Promise<Repository | null>;
13
13
  /** Find a non-deleted repository by its remote URL (normalized: lowercase, no .git suffix). */
14
14
  findByRemoteUrl(url: string): Promise<Repository | null>;
15
+ /** Find a non-deleted repository by its upstream URL (for fork deduplication). */
16
+ findByUpstreamUrl(url: string): Promise<Repository | null>;
15
17
  list(): Promise<Repository[]>;
16
18
  remove(id: string): Promise<void>;
17
19
  softDelete(id: string): Promise<void>;
18
20
  /** Restore a soft-deleted repository by clearing deletedAt. */
19
21
  restore(id: string): Promise<void>;
20
22
  /** Update specific fields on an existing repository. */
21
- update(id: string, fields: Partial<Pick<Repository, 'name' | 'path' | 'remoteUrl'>>): Promise<Repository>;
23
+ update(id: string, fields: Partial<Pick<Repository, 'name' | 'path' | 'remoteUrl' | 'isFork' | 'upstreamUrl'>>): Promise<Repository>;
22
24
  }
23
25
  //# sourceMappingURL=repository-repository.interface.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"repository-repository.interface.d.ts","sourceRoot":"","sources":["../../../../../../../../packages/core/src/application/ports/output/repositories/repository-repository.interface.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,wCAAwC,CAAC;AAEzE,MAAM,WAAW,qBAAqB;IACpC,MAAM,CAAC,UAAU,EAAE,UAAU,GAAG,OAAO,CAAC,UAAU,CAAC,CAAC;IACpD,QAAQ,CAAC,EAAE,EAAE,MAAM,GAAG,OAAO,CAAC,UAAU,GAAG,IAAI,CAAC,CAAC;IACjD,UAAU,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAAC,UAAU,GAAG,IAAI,CAAC,CAAC;IACrD,uEAAuE;IACvE,0BAA0B,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAAC,UAAU,GAAG,IAAI,CAAC,CAAC;IACrE,+FAA+F;IAC/F,eAAe,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,UAAU,GAAG,IAAI,CAAC,CAAC;IACzD,IAAI,IAAI,OAAO,CAAC,UAAU,EAAE,CAAC,CAAC;IAC9B,MAAM,CAAC,EAAE,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAClC,UAAU,CAAC,EAAE,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IACtC,+DAA+D;IAC/D,OAAO,CAAC,EAAE,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IACnC,wDAAwD;IACxD,MAAM,CACJ,EAAE,EAAE,MAAM,EACV,MAAM,EAAE,OAAO,CAAC,IAAI,CAAC,UAAU,EAAE,MAAM,GAAG,MAAM,GAAG,WAAW,CAAC,CAAC,GAC/D,OAAO,CAAC,UAAU,CAAC,CAAC;CACxB"}
1
+ {"version":3,"file":"repository-repository.interface.d.ts","sourceRoot":"","sources":["../../../../../../../../packages/core/src/application/ports/output/repositories/repository-repository.interface.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,wCAAwC,CAAC;AAEzE,MAAM,WAAW,qBAAqB;IACpC,MAAM,CAAC,UAAU,EAAE,UAAU,GAAG,OAAO,CAAC,UAAU,CAAC,CAAC;IACpD,QAAQ,CAAC,EAAE,EAAE,MAAM,GAAG,OAAO,CAAC,UAAU,GAAG,IAAI,CAAC,CAAC;IACjD,UAAU,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAAC,UAAU,GAAG,IAAI,CAAC,CAAC;IACrD,uEAAuE;IACvE,0BAA0B,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAAC,UAAU,GAAG,IAAI,CAAC,CAAC;IACrE,+FAA+F;IAC/F,eAAe,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,UAAU,GAAG,IAAI,CAAC,CAAC;IACzD,kFAAkF;IAClF,iBAAiB,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,UAAU,GAAG,IAAI,CAAC,CAAC;IAC3D,IAAI,IAAI,OAAO,CAAC,UAAU,EAAE,CAAC,CAAC;IAC9B,MAAM,CAAC,EAAE,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAClC,UAAU,CAAC,EAAE,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IACtC,+DAA+D;IAC/D,OAAO,CAAC,EAAE,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IACnC,wDAAwD;IACxD,MAAM,CACJ,EAAE,EAAE,MAAM,EACV,MAAM,EAAE,OAAO,CAAC,IAAI,CAAC,UAAU,EAAE,MAAM,GAAG,MAAM,GAAG,WAAW,GAAG,QAAQ,GAAG,aAAa,CAAC,CAAC,GAC1F,OAAO,CAAC,UAAU,CAAC,CAAC;CACxB"}
@@ -18,6 +18,8 @@ export declare enum GitPrErrorCode {
18
18
  MERGE_FAILED = "MERGE_FAILED",
19
19
  NETWORK_ERROR = "NETWORK_ERROR",
20
20
  PR_NOT_FOUND = "PR_NOT_FOUND",
21
+ REMOTE_ALREADY_EXISTS = "REMOTE_ALREADY_EXISTS",
22
+ REPO_CREATE_FAILED = "REPO_CREATE_FAILED",
21
23
  REBASE_CONFLICT = "REBASE_CONFLICT",
22
24
  SYNC_FAILED = "SYNC_FAILED"
23
25
  }
@@ -144,6 +146,32 @@ export interface IGitPrService {
144
146
  * @returns The remote URL, or null if no remote is configured
145
147
  */
146
148
  getRemoteUrl(cwd: string): Promise<string | null>;
149
+ /**
150
+ * Create a GitHub repository and link it to the local repo.
151
+ * Uses `gh repo create` with `--source=.` and `--push` to atomically
152
+ * create the remote repo, add the origin remote, and push the current branch.
153
+ *
154
+ * @param cwd - Working directory path
155
+ * @param name - Repository name (e.g. "my-repo" or "org/my-repo")
156
+ * @param options - Creation options
157
+ * @returns The URL of the created GitHub repository
158
+ * @throws GitPrError with REPO_CREATE_FAILED code on creation failure
159
+ * @throws GitPrError with GH_NOT_FOUND code if gh CLI is not installed
160
+ * @throws GitPrError with AUTH_FAILURE code if gh is not authenticated
161
+ */
162
+ createGitHubRepo(cwd: string, name: string, options: {
163
+ isPrivate: boolean;
164
+ org?: string;
165
+ }): Promise<string>;
166
+ /**
167
+ * Add a git remote to the local repository.
168
+ *
169
+ * @param cwd - Working directory path
170
+ * @param remoteName - Name for the remote (e.g. "origin")
171
+ * @param remoteUrl - URL of the remote repository
172
+ * @throws GitPrError with GIT_ERROR code on failure
173
+ */
174
+ addRemote(cwd: string, remoteName: string, remoteUrl: string): Promise<void>;
147
175
  /**
148
176
  * Detect the repository's default branch with robust fallback chain:
149
177
  * 1. Remote HEAD (git symbolic-ref refs/remotes/origin/HEAD)
@@ -1 +1 @@
1
- {"version":3,"file":"git-pr-service.interface.d.ts","sourceRoot":"","sources":["../../../../../../../../packages/core/src/application/ports/output/services/git-pr-service.interface.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,wCAAwC,CAAC;AAEvE;;GAEG;AACH,oBAAY,cAAc;IACxB,YAAY,iBAAiB;IAC7B,gBAAgB,qBAAqB;IACrC,UAAU,eAAe;IACzB,YAAY,iBAAiB;IAC7B,SAAS,cAAc;IACvB,cAAc,mBAAmB;IACjC,YAAY,iBAAiB;IAC7B,aAAa,kBAAkB;IAC/B,YAAY,iBAAiB;IAC7B,eAAe,oBAAoB;IACnC,WAAW,gBAAgB;CAC5B;AAED;;GAEG;AACH,qBAAa,UAAW,SAAQ,KAAK;aAGjB,IAAI,EAAE,cAAc;aACpB,KAAK,CAAC,EAAE,KAAK;gBAF7B,OAAO,EAAE,MAAM,EACC,IAAI,EAAE,cAAc,EACpB,KAAK,CAAC,EAAE,KAAK,YAAA;CAKhC;AAED;;GAEG;AACH,MAAM,MAAM,QAAQ,GAAG,SAAS,GAAG,SAAS,GAAG,SAAS,CAAC;AAEzD;;GAEG;AACH,MAAM,WAAW,cAAc;IAC7B,wBAAwB;IACxB,MAAM,EAAE,QAAQ,CAAC;IACjB,uDAAuD;IACvD,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,kDAAkD;IAClD,UAAU,CAAC,EAAE,MAAM,CAAC;CACrB;AAED;;GAEG;AACH,MAAM,WAAW,WAAW;IAC1B,8BAA8B;IAC9B,YAAY,EAAE,MAAM,CAAC;IACrB,4BAA4B;IAC5B,SAAS,EAAE,MAAM,CAAC;IAClB,8BAA8B;IAC9B,SAAS,EAAE,MAA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;;;;;;;;;;;;OAaG;IACH,mBAAmB,CACjB,GAAG,EAAE,MAAM,EACX,aAAa,EAAE,MAAM,EACrB,UAAU,EAAE,MAAM,GACjB,OAAO,CAAC;QAAE,KAAK,EAAE,MAAM,CAAC;QAAC,MAAM,EAAE,MAAM,CAAA;KAAE,CAAC,CAAC;CAC/C"}
1
+ {"version":3,"file":"git-pr-service.interface.d.ts","sourceRoot":"","sources":["../../../../../../../../packages/core/src/application/ports/output/services/git-pr-service.interface.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,wCAAwC,CAAC;AAEvE;;GAEG;AACH,oBAAY,cAAc;IACxB,YAAY,iBAAiB;IAC7B,gBAAgB,qBAAqB;IACrC,UAAU,eAAe;IACzB,YAAY,iBAAiB;IAC7B,SAAS,cAAc;IACvB,cAAc,mBAAmB;IACjC,YAAY,iBAAiB;IAC7B,aAAa,kBAAkB;IAC/B,YAAY,iBAAiB;IAC7B,qBAAqB,0BAA0B;IAC/C,kBAAkB,uBAAuB;IACzC,eAAe,oBAAoB;IACnC,WAAW,gBAAgB;CAC5B;AAED;;GAEG;AACH,qBAAa,UAAW,SAAQ,KAAK;aAGjB,IAAI,EAAE,cAAc;aACpB,KAAK,CAAC,EAAE,KAAK;gBAF7B,OAAO,EAAE,MAAM,EACC,IAAI,EAAE,cAAc,EACpB,KAAK,CAAC,EAAE,KAAK,YAAA;CAKhC;AAED;;GAEG;AACH,MAAM,MAAM,QAAQ,GAAG,SAAS,GAAG,SAAS,GAAG,SAAS,CAAC;AAEzD;;GAEG;AACH,MAAM,WAAW,cAAc;IAC7B,wBAAwB;IACxB,MAAM,EAAE,QAAQ,CAAC;IACjB,uDAAuD;IACvD,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,kDAAkD;IAClD,UAAU,CAAC,EAAE,MAAM,CAAC;CACrB;AAED;;GAEG;AACH,MAAM,WAAW,WAAW;IAC1B,8BAA8B;IAC9B,YAA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C,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAE3C;;;;;;OAMG;IACH,WAAW,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAExC;;;;;;;;OAQG;IACH,KAAK,CAAC,GAAG,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC,OAAO,CAAC,CAAC;IAEvD;;;;;;OAMG;IACH,QAAQ,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAErC;;;;;;OAMG;IACH,SAAS,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAEtC;;;;;;;;;;;;;OAaG;IACH,mBAAmB,CACjB,GAAG,EAAE,MAAM,EACX,aAAa,EAAE,MAAM,EACrB,UAAU,EAAE,MAAM,GACjB,OAAO,CAAC;QAAE,KAAK,EAAE,MAAM,CAAC;QAAC,MAAM,EAAE,MAAM,CAAA;KAAE,CAAC,CAAC;CAC/C"}
@@ -18,6 +18,8 @@ export var GitPrErrorCode;
18
18
  GitPrErrorCode["MERGE_FAILED"] = "MERGE_FAILED";
19
19
  GitPrErrorCode["NETWORK_ERROR"] = "NETWORK_ERROR";
20
20
  GitPrErrorCode["PR_NOT_FOUND"] = "PR_NOT_FOUND";
21
+ GitPrErrorCode["REMOTE_ALREADY_EXISTS"] = "REMOTE_ALREADY_EXISTS";
22
+ GitPrErrorCode["REPO_CREATE_FAILED"] = "REPO_CREATE_FAILED";
21
23
  GitPrErrorCode["REBASE_CONFLICT"] = "REBASE_CONFLICT";
22
24
  GitPrErrorCode["SYNC_FAILED"] = "SYNC_FAILED";
23
25
  })(GitPrErrorCode || (GitPrErrorCode = {}));
@@ -35,6 +35,12 @@ export declare class GitHubRepoListError extends Error {
35
35
  export declare class GitHubPermissionError extends Error {
36
36
  constructor(message: string, cause?: Error);
37
37
  }
38
+ /**
39
+ * Thrown when a fork operation fails.
40
+ */
41
+ export declare class GitHubForkError extends Error {
42
+ constructor(message: string, cause?: Error);
43
+ }
38
44
  /**
39
45
  * A GitHub repository as returned by `gh repo list --json`.
40
46
  */
@@ -88,6 +94,26 @@ export interface ParsedGitHubUrl {
88
94
  /** Combined owner/repo (e.g. "octocat/my-project") */
89
95
  nameWithOwner: string;
90
96
  }
97
+ /**
98
+ * Options for forking a repository.
99
+ */
100
+ export interface ForkOptions {
101
+ onProgress?: (message: string) => void;
102
+ }
103
+ /**
104
+ * Result of checking push access on a repository.
105
+ */
106
+ export interface PushAccessResult {
107
+ hasPushAccess: boolean;
108
+ viewerLogin: string;
109
+ }
110
+ /**
111
+ * Result of forking a repository.
112
+ */
113
+ export interface ForkResult {
114
+ nameWithOwner: string;
115
+ alreadyExisted: boolean;
116
+ }
91
117
  /**
92
118
  * Output port for GitHub repository operations.
93
119
  *
@@ -151,5 +177,26 @@ export interface IGitHubRepositoryService {
151
177
  * @throws {GitHubPermissionError} if the permission check fails (e.g. gh not installed, not authenticated)
152
178
  */
153
179
  getViewerPermission(repoPath: string): Promise<string>;
180
+ /**
181
+ * Get the authenticated GitHub user's login.
182
+ * @returns The login username
183
+ * @throws {GitHubAuthError} if not authenticated
184
+ */
185
+ getAuthenticatedUser(): Promise<string>;
186
+ /**
187
+ * Check if the authenticated user has push access to a repository.
188
+ * @param nameWithOwner - Full owner/repo identifier
189
+ * @returns Push access result with viewer login
190
+ * @throws {GitHubPermissionError} on failure
191
+ */
192
+ checkPushAccess(nameWithOwner: string): Promise<PushAccessResult>;
193
+ /**
194
+ * Fork a repository to the authenticated user's account.
195
+ * @param nameWithOwner - Full owner/repo identifier to fork
196
+ * @param options - Optional progress callback
197
+ * @returns Fork result with the fork's nameWithOwner
198
+ * @throws {GitHubForkError} on failure
199
+ */
200
+ forkRepository(nameWithOwner: string, options?: ForkOptions): Promise<ForkResult>;
154
201
  }
155
202
  //# sourceMappingURL=github-repository-service.interface.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"github-repository-service.interface.d.ts","sourceRoot":"","sources":["../../../../../../../../packages/core/src/application/ports/output/services/github-repository-service.interface.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAMH;;GAEG;AACH,qBAAa,eAAgB,SAAQ,KAAK;gBAC5B,OAAO,EAAE,MAAM,EAAE,KAAK,CAAC,EAAE,KAAK;CAM3C;AAED;;GAEG;AACH,qBAAa,gBAAiB,SAAQ,KAAK;gBAC7B,OAAO,EAAE,MAAM,EAAE,KAAK,CAAC,EAAE,KAAK;CAM3C;AAED;;GAEG;AACH,qBAAa,mBAAoB,SAAQ,KAAK;gBAChC,OAAO,EAAE,MAAM,EAAE,KAAK,CAAC,EAAE,KAAK;CAM3C;AAED;;GAEG;AACH,qBAAa,mBAAoB,SAAQ,KAAK;gBAChC,OAAO,EAAE,MAAM,EAAE,KAAK,CAAC,EAAE,KAAK;CAM3C;AAED;;GAEG;AACH,qBAAa,qBAAsB,SAAQ,KAAK;gBAClC,OAAO,EAAE,MAAM,EAAE,KAAK,CAAC,EAAE,KAAK;CAM3C;AAMD;;GAEG;AACH,MAAM,WAAW,UAAU;IACzB,0CAA0C;IAC1C,IAAI,EAAE,MAAM,CAAC;IACb,6DAA6D;IAC7D,aAAa,EAAE,MAAM,CAAC;IACtB,mDAAmD;IACnD,WAAW,EAAE,MAAM,CAAC;IACpB,wCAAwC;IACxC,SAAS,EAAE,OAAO,CAAC;IACnB,iDAAiD;IACjD,QAAQ,EAAE,MAAM,CAAC;CAClB;AAED;;GAEG;AACH,MAAM,WAAW,2BAA2B;IAC1C,sDAAsD;IACtD,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,qCAAqC;IACrC,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,+FAA+F;IAC/F,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED;;GAEG;AACH,MAAM,WAAW,kBAAkB;IACjC,gDAAgD;IAChD,KAAK,EAAE,MAAM,CAAC;IACd,qDAAqD;IACrD,WAAW,EAAE,MAAM,CAAC;CACrB;AAED;;GAEG;AACH,MAAM,WAAW,YAAY;IAC3B,4EAA4E;IAC5E,UAAU,CAAC,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,CAAC;CACrC;AAED;;GAEG;AACH,MAAM,WAAW,eAAe;IAC9B,wCAAwC;IACxC,KAAK,EAAE,MAAM,CAAC;IACd,0CAA0C;IAC1C,IAAI,EAAE,MAAM,CAAC;IACb,sDAAsD;IACtD,aAAa,EAAE,MAAM,CAAC;CACvB;AAMD;;;;GAIG;AACH,MAAM,WAAW,wBAAwB;IACvC;;;;OAIG;IACH,SAAS,IAAI,OAAO,CAAC,IAAI,CAAC,CAAC;IAE3B;;;;;;;OAOG;IACH,eAAe,CACb,aAAa,EAAE,MAAM,EACrB,WAAW,EAAE,MAAM,EACnB,OAAO,CAAC,EAAE,YAAY,GACrB,OAAO,CAAC,IAAI,CAAC,CAAC;IAEjB;;;;;;;;OAQG;IACH,oBAAoB,CAAC,OAAO,CAAC,EAAE,2BAA2B,GAAG,OAAO,CAAC,UAAU,EAAE,CAAC,CAAC;IAEnF;;;;;OAKG;IACH,iBAAiB,IAAI,OAAO,CAAC,kBAAkB,EAAE,CAAC,CAAC;IAEnD;;;;;;;;;;;;OAYG;IACH,cAAc,CAAC,GAAG,EAAE,MAAM,GAAG,eAAe,CAAC;IAE7C;;;;;;;;;OASG;IACH,mBAAmB,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC,CAAC;CACxD"}
1
+ {"version":3,"file":"github-repository-service.interface.d.ts","sourceRoot":"","sources":["../../../../../../../../packages/core/src/application/ports/output/services/github-repository-service.interface.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAMH;;GAEG;AACH,qBAAa,eAAgB,SAAQ,KAAK;gBAC5B,OAAO,EAAE,MAAM,EAAE,KAAK,CAAC,EAAE,KAAK;CAM3C;AAED;;GAEG;AACH,qBAAa,gBAAiB,SAAQ,KAAK;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AAC;IAElE;;;;;;OAMG;IACH,cAAc,CAAC,aAAa,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,WAAW,GAAG,OAAO,CAAC,UAAU,CAAC,CAAC;CACnF"}
@@ -68,3 +68,15 @@ export class GitHubPermissionError extends Error {
68
68
  this.cause = cause;
69
69
  }
70
70
  }
71
+ /**
72
+ * Thrown when a fork operation fails.
73
+ */
74
+ export class GitHubForkError extends Error {
75
+ constructor(message, cause) {
76
+ super(message);
77
+ this.name = 'GitHubForkError';
78
+ Object.setPrototypeOf(this, new.target.prototype);
79
+ if (cause)
80
+ this.cause = cause;
81
+ }
82
+ }
@@ -0,0 +1,28 @@
1
+ /**
2
+ * Browser Opener Interface
3
+ *
4
+ * Output port for opening URLs in the user's default browser.
5
+ * Infrastructure layer provides concrete implementations:
6
+ * - BrowserOpenerService — default, uses platform-specific commands (open, xdg-open, cmd start)
7
+ * - ElectronBrowserOpener — used when running inside Electron (focuses BrowserWindow or shell.openExternal)
8
+ *
9
+ * Following Clean Architecture:
10
+ * - Application layer depends on this interface
11
+ * - Infrastructure layer provides concrete implementations
12
+ */
13
+ /**
14
+ * Port interface for opening URLs in the user's browser or app window.
15
+ *
16
+ * Implementations must:
17
+ * - Handle errors gracefully (log, never throw)
18
+ * - Degrade gracefully in non-interactive environments (CI, piped I/O)
19
+ */
20
+ export interface IBrowserOpener {
21
+ /**
22
+ * Open a URL in the user's default browser or application window.
23
+ *
24
+ * @param url - The URL to open
25
+ */
26
+ open(url: string): void;
27
+ }
28
+ //# sourceMappingURL=i-browser-opener.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"i-browser-opener.d.ts","sourceRoot":"","sources":["../../../../../../../../packages/core/src/application/ports/output/services/i-browser-opener.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAEH;;;;;;GAMG;AACH,MAAM,WAAW,cAAc;IAC7B;;;;OAIG;IACH,IAAI,CAAC,GAAG,EAAE,MAAM,GAAG,IAAI,CAAC;CACzB"}
@@ -0,0 +1,13 @@
1
+ /**
2
+ * Browser Opener Interface
3
+ *
4
+ * Output port for opening URLs in the user's default browser.
5
+ * Infrastructure layer provides concrete implementations:
6
+ * - BrowserOpenerService — default, uses platform-specific commands (open, xdg-open, cmd start)
7
+ * - ElectronBrowserOpener — used when running inside Electron (focuses BrowserWindow or shell.openExternal)
8
+ *
9
+ * Following Clean Architecture:
10
+ * - Application layer depends on this interface
11
+ * - Infrastructure layer provides concrete implementations
12
+ */
13
+ export {};
@@ -0,0 +1,29 @@
1
+ /**
2
+ * Desktop Notifier Interface
3
+ *
4
+ * Output port for sending native OS desktop notifications.
5
+ * Infrastructure layer provides concrete implementations:
6
+ * - DesktopNotifier (node-notifier) — default for CLI/web contexts
7
+ * - ElectronDesktopNotifier — used when running inside Electron
8
+ *
9
+ * Following Clean Architecture:
10
+ * - Application layer depends on this interface
11
+ * - Infrastructure layer provides concrete implementations
12
+ */
13
+ /**
14
+ * Port interface for sending native OS desktop notifications.
15
+ *
16
+ * Implementations must:
17
+ * - Sanitize input to prevent injection (shell metacharacters, length limits)
18
+ * - Handle errors gracefully (log, never throw)
19
+ */
20
+ export interface IDesktopNotifier {
21
+ /**
22
+ * Send a native OS desktop notification.
23
+ *
24
+ * @param title - Notification title
25
+ * @param body - Notification body text
26
+ */
27
+ send(title: string, body: string): void;
28
+ }
29
+ //# sourceMappingURL=i-desktop-notifier.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"i-desktop-notifier.d.ts","sourceRoot":"","sources":["../../../../../../../../packages/core/src/application/ports/output/services/i-desktop-notifier.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAEH;;;;;;GAMG;AACH,MAAM,WAAW,gBAAgB;IAC/B;;;;;OAKG;IACH,IAAI,CAAC,KAAK,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,GAAG,IAAI,CAAC;CACzC"}
@@ -0,0 +1,13 @@
1
+ /**
2
+ * Desktop Notifier Interface
3
+ *
4
+ * Output port for sending native OS desktop notifications.
5
+ * Infrastructure layer provides concrete implementations:
6
+ * - DesktopNotifier (node-notifier) — default for CLI/web contexts
7
+ * - ElectronDesktopNotifier — used when running inside Electron
8
+ *
9
+ * Following Clean Architecture:
10
+ * - Application layer depends on this interface
11
+ * - Infrastructure layer provides concrete implementations
12
+ */
13
+ export {};
@@ -21,4 +21,6 @@ export type { IGitHubRepositoryService, GitHubRepo, GitHubOrganization, ListUser
21
21
  export { GitHubAuthError, GitHubCloneError, GitHubUrlParseError, GitHubRepoListError, } from './github-repository-service.interface.js';
22
22
  export type { IInteractiveSessionService, StreamChunk, UnsubscribeFn, ChatState, } from './interactive-session-service.interface.js';
23
23
  export type { ISkillInjectorService, SkillInjectionResult } from './skill-injector.interface.js';
24
+ export type { IDesktopNotifier } from './i-desktop-notifier.js';
25
+ export type { IBrowserOpener } from './i-browser-opener.js';
24
26
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../../../packages/core/src/application/ports/output/services/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,YAAY,EAAE,qBAAqB,EAAE,aAAa,EAAE,MAAM,uCAAuC,CAAC;AAClG,OAAO,EACL,iBAAiB,EACjB,kBAAkB,EAClB,wBAAwB,EACxB,4BAA4B,GAC7B,MAAM,uCAAuC,CAAC;AAC/C,YAAY,EACV,uBAAuB,EACvB,qBAAqB,GACtB,MAAM,iCAAiC,CAAC;AACzC,YAAY,EAAE,eAAe,EAAE,MAAM,gCAAgC,CAAC;AACtE,YAAY,EAAE,iBAAiB,EAAE,MAAM,mCAAmC,CAAC;AAC3E,YAAY,EAAE,gBAAgB,EAAE,YAAY,EAAE,MAAM,iCAAiC,CAAC;AACtF,OAAO,EAAE,aAAa,EAAE,iBAAiB,EAAE,MAAM,iCAAiC,CAAC;AACnF,YAAY,EAAE,qBAAqB,EAAE,sBAAsB,EAAE,MAAM,6BAA6B,CAAC;AACjG,YAAY,EAAE,oBAAoB,EAAE,MAAM,qCAAqC,CAAC;AAChF,YAAY,EACV,aAAa,EACb,QAAQ,EACR,cAAc,EACd,WAAW,EACX,aAAa,EACb,cAAc,GACf,MAAM,+BAA+B,CAAC;AACvC,OAAO,EAAE,UAAU,EAAE,cAAc,EAAE,MAAM,+BAA+B,CAAC;AAC3E,YAAY,EACV,mBAAmB,EACnB,cAAc,EACd,eAAe,EACf,gBAAgB,EAChB,eAAe,GAChB,MAAM,qCAAqC,CAAC;AAC7C,YAAY,EAAE,cAAc,EAAE,WAAW,EAAE,MAAM,+BAA+B,CAAC;AACjF,YAAY,EAAE,kBAAkB,EAAE,gBAAgB,EAAE,MAAM,mCAAmC,CAAC;AAC9F,YAAY,EACV,wBAAwB,EACxB,UAAU,EACV,kBAAkB,EAClB,2BAA2B,EAC3B,YAAY,EACZ,eAAe,GAChB,MAAM,0CAA0C,CAAC;AAClD,OAAO,EACL,eAAe,EACf,gBAAgB,EAChB,mBAAmB,EACnB,mBAAmB,GACpB,MAAM,0CAA0C,CAAC;AAClD,YAAY,EACV,0BAA0B,EAC1B,WAAW,EACX,aAAa,EACb,SAAS,GACV,MAAM,4CAA4C,CAAC;AACpD,YAAY,EAAE,qBAAqB,EAAE,oBAAoB,EAAE,MAAM,+BAA+B,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../../../packages/core/src/application/ports/output/services/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,YAAY,EAAE,qBAAqB,EAAE,aAAa,EAAE,MAAM,uCAAuC,CAAC;AAClG,OAAO,EACL,iBAAiB,EACjB,kBAAkB,EAClB,wBAAwB,EACxB,4BAA4B,GAC7B,MAAM,uCAAuC,CAAC;AAC/C,YAAY,EACV,uBAAuB,EACvB,qBAAqB,GACtB,MAAM,iCAAiC,CAAC;AACzC,YAAY,EAAE,eAAe,EAAE,MAAM,gCAAgC,CAAC;AACtE,YAAY,EAAE,iBAAiB,EAAE,MAAM,mCAAmC,CAAC;AAC3E,YAAY,EAAE,gBAAgB,EAAE,YAAY,EAAE,MAAM,iCAAiC,CAAC;AACtF,OAAO,EAAE,aAAa,EAAE,iBAAiB,EAAE,MAAM,iCAAiC,CAAC;AACnF,YAAY,EAAE,qBAAqB,EAAE,sBAAsB,EAAE,MAAM,6BAA6B,CAAC;AACjG,YAAY,EAAE,oBAAoB,EAAE,MAAM,qCAAqC,CAAC;AAChF,YAAY,EACV,aAAa,EACb,QAAQ,EACR,cAAc,EACd,WAAW,EACX,aAAa,EACb,cAAc,GACf,MAAM,+BAA+B,CAAC;AACvC,OAAO,EAAE,UAAU,EAAE,cAAc,EAAE,MAAM,+BAA+B,CAAC;AAC3E,YAAY,EACV,mBAAmB,EACnB,cAAc,EACd,eAAe,EACf,gBAAgB,EAChB,eAAe,GAChB,MAAM,qCAAqC,CAAC;AAC7C,YAAY,EAAE,cAAc,EAAE,WAAW,EAAE,MAAM,+BAA+B,CAAC;AACjF,YAAY,EAAE,kBAAkB,EAAE,gBAAgB,EAAE,MAAM,mCAAmC,CAAC;AAC9F,YAAY,EACV,wBAAwB,EACxB,UAAU,EACV,kBAAkB,EAClB,2BAA2B,EAC3B,YAAY,EACZ,eAAe,GAChB,MAAM,0CAA0C,CAAC;AAClD,OAAO,EACL,eAAe,EACf,gBAAgB,EAChB,mBAAmB,EACnB,mBAAmB,GACpB,MAAM,0CAA0C,CAAC;AAClD,YAAY,EACV,0BAA0B,EAC1B,WAAW,EACX,aAAa,EACb,SAAS,GACV,MAAM,4CAA4C,CAAC;AACpD,YAAY,EAAE,qBAAqB,EAAE,oBAAoB,EAAE,MAAM,+BAA+B,CAAC;AACjG,YAAY,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAChE,YAAY,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC"}
@@ -0,0 +1,67 @@
1
+ /**
2
+ * Create Feature From Remote Use Case
3
+ *
4
+ * Composite use case that chains ImportGitHubRepositoryUseCase with
5
+ * CreateFeatureUseCase. Enables creating a feature on a remote GitHub
6
+ * repo in a single command — clone (or fork), register, then create feature.
7
+ *
8
+ * Provides two execution modes:
9
+ * - execute(): synchronous full flow for CLI
10
+ * - createRecord() + initializeAndSpawn(): two-phase for Web UI (fast response + background work)
11
+ */
12
+ import type { Feature } from '../../../../domain/generated/output.js';
13
+ import type { ApprovalGates, Attachment } from '../../../../domain/generated/output.js';
14
+ import type { CloneOptions, ForkOptions } from '../../../ports/output/services/github-repository-service.interface.js';
15
+ import { ImportGitHubRepositoryUseCase } from '../../repositories/import-github-repository.use-case.js';
16
+ import { CreateFeatureUseCase } from './create-feature.use-case.js';
17
+ import type { CreateFeatureResult, CreateRecordResult } from './types.js';
18
+ export interface CreateFeatureFromRemoteInput {
19
+ /** GitHub URL or owner/repo shorthand */
20
+ remoteUrl: string;
21
+ /** Override clone destination directory */
22
+ cloneDest?: string;
23
+ /** Default base directory for clones (from settings) */
24
+ defaultCloneDir?: string;
25
+ /** Options for the clone subprocess */
26
+ cloneOptions?: CloneOptions;
27
+ /** Options for fork operations */
28
+ forkOptions?: ForkOptions;
29
+ userInput: string;
30
+ approvalGates?: ApprovalGates;
31
+ push?: boolean;
32
+ openPr?: boolean;
33
+ parentId?: string;
34
+ name?: string;
35
+ description?: string;
36
+ fast?: boolean;
37
+ pending?: boolean;
38
+ agentType?: string;
39
+ model?: string;
40
+ attachments?: Attachment[];
41
+ sessionId?: string;
42
+ attachmentPaths?: string[];
43
+ }
44
+ export declare class CreateFeatureFromRemoteUseCase {
45
+ private readonly importUseCase;
46
+ private readonly createFeatureUseCase;
47
+ constructor(importUseCase: ImportGitHubRepositoryUseCase, createFeatureUseCase: CreateFeatureUseCase);
48
+ /**
49
+ * Full synchronous execution: import repo then create feature.
50
+ * Used by the CLI which shows a spinner and needs everything done before returning.
51
+ */
52
+ execute(input: CreateFeatureFromRemoteInput): Promise<CreateFeatureResult>;
53
+ /**
54
+ * Phase 1 (fast): import repo + create DB record. Returns immediately with real feature ID.
55
+ * Used by the Web UI for optimistic display.
56
+ */
57
+ createRecord(input: CreateFeatureFromRemoteInput): Promise<CreateRecordResult>;
58
+ /**
59
+ * Phase 2 (background): metadata generation, worktree, spec, agent spawn.
60
+ * Fire-and-forget from the Web UI.
61
+ */
62
+ initializeAndSpawn(feature: Feature, input: CreateFeatureFromRemoteInput, shouldSpawn: boolean): Promise<{
63
+ warning?: string;
64
+ updatedFeature: Feature;
65
+ }>;
66
+ }
67
+ //# sourceMappingURL=create-feature-from-remote.use-case.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"create-feature-from-remote.use-case.d.ts","sourceRoot":"","sources":["../../../../../../../../packages/core/src/application/use-cases/features/create/create-feature-from-remote.use-case.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAGH,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,wCAAwC,CAAC;AACtE,OAAO,KAAK,EAAE,aAAa,EAAE,UAAU,EAAE,MAAM,wCAAwC,CAAC;AACxF,OAAO,KAAK,EACV,YAAY,EACZ,WAAW,EACZ,MAAM,uEAAuE,CAAC;AAC/E,OAAO,EAAE,6BAA6B,EAAE,MAAM,yDAAyD,CAAC;AACxG,OAAO,EAAE,oBAAoB,EAAE,MAAM,8BAA8B,CAAC;AACpE,OAAO,KAAK,EAAE,mBAAmB,EAAE,kBAAkB,EAAE,MAAM,YAAY,CAAC;AAE1E,MAAM,WAAW,4BAA4B;IAC3C,yCAAyC;IACzC,SAAS,EAAE,MAAM,CAAC;IAClB,2CAA2C;IAC3C,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,wDAAwD;IACxD,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,uCAAuC;IACvC,YAAY,CAAC,EAAE,YAAY,CAAC;IAC5B,kCAAkC;IAClC,WAAW,CAAC,EAAE,WAAW,CAAC;IAG1B,SAAS,EAAE,MAAM,CAAC;IAClB,aAAa,CAAC,EAAE,aAAa,CAAC;IAC9B,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,WAAW,CAAC,EAAE,UAAU,EAAE,CAAC;IAC3B,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,eAAe,CAAC,EAAE,MAAM,EAAE,CAAC;CAC5B;AAED,qBACa,8BAA8B;IAGvC,OAAO,CAAC,QAAQ,CAAC,aAAa;IAE9B,OAAO,CAAC,QAAQ,CAAC,oBAAoB;gBAFpB,aAAa,EAAE,6BAA6B,EAE5C,oBAAoB,EAAE,oBAAoB;IAG7D;;;OAGG;IACG,OAAO,CAAC,KAAK,EAAE,4BAA4B,GAAG,OAAO,CAAC,mBAAmB,CAAC;IA4BhF;;;OAGG;IACG,YAAY,CAAC,KAAK,EAAE,4BAA4B,GAAG,OAAO,CAAC,kBAAkB,CAAC;IA4BpF;;;OAGG;IACG,kBAAkB,CACtB,OAAO,EAAE,OAAO,EAChB,KAAK,EAAE,4BAA4B,EACnC,WAAW,EAAE,OAAO,GACnB,OAAO,CAAC;QAAE,OAAO,CAAC,EAAE,MAAM,CAAC;QAAC,cAAc,EAAE,OAAO,CAAA;KAAE,CAAC;CA0B1D"}
@@ -0,0 +1,128 @@
1
+ /**
2
+ * Create Feature From Remote Use Case
3
+ *
4
+ * Composite use case that chains ImportGitHubRepositoryUseCase with
5
+ * CreateFeatureUseCase. Enables creating a feature on a remote GitHub
6
+ * repo in a single command — clone (or fork), register, then create feature.
7
+ *
8
+ * Provides two execution modes:
9
+ * - execute(): synchronous full flow for CLI
10
+ * - createRecord() + initializeAndSpawn(): two-phase for Web UI (fast response + background work)
11
+ */
12
+ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
13
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
14
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
15
+ else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
16
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
17
+ };
18
+ var __metadata = (this && this.__metadata) || function (k, v) {
19
+ if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
20
+ };
21
+ var __param = (this && this.__param) || function (paramIndex, decorator) {
22
+ return function (target, key) { decorator(target, key, paramIndex); }
23
+ };
24
+ import { injectable, inject } from 'tsyringe';
25
+ import { ImportGitHubRepositoryUseCase } from '../../repositories/import-github-repository.use-case.js';
26
+ import { CreateFeatureUseCase } from './create-feature.use-case.js';
27
+ let CreateFeatureFromRemoteUseCase = class CreateFeatureFromRemoteUseCase {
28
+ importUseCase;
29
+ createFeatureUseCase;
30
+ constructor(importUseCase, createFeatureUseCase) {
31
+ this.importUseCase = importUseCase;
32
+ this.createFeatureUseCase = createFeatureUseCase;
33
+ }
34
+ /**
35
+ * Full synchronous execution: import repo then create feature.
36
+ * Used by the CLI which shows a spinner and needs everything done before returning.
37
+ */
38
+ async execute(input) {
39
+ const repository = await this.importUseCase.execute({
40
+ url: input.remoteUrl,
41
+ dest: input.cloneDest,
42
+ defaultCloneDir: input.defaultCloneDir,
43
+ cloneOptions: input.cloneOptions,
44
+ forkOptions: input.forkOptions,
45
+ });
46
+ return this.createFeatureUseCase.execute({
47
+ userInput: input.userInput,
48
+ repositoryPath: repository.path,
49
+ approvalGates: input.approvalGates,
50
+ push: input.push,
51
+ openPr: input.openPr,
52
+ parentId: input.parentId,
53
+ name: input.name,
54
+ description: input.description,
55
+ fast: input.fast,
56
+ pending: input.pending,
57
+ agentType: input.agentType,
58
+ model: input.model,
59
+ attachments: input.attachments,
60
+ sessionId: input.sessionId,
61
+ attachmentPaths: input.attachmentPaths,
62
+ });
63
+ }
64
+ /**
65
+ * Phase 1 (fast): import repo + create DB record. Returns immediately with real feature ID.
66
+ * Used by the Web UI for optimistic display.
67
+ */
68
+ async createRecord(input) {
69
+ const repository = await this.importUseCase.execute({
70
+ url: input.remoteUrl,
71
+ dest: input.cloneDest,
72
+ defaultCloneDir: input.defaultCloneDir,
73
+ cloneOptions: input.cloneOptions,
74
+ forkOptions: input.forkOptions,
75
+ });
76
+ return this.createFeatureUseCase.createRecord({
77
+ userInput: input.userInput,
78
+ repositoryPath: repository.path,
79
+ approvalGates: input.approvalGates,
80
+ push: input.push,
81
+ openPr: input.openPr,
82
+ parentId: input.parentId,
83
+ name: input.name,
84
+ description: input.description,
85
+ fast: input.fast,
86
+ pending: input.pending,
87
+ agentType: input.agentType,
88
+ model: input.model,
89
+ attachments: input.attachments,
90
+ sessionId: input.sessionId,
91
+ attachmentPaths: input.attachmentPaths,
92
+ });
93
+ }
94
+ /**
95
+ * Phase 2 (background): metadata generation, worktree, spec, agent spawn.
96
+ * Fire-and-forget from the Web UI.
97
+ */
98
+ async initializeAndSpawn(feature, input, shouldSpawn) {
99
+ return this.createFeatureUseCase.initializeAndSpawn(feature, {
100
+ userInput: input.userInput,
101
+ // CreateFeatureUseCase.initializeAndSpawn reads the effective repo path
102
+ // from feature.repositoryPath, but the interface still requires this
103
+ // field. Pass the feature's repositoryPath for consistency.
104
+ repositoryPath: feature.repositoryPath,
105
+ approvalGates: input.approvalGates,
106
+ push: input.push,
107
+ openPr: input.openPr,
108
+ parentId: input.parentId,
109
+ name: input.name,
110
+ description: input.description,
111
+ fast: input.fast,
112
+ pending: input.pending,
113
+ agentType: input.agentType,
114
+ model: input.model,
115
+ attachments: input.attachments,
116
+ sessionId: input.sessionId,
117
+ attachmentPaths: input.attachmentPaths,
118
+ }, shouldSpawn);
119
+ }
120
+ };
121
+ CreateFeatureFromRemoteUseCase = __decorate([
122
+ injectable(),
123
+ __param(0, inject(ImportGitHubRepositoryUseCase)),
124
+ __param(1, inject(CreateFeatureUseCase)),
125
+ __metadata("design:paramtypes", [ImportGitHubRepositoryUseCase,
126
+ CreateFeatureUseCase])
127
+ ], CreateFeatureFromRemoteUseCase);
128
+ export { CreateFeatureFromRemoteUseCase };
@@ -2,12 +2,12 @@
2
2
  * Import GitHub Repository Use Case
3
3
  *
4
4
  * Orchestrates importing a GitHub repository: validates the URL, checks auth,
5
- * detects duplicates by remoteUrl, clones via IGitHubRepositoryService,
6
- * delegates local registration to AddRepositoryUseCase, and updates the
7
- * repository record with the normalized remoteUrl.
5
+ * detects duplicates by remoteUrl/upstreamUrl, checks push access, and either
6
+ * clones directly or auto-forks when the user lacks push access.
8
7
  */
9
8
  import type { Repository } from '../../../domain/generated/output.js';
10
- import type { IGitHubRepositoryService, CloneOptions } from '../../ports/output/services/github-repository-service.interface.js';
9
+ import type { IGitHubRepositoryService, CloneOptions, ForkOptions } from '../../ports/output/services/github-repository-service.interface.js';
10
+ import type { IGitPrService } from '../../ports/output/services/git-pr-service.interface.js';
11
11
  import type { IRepositoryRepository } from '../../ports/output/repositories/repository-repository.interface.js';
12
12
  import { AddRepositoryUseCase } from './add-repository.use-case.js';
13
13
  export interface ImportGitHubRepositoryInput {
@@ -19,13 +19,24 @@ export interface ImportGitHubRepositoryInput {
19
19
  defaultCloneDir?: string;
20
20
  /** Options for the clone subprocess (e.g. progress callback) */
21
21
  cloneOptions?: CloneOptions;
22
+ /** Options for fork operations (e.g. progress callback) */
23
+ forkOptions?: ForkOptions;
22
24
  }
23
25
  export declare class ImportGitHubRepositoryUseCase {
24
26
  private readonly gitHubService;
25
27
  private readonly repositoryRepo;
26
28
  private readonly addRepositoryUseCase;
27
- constructor(gitHubService: IGitHubRepositoryService, repositoryRepo: IRepositoryRepository, addRepositoryUseCase: AddRepositoryUseCase);
29
+ private readonly gitPrService;
30
+ constructor(gitHubService: IGitHubRepositoryService, repositoryRepo: IRepositoryRepository, addRepositoryUseCase: AddRepositoryUseCase, gitPrService: IGitPrService);
28
31
  execute(input: ImportGitHubRepositoryInput): Promise<Repository>;
32
+ /**
33
+ * Direct clone path — user has push access to the repository.
34
+ */
35
+ private cloneDirect;
36
+ /**
37
+ * Fork-and-clone path — user lacks push access, so we auto-fork first.
38
+ */
39
+ private forkAndClone;
29
40
  private resolveDestination;
30
41
  }
31
42
  //# sourceMappingURL=import-github-repository.use-case.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"import-github-repository.use-case.d.ts","sourceRoot":"","sources":["../../../../../../../packages/core/src/application/use-cases/repositories/import-github-repository.use-case.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAKH,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,qCAAqC,CAAC;AACtE,OAAO,KAAK,EACV,wBAAwB,EACxB,YAAY,EACb,MAAM,oEAAoE,CAAC;AAC5E,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,oEAAoE,CAAC;AAChH,OAAO,EAAE,oBAAoB,EAAE,MAAM,8BAA8B,CAAC;AAEpE,MAAM,WAAW,2BAA2B;IAC1C,kDAAkD;IAClD,GAAG,EAAE,MAAM,CAAC;IACZ,2CAA2C;IAC3C,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,wDAAwD;IACxD,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,gEAAgE;IAChE,YAAY,CAAC,EAAE,YAAY,CAAC;CAC7B;AAUD,qBACa,6BAA6B;IAGtC,OAAO,CAAC,QAAQ,CAAC,aAAa;IAE9B,OAAO,CAAC,QAAQ,CAAC,cAAc;IAE/B,OAAO,CAAC,QAAQ,CAAC,oBAAoB;gBAJpB,aAAa,EAAE,wBAAwB,EAEvC,cAAc,EAAE,qBAAqB,EAErC,oBAAoB,EAAE,oBAAoB;IAGvD,OAAO,CAAC,KAAK,EAAE,2BAA2B,GAAG,OAAO,CAAC,UAAU,CAAC;IAoCtE,OAAO,CAAC,kBAAkB;CAW3B"}
1
+ {"version":3,"file":"import-github-repository.use-case.d.ts","sourceRoot":"","sources":["../../../../../../../packages/core/src/application/use-cases/repositories/import-github-repository.use-case.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAKH,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,qCAAqC,CAAC;AACtE,OAAO,KAAK,EACV,wBAAwB,EACxB,YAAY,EACZ,WAAW,EACZ,MAAM,oEAAoE,CAAC;AAC5E,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,yDAAyD,CAAC;AAC7F,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,oEAAoE,CAAC;AAChH,OAAO,EAAE,oBAAoB,EAAE,MAAM,8BAA8B,CAAC;AAKpE,MAAM,WAAW,2BAA2B;IAC1C,kDAAkD;IAClD,GAAG,EAAE,MAAM,CAAC;IACZ,2CAA2C;IAC3C,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,wDAAwD;IACxD,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,gEAAgE;IAChE,YAAY,CAAC,EAAE,YAAY,CAAC;IAC5B,2DAA2D;IAC3D,WAAW,CAAC,EAAE,WAAW,CAAC;CAC3B;AAUD,qBACa,6BAA6B;IAGtC,OAAO,CAAC,QAAQ,CAAC,aAAa;IAE9B,OAAO,CAAC,QAAQ,CAAC,cAAc;IAE/B,OAAO,CAAC,QAAQ,CAAC,oBAAoB;IAErC,OAAO,CAAC,QAAQ,CAAC,YAAY;gBANZ,aAAa,EAAE,wBAAwB,EAEvC,cAAc,EAAE,qBAAqB,EAErC,oBAAoB,EAAE,oBAAoB,EAE1C,YAAY,EAAE,aAAa;IAGxC,OAAO,CAAC,KAAK,EAAE,2BAA2B,GAAG,OAAO,CAAC,UAAU,CAAC;IAgCtE;;OAEG;YACW,WAAW;IAsBzB;;OAEG;YACW,YAAY;IAqD1B,OAAO,CAAC,kBAAkB;CAW3B"}