@hubspot/cli 7.5.2-experimental.0 → 7.5.3-beta.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (413) hide show
  1. package/api/migrate.d.ts +12 -3
  2. package/api/migrate.js +9 -2
  3. package/bin/cli.js +100 -93
  4. package/commands/account/auth.d.ts +8 -0
  5. package/commands/account/auth.js +175 -0
  6. package/commands/account/clean.d.ts +3 -7
  7. package/commands/account/clean.js +54 -14
  8. package/commands/account/createOverride.d.ts +6 -0
  9. package/commands/account/createOverride.js +121 -0
  10. package/commands/account/info.d.ts +3 -7
  11. package/commands/account/info.js +36 -5
  12. package/commands/account/list.d.ts +3 -7
  13. package/commands/account/list.js +38 -15
  14. package/commands/account/remove.d.ts +3 -7
  15. package/commands/account/remove.js +49 -9
  16. package/commands/account/removeOverride.d.ts +6 -0
  17. package/commands/account/removeOverride.js +93 -0
  18. package/commands/account/rename.d.ts +3 -7
  19. package/commands/account/rename.js +16 -9
  20. package/commands/account/use.d.ts +5 -9
  21. package/commands/account/use.js +27 -6
  22. package/commands/account.d.ts +3 -4
  23. package/commands/account.js +33 -53
  24. package/commands/app/migrate.d.ts +5 -6
  25. package/commands/app/migrate.js +60 -44
  26. package/commands/app/secret/add.d.ts +7 -0
  27. package/commands/app/secret/add.js +64 -0
  28. package/commands/app/secret/delete.d.ts +8 -0
  29. package/commands/app/secret/delete.js +87 -0
  30. package/commands/app/secret/list.d.ts +6 -0
  31. package/commands/app/secret/list.js +64 -0
  32. package/commands/app/secret/update.d.ts +7 -0
  33. package/commands/app/secret/update.js +77 -0
  34. package/commands/app/secret.d.ts +3 -0
  35. package/commands/app/secret.js +30 -0
  36. package/commands/app.d.ts +2 -5
  37. package/commands/app.js +10 -10
  38. package/commands/auth.d.ts +5 -7
  39. package/commands/auth.js +37 -33
  40. package/commands/cms/convertFields.d.ts +7 -1
  41. package/commands/cms/convertFields.js +57 -41
  42. package/commands/cms/getReactModule.d.ts +7 -1
  43. package/commands/cms/getReactModule.js +52 -34
  44. package/commands/cms/lighthouseScore.d.ts +8 -1
  45. package/commands/cms/lighthouseScore.js +129 -100
  46. package/commands/cms.d.ts +3 -1
  47. package/commands/cms.js +22 -16
  48. package/commands/completion.d.ts +3 -1
  49. package/commands/completion.js +23 -13
  50. package/commands/config/migrate.d.ts +6 -0
  51. package/commands/config/migrate.js +75 -0
  52. package/commands/config/set.d.ts +10 -1
  53. package/commands/config/set.js +56 -32
  54. package/commands/config.d.ts +3 -1
  55. package/commands/config.js +19 -11
  56. package/commands/create/api-sample.d.ts +3 -1
  57. package/commands/create/api-sample.js +34 -38
  58. package/commands/create/app.d.ts +3 -1
  59. package/commands/create/app.js +9 -7
  60. package/commands/create/function.d.ts +3 -1
  61. package/commands/create/function.js +11 -10
  62. package/commands/create/index.d.ts +5 -1
  63. package/commands/create/index.js +23 -11
  64. package/commands/create/module.d.ts +3 -1
  65. package/commands/create/module.js +14 -13
  66. package/commands/create/react-app.d.ts +3 -1
  67. package/commands/create/react-app.js +10 -7
  68. package/commands/create/template.d.ts +3 -1
  69. package/commands/create/template.js +14 -14
  70. package/commands/create/vue-app.d.ts +3 -1
  71. package/commands/create/vue-app.js +10 -7
  72. package/commands/create/webpack-serverless.d.ts +3 -1
  73. package/commands/create/webpack-serverless.js +10 -7
  74. package/commands/create/website-theme.d.ts +3 -1
  75. package/commands/create/website-theme.js +10 -9
  76. package/commands/create.d.ts +4 -24
  77. package/commands/create.js +62 -75
  78. package/commands/customObject/create.d.ts +4 -9
  79. package/commands/customObject/create.js +17 -10
  80. package/commands/customObject/schema/create.d.ts +4 -9
  81. package/commands/customObject/schema/create.js +18 -11
  82. package/commands/customObject/schema/delete.d.ts +4 -9
  83. package/commands/customObject/schema/delete.js +17 -10
  84. package/commands/customObject/schema/fetch-all.d.ts +4 -9
  85. package/commands/customObject/schema/fetch-all.js +17 -10
  86. package/commands/customObject/schema/fetch.d.ts +4 -9
  87. package/commands/customObject/schema/fetch.js +17 -10
  88. package/commands/customObject/schema/list.d.ts +4 -8
  89. package/commands/customObject/schema/list.js +17 -10
  90. package/commands/customObject/schema/update.d.ts +4 -9
  91. package/commands/customObject/schema/update.js +18 -11
  92. package/commands/customObject/schema.d.ts +3 -5
  93. package/commands/customObject/schema.js +27 -54
  94. package/commands/customObject.d.ts +3 -4
  95. package/commands/customObject.js +20 -48
  96. package/commands/doctor.d.ts +6 -8
  97. package/commands/doctor.js +30 -22
  98. package/commands/feedback.d.ts +4 -1
  99. package/commands/feedback.js +38 -48
  100. package/commands/fetch.d.ts +12 -1
  101. package/commands/fetch.js +49 -34
  102. package/commands/filemanager/fetch.d.ts +4 -9
  103. package/commands/filemanager/fetch.js +18 -11
  104. package/commands/filemanager/upload.d.ts +4 -9
  105. package/commands/filemanager/upload.js +17 -11
  106. package/commands/filemanager.d.ts +3 -4
  107. package/commands/filemanager.js +18 -42
  108. package/commands/function/deploy.d.ts +6 -1
  109. package/commands/function/deploy.js +70 -50
  110. package/commands/function/list.d.ts +6 -1
  111. package/commands/function/list.js +44 -32
  112. package/commands/function/server.d.ts +10 -1
  113. package/commands/function/server.js +49 -38
  114. package/commands/function.d.ts +5 -1
  115. package/commands/function.js +22 -11
  116. package/commands/getStarted.d.ts +9 -0
  117. package/commands/getStarted.js +227 -0
  118. package/commands/hubdb/clear.d.ts +4 -9
  119. package/commands/hubdb/clear.js +21 -15
  120. package/commands/hubdb/create.d.ts +4 -9
  121. package/commands/hubdb/create.js +23 -17
  122. package/commands/hubdb/delete.d.ts +4 -9
  123. package/commands/hubdb/delete.js +24 -16
  124. package/commands/hubdb/fetch.d.ts +4 -9
  125. package/commands/hubdb/fetch.js +20 -14
  126. package/commands/hubdb/list.d.ts +4 -0
  127. package/commands/hubdb/list.js +83 -0
  128. package/commands/hubdb.d.ts +3 -2
  129. package/commands/hubdb.js +24 -47
  130. package/commands/init.d.ts +3 -7
  131. package/commands/init.js +31 -24
  132. package/commands/lint.d.ts +6 -4
  133. package/commands/lint.js +42 -44
  134. package/commands/list.d.ts +3 -7
  135. package/commands/list.js +21 -16
  136. package/commands/logs.d.ts +10 -1
  137. package/commands/logs.js +53 -45
  138. package/commands/mcp/setup.d.ts +7 -0
  139. package/commands/mcp/setup.js +50 -0
  140. package/commands/mcp/start.d.ts +3 -0
  141. package/commands/mcp/start.js +75 -0
  142. package/commands/mcp.d.ts +3 -0
  143. package/commands/mcp.js +26 -0
  144. package/commands/module/marketplace-validate.d.ts +6 -1
  145. package/commands/module/marketplace-validate.js +39 -30
  146. package/commands/module.d.ts +3 -1
  147. package/commands/module.js +23 -12
  148. package/commands/mv.d.ts +3 -7
  149. package/commands/mv.js +20 -15
  150. package/commands/open.d.ts +3 -7
  151. package/commands/open.js +20 -15
  152. package/commands/project/add.d.ts +8 -9
  153. package/commands/project/add.js +53 -85
  154. package/commands/project/cloneApp.d.ts +6 -8
  155. package/commands/project/cloneApp.js +51 -47
  156. package/commands/project/create.d.ts +4 -1
  157. package/commands/project/create.js +132 -81
  158. package/commands/project/deploy.d.ts +5 -6
  159. package/commands/project/deploy.js +93 -37
  160. package/commands/project/dev/deprecatedFlow.d.ts +8 -2
  161. package/commands/project/dev/deprecatedFlow.js +41 -26
  162. package/commands/project/dev/index.d.ts +4 -5
  163. package/commands/project/dev/index.js +103 -33
  164. package/commands/project/dev/unifiedFlow.d.ts +11 -2
  165. package/commands/project/dev/unifiedFlow.js +85 -46
  166. package/commands/project/download.d.ts +3 -7
  167. package/commands/project/download.js +18 -19
  168. package/commands/project/installDeps.d.ts +6 -1
  169. package/commands/project/installDeps.js +48 -32
  170. package/commands/project/listBuilds.d.ts +3 -7
  171. package/commands/project/listBuilds.js +32 -30
  172. package/commands/project/logs.d.ts +10 -1
  173. package/commands/project/logs.js +73 -65
  174. package/commands/project/migrate.d.ts +7 -8
  175. package/commands/project/migrate.js +49 -26
  176. package/commands/project/migrateApp.d.ts +3 -8
  177. package/commands/project/migrateApp.js +23 -20
  178. package/commands/project/open.d.ts +3 -7
  179. package/commands/project/open.js +29 -21
  180. package/commands/project/profile/add.d.ts +7 -0
  181. package/commands/project/profile/add.js +209 -0
  182. package/commands/project/profile/delete.d.ts +6 -0
  183. package/commands/project/profile/delete.js +123 -0
  184. package/commands/project/profile.d.ts +3 -0
  185. package/commands/project/profile.js +25 -0
  186. package/commands/project/upload.d.ts +10 -1
  187. package/commands/project/upload.js +94 -56
  188. package/commands/project/validate.d.ts +6 -0
  189. package/commands/project/validate.js +81 -0
  190. package/commands/project/watch.d.ts +6 -1
  191. package/commands/project/watch.js +95 -61
  192. package/commands/project.d.ts +3 -1
  193. package/commands/project.js +49 -37
  194. package/commands/remove.d.ts +3 -7
  195. package/commands/remove.js +22 -20
  196. package/commands/sandbox/create.d.ts +4 -9
  197. package/commands/sandbox/create.js +27 -21
  198. package/commands/sandbox/delete.d.ts +4 -9
  199. package/commands/sandbox/delete.js +35 -29
  200. package/commands/sandbox.d.ts +3 -4
  201. package/commands/sandbox.js +18 -44
  202. package/commands/secret/addSecret.d.ts +4 -9
  203. package/commands/secret/addSecret.js +21 -15
  204. package/commands/secret/deleteSecret.d.ts +4 -9
  205. package/commands/secret/deleteSecret.js +28 -18
  206. package/commands/secret/listSecret.d.ts +4 -9
  207. package/commands/secret/listSecret.js +19 -13
  208. package/commands/secret/updateSecret.d.ts +4 -9
  209. package/commands/secret/updateSecret.js +25 -17
  210. package/commands/secret.d.ts +3 -4
  211. package/commands/secret.js +23 -49
  212. package/commands/theme/generate-selectors.d.ts +3 -7
  213. package/commands/theme/generate-selectors.js +20 -16
  214. package/commands/theme/marketplace-validate.d.ts +4 -9
  215. package/commands/theme/marketplace-validate.js +22 -18
  216. package/commands/theme/preview.d.ts +4 -9
  217. package/commands/theme/preview.js +36 -30
  218. package/commands/theme.d.ts +3 -4
  219. package/commands/theme.js +22 -48
  220. package/commands/upload.d.ts +12 -1
  221. package/commands/upload.js +116 -135
  222. package/commands/watch.d.ts +14 -1
  223. package/commands/watch.js +74 -76
  224. package/lang/en.d.ts +3218 -0
  225. package/lang/en.js +3075 -3313
  226. package/lang/en.lyaml +96 -228
  227. package/lib/accountTypes.d.ts +1 -0
  228. package/lib/accountTypes.js +11 -0
  229. package/lib/app/migrate.d.ts +33 -4
  230. package/lib/app/migrate.js +172 -91
  231. package/lib/app/migrate_legacy.d.ts +2 -2
  232. package/lib/app/migrate_legacy.js +12 -11
  233. package/lib/app/urls.d.ts +16 -0
  234. package/lib/app/urls.js +16 -0
  235. package/lib/buildAccount.d.ts +1 -2
  236. package/lib/buildAccount.js +11 -10
  237. package/lib/commonOpts.d.ts +4 -7
  238. package/lib/commonOpts.js +47 -19
  239. package/lib/configMigrate.d.ts +2 -0
  240. package/lib/configMigrate.js +83 -0
  241. package/lib/configOptions.d.ts +4 -0
  242. package/lib/configOptions.js +41 -45
  243. package/lib/constants.d.ts +33 -0
  244. package/lib/constants.js +34 -1
  245. package/lib/dependencyManagement.d.ts +0 -5
  246. package/lib/dependencyManagement.js +14 -40
  247. package/lib/doctor/Diagnosis.d.ts +1 -2
  248. package/lib/doctor/Diagnosis.js +19 -16
  249. package/lib/doctor/DiagnosticInfoBuilder.d.ts +2 -1
  250. package/lib/doctor/DiagnosticInfoBuilder.js +10 -9
  251. package/lib/doctor/Doctor.d.ts +1 -0
  252. package/lib/doctor/Doctor.js +60 -46
  253. package/lib/errorHandlers/index.js +13 -7
  254. package/lib/errorHandlers/suppressError.js +18 -26
  255. package/lib/filesystem.d.ts +1 -1
  256. package/lib/generateSelectors.js +3 -6
  257. package/lib/hasFeature.d.ts +3 -1
  258. package/lib/interpolation.d.ts +2 -3
  259. package/lib/lang.d.ts +2 -3
  260. package/lib/marketplaceValidate.d.ts +12 -2
  261. package/lib/marketplaceValidate.js +22 -29
  262. package/lib/mcp/setup.d.ts +12 -0
  263. package/lib/mcp/setup.js +216 -0
  264. package/lib/middleware/__test__/yargsChecksMiddleware.test.js +3 -3
  265. package/lib/middleware/autoUpdateMiddleware.d.ts +1 -0
  266. package/lib/middleware/autoUpdateMiddleware.js +89 -0
  267. package/lib/middleware/configMiddleware.js +37 -3
  268. package/lib/middleware/fireAlarmMiddleware.d.ts +4 -0
  269. package/lib/middleware/fireAlarmMiddleware.js +125 -0
  270. package/lib/middleware/yargsChecksMiddleware.js +2 -2
  271. package/lib/npm.d.ts +9 -0
  272. package/lib/npm.js +36 -0
  273. package/lib/oauth.js +1 -2
  274. package/lib/process.js +1 -2
  275. package/lib/projectProfiles.d.ts +7 -0
  276. package/lib/projectProfiles.js +83 -0
  277. package/lib/projects/ProjectLogsManager.d.ts +1 -1
  278. package/lib/projects/ProjectLogsManager.js +16 -21
  279. package/lib/projects/add/legacyAddComponent.d.ts +5 -0
  280. package/lib/projects/add/legacyAddComponent.js +48 -0
  281. package/lib/projects/add/v3AddComponent.d.ts +8 -0
  282. package/lib/projects/add/v3AddComponent.js +85 -0
  283. package/lib/projects/buildAndDeploy.js +46 -42
  284. package/lib/projects/components.d.ts +2 -0
  285. package/lib/projects/components.js +82 -0
  286. package/lib/projects/config.d.ts +9 -0
  287. package/lib/projects/config.js +79 -0
  288. package/lib/projects/create/index.d.ts +23 -0
  289. package/lib/projects/create/index.js +33 -0
  290. package/lib/projects/create/legacy.d.ts +6 -0
  291. package/lib/projects/{create.js → create/legacy.js} +23 -15
  292. package/lib/projects/create/v3.d.ts +27 -0
  293. package/lib/projects/create/v3.js +158 -0
  294. package/lib/projects/ensureProjectExists.d.ts +11 -0
  295. package/lib/projects/ensureProjectExists.js +97 -0
  296. package/lib/projects/localDev/AppDevModeInterface.d.ts +30 -0
  297. package/lib/projects/localDev/AppDevModeInterface.js +214 -0
  298. package/lib/{DevServerManager.d.ts → projects/localDev/DevServerManager.d.ts} +1 -1
  299. package/lib/{DevServerManager.js → projects/localDev/DevServerManager.js} +6 -6
  300. package/lib/projects/localDev/DevServerManagerV2.d.ts +22 -0
  301. package/lib/{DevServerManagerV2.js → projects/localDev/DevServerManagerV2.js} +22 -19
  302. package/lib/projects/localDev/LocalDevLogger.d.ts +30 -0
  303. package/lib/projects/localDev/LocalDevLogger.js +159 -0
  304. package/lib/{LocalDevManager.d.ts → projects/localDev/LocalDevManager.d.ts} +1 -1
  305. package/lib/{LocalDevManager.js → projects/localDev/LocalDevManager.js} +57 -83
  306. package/lib/projects/localDev/LocalDevProcess.d.ts +34 -0
  307. package/lib/projects/localDev/LocalDevProcess.js +201 -0
  308. package/lib/projects/localDev/LocalDevState.d.ts +50 -0
  309. package/lib/projects/localDev/LocalDevState.js +119 -0
  310. package/lib/projects/localDev/LocalDevWatcher.d.ts +10 -0
  311. package/lib/projects/localDev/LocalDevWatcher.js +53 -0
  312. package/lib/projects/localDev/LocalDevWebsocketServer.d.ts +20 -0
  313. package/lib/projects/localDev/LocalDevWebsocketServer.js +131 -0
  314. package/lib/{localDev.d.ts → projects/localDev/helpers.d.ts} +6 -4
  315. package/lib/{localDev.js → projects/localDev/helpers.js} +127 -114
  316. package/lib/projects/ui.d.ts +1 -0
  317. package/lib/projects/ui.js +15 -0
  318. package/lib/projects/upload.d.ts +17 -2
  319. package/lib/projects/upload.js +74 -50
  320. package/lib/projects/urls.d.ts +4 -0
  321. package/lib/projects/urls.js +23 -1
  322. package/lib/projects/watch.d.ts +1 -1
  323. package/lib/projects/watch.js +21 -18
  324. package/lib/prompts/accountNamePrompt.js +16 -13
  325. package/lib/prompts/accountsPrompt.js +1 -2
  326. package/lib/prompts/cmsFieldPrompt.js +1 -2
  327. package/lib/prompts/createApiSamplePrompt.d.ts +2 -10
  328. package/lib/prompts/createApiSamplePrompt.js +4 -5
  329. package/lib/prompts/createFunctionPrompt.js +13 -14
  330. package/lib/prompts/createModulePrompt.js +8 -9
  331. package/lib/prompts/createProjectPrompt.d.ts +20 -4
  332. package/lib/prompts/createProjectPrompt.js +43 -13
  333. package/lib/prompts/createTemplatePrompt.d.ts +22 -4
  334. package/lib/prompts/createTemplatePrompt.js +1 -2
  335. package/lib/prompts/downloadProjectPrompt.js +3 -4
  336. package/lib/prompts/installAppPrompt.d.ts +2 -0
  337. package/lib/prompts/installAppPrompt.js +45 -0
  338. package/lib/prompts/personalAccessKeyPrompt.js +35 -25
  339. package/lib/prompts/previewPrompt.js +5 -6
  340. package/lib/prompts/projectAddPrompt.d.ts +5 -1
  341. package/lib/prompts/projectAddPrompt.js +35 -8
  342. package/lib/prompts/projectDevTargetAccountPrompt.d.ts +6 -1
  343. package/lib/prompts/projectDevTargetAccountPrompt.js +15 -16
  344. package/lib/prompts/projectNamePrompt.js +5 -6
  345. package/lib/prompts/projectsLogsPrompt.js +3 -2
  346. package/lib/prompts/promptUtils.d.ts +4 -2
  347. package/lib/prompts/promptUtils.js +3 -1
  348. package/lib/prompts/sandboxesPrompt.js +5 -6
  349. package/lib/prompts/secretPrompt.js +2 -3
  350. package/lib/prompts/selectAppPrompt.d.ts +2 -0
  351. package/lib/prompts/selectAppPrompt.js +40 -0
  352. package/lib/prompts/selectHubDBTablePrompt.js +11 -8
  353. package/lib/prompts/{selectPublicAppPrompt.d.ts → selectPublicAppForMigrationPrompt.d.ts} +1 -1
  354. package/lib/prompts/{selectPublicAppPrompt.js → selectPublicAppForMigrationPrompt.js} +8 -9
  355. package/lib/prompts/setAsDefaultAccountPrompt.js +11 -2
  356. package/lib/prompts/uploadPrompt.js +4 -5
  357. package/lib/sandboxSync.js +15 -14
  358. package/lib/sandboxes.js +12 -13
  359. package/lib/serverlessLogs.js +4 -6
  360. package/lib/testUtils.d.ts +3 -3
  361. package/lib/testUtils.js +8 -9
  362. package/lib/ui/boxen.d.ts +5 -0
  363. package/lib/ui/boxen.js +30 -0
  364. package/lib/ui/git.js +8 -9
  365. package/lib/ui/index.d.ts +4 -2
  366. package/lib/ui/index.js +20 -17
  367. package/lib/ui/logger.d.ts +10 -0
  368. package/lib/ui/logger.js +15 -0
  369. package/lib/ui/serverlessFunctionLogs.js +2 -3
  370. package/lib/upload.d.ts +1 -1
  371. package/lib/validation.js +4 -5
  372. package/lib/yargsUtils.d.ts +5 -1
  373. package/lib/yargsUtils.js +6 -0
  374. package/mcp-server/server.d.ts +1 -0
  375. package/mcp-server/server.js +18 -0
  376. package/mcp-server/tools/index.d.ts +2 -0
  377. package/mcp-server/tools/index.js +17 -0
  378. package/mcp-server/tools/project/AddFeatureToProject.d.ts +29 -0
  379. package/mcp-server/tools/project/AddFeatureToProject.js +85 -0
  380. package/mcp-server/tools/project/CreateProjectTool.d.ts +35 -0
  381. package/mcp-server/tools/project/CreateProjectTool.js +100 -0
  382. package/mcp-server/tools/project/DeployProject.d.ts +20 -0
  383. package/mcp-server/tools/project/DeployProject.js +50 -0
  384. package/mcp-server/tools/project/GuidedWalkthroughTool.d.ts +17 -0
  385. package/mcp-server/tools/project/GuidedWalkthroughTool.js +58 -0
  386. package/mcp-server/tools/project/UploadProjectTools.d.ts +17 -0
  387. package/mcp-server/tools/project/UploadProjectTools.js +35 -0
  388. package/mcp-server/tools/project/constants.d.ts +3 -0
  389. package/mcp-server/tools/project/constants.js +13 -0
  390. package/mcp-server/types.d.ts +14 -0
  391. package/mcp-server/types.js +17 -0
  392. package/mcp-server/utils/command.d.ts +3 -0
  393. package/mcp-server/utils/command.js +16 -0
  394. package/mcp-server/utils/content.d.ts +3 -0
  395. package/mcp-server/utils/content.js +21 -0
  396. package/mcp-server/utils/project.d.ts +5 -0
  397. package/mcp-server/utils/project.js +17 -0
  398. package/package.json +19 -11
  399. package/types/Cms.d.ts +30 -0
  400. package/types/Cms.js +2 -0
  401. package/types/LocalDev.d.ts +35 -0
  402. package/types/LocalDev.js +2 -0
  403. package/types/Projects.d.ts +19 -2
  404. package/types/Prompts.d.ts +0 -7
  405. package/types/Yargs.d.ts +14 -14
  406. package/lib/DevServerManagerV2.d.ts +0 -33
  407. package/lib/LocalDevManagerV2.d.ts +0 -64
  408. package/lib/LocalDevManagerV2.js +0 -377
  409. package/lib/projects/create.d.ts +0 -5
  410. package/lib/projects/index.d.ts +0 -21
  411. package/lib/projects/index.js +0 -194
  412. package/lib/prompts/installPublicAppPrompt.d.ts +0 -1
  413. package/lib/prompts/installPublicAppPrompt.js +0 -40
@@ -0,0 +1,17 @@
1
+ import { TextContentResponse, Tool } from '../../types';
2
+ import { McpServer, RegisteredTool } from '@modelcontextprotocol/sdk/server/mcp.js';
3
+ import { z } from 'zod';
4
+ declare const inputSchemaZodObject: z.ZodObject<{
5
+ command: z.ZodOptional<z.ZodUnion<[z.ZodLiteral<"hs init">, z.ZodLiteral<"hs auth">, z.ZodLiteral<"hs project create">, z.ZodLiteral<"hs project upload">]>>;
6
+ }, "strip", z.ZodTypeAny, {
7
+ command?: "hs auth" | "hs project upload" | "hs project create" | "hs init" | undefined;
8
+ }, {
9
+ command?: "hs auth" | "hs project upload" | "hs project create" | "hs init" | undefined;
10
+ }>;
11
+ type InputSchemaType = z.infer<typeof inputSchemaZodObject>;
12
+ export declare class GuidedWalkthroughTool extends Tool<InputSchemaType> {
13
+ constructor(mcpServer: McpServer);
14
+ handler({ command }: InputSchemaType): Promise<TextContentResponse>;
15
+ register(): RegisteredTool;
16
+ }
17
+ export {};
@@ -0,0 +1,58 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.GuidedWalkthroughTool = void 0;
4
+ const types_1 = require("../../types");
5
+ const zod_1 = require("zod");
6
+ const command_1 = require("../../utils/command");
7
+ const content_1 = require("../../utils/content");
8
+ const nextCommands = {
9
+ 'hs init': 'hs auth',
10
+ 'hs auth': 'hs project create',
11
+ 'hs project create': 'hs project upload',
12
+ 'hs project upload': 'hs project dev',
13
+ };
14
+ const inputSchema = {
15
+ command: zod_1.z
16
+ .union([
17
+ zod_1.z.literal('hs init'),
18
+ zod_1.z.literal('hs auth'),
19
+ zod_1.z.literal('hs project create'),
20
+ zod_1.z.literal('hs project upload'),
21
+ ])
22
+ .describe('The command to learn more about. Start with `hs init`')
23
+ .optional(),
24
+ };
25
+ // eslint-disable-next-line @typescript-eslint/no-unused-vars
26
+ const inputSchemaZodObject = zod_1.z.object({
27
+ ...inputSchema,
28
+ });
29
+ class GuidedWalkthroughTool extends types_1.Tool {
30
+ constructor(mcpServer) {
31
+ super(mcpServer);
32
+ }
33
+ async handler({ command }) {
34
+ if (command) {
35
+ const { stdout } = await (0, command_1.execAsync)(`${command} --help`);
36
+ return (0, content_1.formatTextContents)(`Display this help output for the user amd wait for them to acknowledge: ${stdout}. ${nextCommands[command] ? `Once they are ready, A good command to look at next is ${nextCommands[command]}` : ''}`);
37
+ }
38
+ return (0, content_1.formatTextContents)('Is there another command you would like to learn more about?');
39
+ }
40
+ register() {
41
+ return this.mcpServer.registerTool('guided-walkthrough-hubspot-cli', {
42
+ title: 'Guided walkthrough of the CLI',
43
+ description: 'Give the user a guided walkthrough of the HubSpot CLI.',
44
+ inputSchema: {
45
+ command: zod_1.z
46
+ .union([
47
+ zod_1.z.literal('hs init'),
48
+ zod_1.z.literal('hs auth'),
49
+ zod_1.z.literal('hs project create'),
50
+ zod_1.z.literal('hs project upload'),
51
+ ])
52
+ .describe('The command to learn more about. Start with `hs init`')
53
+ .optional(),
54
+ },
55
+ }, this.handler);
56
+ }
57
+ }
58
+ exports.GuidedWalkthroughTool = GuidedWalkthroughTool;
@@ -0,0 +1,17 @@
1
+ import { TextContentResponse, Tool } from '../../types';
2
+ import { McpServer, RegisteredTool } from '@modelcontextprotocol/sdk/server/mcp.js';
3
+ import z from 'zod';
4
+ declare const inputSchemaZodObject: z.ZodObject<{
5
+ absoluteProjectPath: z.ZodString;
6
+ }, "strip", z.ZodTypeAny, {
7
+ absoluteProjectPath: string;
8
+ }, {
9
+ absoluteProjectPath: string;
10
+ }>;
11
+ type InputSchemaType = z.infer<typeof inputSchemaZodObject>;
12
+ export declare class UploadProjectTools extends Tool<InputSchemaType> {
13
+ constructor(mcpServer: McpServer);
14
+ handler({ absoluteProjectPath, }: InputSchemaType): Promise<TextContentResponse>;
15
+ register(): RegisteredTool;
16
+ }
17
+ export {};
@@ -0,0 +1,35 @@
1
+ "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ exports.UploadProjectTools = void 0;
7
+ const types_1 = require("../../types");
8
+ const project_1 = require("../../utils/project");
9
+ const constants_1 = require("./constants");
10
+ const zod_1 = __importDefault(require("zod"));
11
+ const content_1 = require("../../utils/content");
12
+ const inputSchema = {
13
+ absoluteProjectPath: constants_1.absoluteProjectPath,
14
+ };
15
+ // eslint-disable-next-line @typescript-eslint/no-unused-vars
16
+ const inputSchemaZodObject = zod_1.default.object({
17
+ ...inputSchema,
18
+ });
19
+ class UploadProjectTools extends types_1.Tool {
20
+ constructor(mcpServer) {
21
+ super(mcpServer);
22
+ }
23
+ async handler({ absoluteProjectPath, }) {
24
+ const { stdout, stderr } = await (0, project_1.runCommandInDir)(absoluteProjectPath, `hs project upload --force-create`);
25
+ return (0, content_1.formatTextContents)(stdout, stderr);
26
+ }
27
+ register() {
28
+ return this.mcpServer.registerTool('upload-hubspot-project', {
29
+ title: 'Upload HubSpot Project',
30
+ description: 'Uploads the HubSpot project in current working directory. If the project does not exist, it will be created. MUST be ran from within the project directory.',
31
+ inputSchema,
32
+ }, this.handler);
33
+ }
34
+ }
35
+ exports.UploadProjectTools = UploadProjectTools;
@@ -0,0 +1,3 @@
1
+ import z from 'zod';
2
+ export declare const absoluteProjectPath: z.ZodString;
3
+ export declare const absoluteCurrentWorkingDirectory: z.ZodString;
@@ -0,0 +1,13 @@
1
+ "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ exports.absoluteCurrentWorkingDirectory = exports.absoluteProjectPath = void 0;
7
+ const zod_1 = __importDefault(require("zod"));
8
+ exports.absoluteProjectPath = zod_1.default
9
+ .string()
10
+ .describe('The absolute path to the project directory.');
11
+ exports.absoluteCurrentWorkingDirectory = zod_1.default
12
+ .string()
13
+ .describe('The absolute path to the current working directory.');
@@ -0,0 +1,14 @@
1
+ import { McpServer, RegisteredTool } from '@modelcontextprotocol/sdk/server/mcp.js';
2
+ export declare class Tool<InputSchema, ResponseType = TextContentResponse> {
3
+ protected mcpServer: McpServer;
4
+ constructor(mcpServer: McpServer);
5
+ register(): RegisteredTool;
6
+ handler(input: InputSchema): ResponseType | Promise<ResponseType>;
7
+ }
8
+ export type TextContent = {
9
+ type: 'text';
10
+ text: string;
11
+ };
12
+ export type TextContentResponse = {
13
+ content: TextContent[];
14
+ };
@@ -0,0 +1,17 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.Tool = void 0;
4
+ class Tool {
5
+ mcpServer;
6
+ constructor(mcpServer) {
7
+ this.mcpServer = mcpServer;
8
+ }
9
+ register() {
10
+ throw new Error('Must implement register');
11
+ }
12
+ // eslint-disable-next-line @typescript-eslint/no-unused-vars
13
+ handler(input) {
14
+ throw new Error('Must implement handler');
15
+ }
16
+ }
17
+ exports.Tool = Tool;
@@ -0,0 +1,3 @@
1
+ import { exec } from 'child_process';
2
+ export declare const execAsync: typeof exec.__promisify__;
3
+ export declare function addFlag(command: string, flagName: string, value: string | number | boolean | string[]): string;
@@ -0,0 +1,16 @@
1
+ "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ exports.execAsync = void 0;
7
+ exports.addFlag = addFlag;
8
+ const util_1 = __importDefault(require("util"));
9
+ const child_process_1 = require("child_process");
10
+ exports.execAsync = util_1.default.promisify(child_process_1.exec);
11
+ function addFlag(command, flagName, value) {
12
+ if (Array.isArray(value)) {
13
+ return `${command} --${flagName} ${value.map(item => `"${item}"`).join(' ')}`;
14
+ }
15
+ return `${command} --${flagName} "${value}"`;
16
+ }
@@ -0,0 +1,3 @@
1
+ import { TextContent, TextContentResponse } from '../types';
2
+ export declare function formatTextContents(...outputs: (string | undefined)[]): TextContentResponse;
3
+ export declare function formatTextContent(text: string): TextContent;
@@ -0,0 +1,21 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.formatTextContents = formatTextContents;
4
+ exports.formatTextContent = formatTextContent;
5
+ function formatTextContents(...outputs) {
6
+ const content = [];
7
+ outputs.forEach(output => {
8
+ if (output !== undefined) {
9
+ content.push(formatTextContent(output));
10
+ }
11
+ });
12
+ return {
13
+ content,
14
+ };
15
+ }
16
+ function formatTextContent(text) {
17
+ return {
18
+ type: 'text',
19
+ text,
20
+ };
21
+ }
@@ -0,0 +1,5 @@
1
+ export interface CommandResults {
2
+ stderr: string;
3
+ stdout: string;
4
+ }
5
+ export declare function runCommandInDir(directory: string, command: string): Promise<CommandResults>;
@@ -0,0 +1,17 @@
1
+ "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ exports.runCommandInDir = runCommandInDir;
7
+ const command_1 = require("./command");
8
+ const path_1 = __importDefault(require("path"));
9
+ const fs_1 = __importDefault(require("fs"));
10
+ async function runCommandInDir(directory, command) {
11
+ if (!fs_1.default.existsSync(directory)) {
12
+ fs_1.default.mkdirSync(directory);
13
+ }
14
+ return (0, command_1.execAsync)(command, {
15
+ cwd: path_1.default.resolve(directory),
16
+ });
17
+ }
package/package.json CHANGED
@@ -1,16 +1,17 @@
1
1
  {
2
2
  "name": "@hubspot/cli",
3
- "version": "7.5.2-experimental.0",
3
+ "version": "7.5.3-beta.0",
4
4
  "description": "The official CLI for developing on HubSpot",
5
5
  "license": "Apache-2.0",
6
6
  "repository": "https://github.com/HubSpot/hubspot-cli",
7
7
  "dependencies": {
8
- "@hubspot/local-dev-lib": "3.5.1",
9
- "@hubspot/project-parsing-lib": "0.1.6",
10
- "@hubspot/serverless-dev-runtime": "7.0.2",
8
+ "@hubspot/local-dev-lib": "3.9.0",
9
+ "@hubspot/project-parsing-lib": "0.3.2",
10
+ "@hubspot/serverless-dev-runtime": "7.0.6",
11
11
  "@hubspot/theme-preview-dev-server": "0.0.10",
12
- "@hubspot/ui-extensions-dev-server": "0.8.52",
12
+ "@hubspot/ui-extensions-dev-server": "0.9.2",
13
13
  "archiver": "7.0.1",
14
+ "boxen": "8.0.1",
14
15
  "chalk": "4.1.2",
15
16
  "chokidar": "3.6.0",
16
17
  "cli-cursor": "3.1.0",
@@ -27,6 +28,7 @@
27
28
  "table": "6.9.0",
28
29
  "tmp": "0.2.3",
29
30
  "update-notifier": "5.1.0",
31
+ "ws": "^8.18.2",
30
32
  "yargs": "17.7.2",
31
33
  "yargs-parser": "21.1.1"
32
34
  },
@@ -40,10 +42,11 @@
40
42
  "@types/js-yaml": "^4.0.9",
41
43
  "@types/semver": "^7.5.8",
42
44
  "@types/tmp": "^0.2.6",
45
+ "@types/ws": "^8.18.1",
43
46
  "@types/yargs": "^17.0.33",
44
- "@typescript-eslint/eslint-plugin": "^8.11.0",
47
+ "@typescript-eslint/eslint-plugin": "^8.30.1",
45
48
  "@typescript-eslint/parser": "^8.11.0",
46
- "axios": "^1.7.2",
49
+ "axios": "^1.7.4",
47
50
  "eslint": "^8.56.0",
48
51
  "eslint-plugin-import": "^2.31.0",
49
52
  "husky": "^4.3.8",
@@ -58,14 +61,18 @@
58
61
  "typescript": "^5.6.2"
59
62
  },
60
63
  "optionalDependencies": {
61
- "@hubspot/cms-dev-server": "^1.0.9"
64
+ "@hubspot/cms-dev-server": "^1.0.9",
65
+ "@modelcontextprotocol/sdk": "1.13.3"
62
66
  },
63
67
  "scripts": {
64
68
  "build": "ts-node ./scripts/build.ts",
65
- "lint": "eslint . && prettier --list-different './**/*.{ts,js,json}'",
69
+ "debug-mcp": "yarn build && npx @modelcontextprotocol/inspector node dist/mcp-server/server.js",
70
+ "lint": "echo 'Linting is disabled for Blazar'",
71
+ "lint:local": "eslint . && prettier --list-different './**/*.{ts,js,json}'",
66
72
  "list-all-commands": "yarn ts-node ./scripts/get-all-commands.ts",
73
+ "local-link": "yarn ts-node ./scripts/linking.ts",
67
74
  "prettier:write": "prettier --write './**/*.{ts,js,json}'",
68
- "test": "yarn node --experimental-vm-modules $(yarn bin jest)",
75
+ "test": "node --experimental-vm-modules ./node_modules/jest/bin/jest.js",
69
76
  "test-cli": "yarn build && yarn --cwd 'acceptance-tests' test-ci",
70
77
  "test-cli-debug": "yarn build && yarn --cwd 'acceptance-tests' test-debug",
71
78
  "test-cli-qa": "yarn build && yarn --cwd 'acceptance-tests' test-qa",
@@ -75,7 +82,8 @@
75
82
  "release": "yarn ts-node ./scripts/release.ts release",
76
83
  "hs": "yarn build && node ./dist/bin/hs",
77
84
  "hs-debug": "yarn build && NODE_DEBUG=http* node --inspect-brk ./dist/bin/hs",
78
- "update-ldl": "yarn add --exact @hubspot/local-dev-lib@latest"
85
+ "update-ldl": "yarn add --exact @hubspot/local-dev-lib@latest",
86
+ "view-unreleased-changes": "node ./scripts/unreleasedChanges.js"
79
87
  },
80
88
  "lint-staged": {
81
89
  "**/*.{js,ts,scss,css}": [
package/types/Cms.d.ts ADDED
@@ -0,0 +1,30 @@
1
+ import { CommonArgs, ConfigArgs } from './Yargs';
2
+ export type CreateArgs = CommonArgs & ConfigArgs & {
3
+ branch?: string;
4
+ type: string;
5
+ dest: string;
6
+ name: string;
7
+ internal?: boolean;
8
+ };
9
+ export type CmsAssetOperationArgs = {
10
+ assetType: string;
11
+ name: string;
12
+ dest: string;
13
+ getInternalVersion: boolean;
14
+ commandArgs: CreateArgs;
15
+ };
16
+ export type CreatableCmsAsset = {
17
+ hidden: boolean;
18
+ dest: (args: CmsAssetOperationArgs) => string;
19
+ validate?: (args: CmsAssetOperationArgs) => boolean;
20
+ execute: (args: CmsAssetOperationArgs) => Promise<void>;
21
+ };
22
+ export type ApiSampleChoice = {
23
+ name: string;
24
+ description: string;
25
+ id: string;
26
+ languages: string[];
27
+ };
28
+ export type ApiSampleConfig = {
29
+ samples: ApiSampleChoice[];
30
+ };
package/types/Cms.js ADDED
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,35 @@
1
+ import { IntermediateRepresentationNodeLocalDev } from '@hubspot/project-parsing-lib/src/lib/types';
2
+ import { Build } from '@hubspot/local-dev-lib/types/Build';
3
+ import { Environment } from '@hubspot/local-dev-lib/types/Config';
4
+ import { ValueOf } from '@hubspot/local-dev-lib/types/Utils';
5
+ import { ProjectConfig } from './Projects';
6
+ import LocalDevState from '../lib/projects/localDev/LocalDevState';
7
+ import { APP_INSTALLATION_STATES, LOCAL_DEV_SERVER_MESSAGE_TYPES } from '../lib/constants';
8
+ export type LocalDevStateConstructorOptions = {
9
+ targetProjectAccountId: number;
10
+ targetTestingAccountId: number;
11
+ projectConfig: ProjectConfig;
12
+ projectDir: string;
13
+ projectId: number;
14
+ projectName: string;
15
+ debug?: boolean;
16
+ deployedBuild?: Build;
17
+ isGithubLinked: boolean;
18
+ initialProjectNodes: {
19
+ [key: string]: IntermediateRepresentationNodeLocalDev;
20
+ };
21
+ env: Environment;
22
+ };
23
+ export type LocalDevWebsocketMessage = {
24
+ type: string;
25
+ data?: unknown;
26
+ };
27
+ export type LocalDevStateListener<K extends keyof LocalDevState> = (value: LocalDevState[K]) => void;
28
+ export type AppLocalDevData = {
29
+ id: number;
30
+ clientId: string;
31
+ name: string;
32
+ installationState: ValueOf<typeof APP_INSTALLATION_STATES>;
33
+ scopeGroupIds: number[];
34
+ };
35
+ export type LocalDevServerMessage = ValueOf<typeof LOCAL_DEV_SERVER_MESSAGE_TYPES>;
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,15 +1,23 @@
1
1
  import { Build, SubbuildStatus } from '@hubspot/local-dev-lib/types/Build';
2
2
  import { Deploy, SubdeployStatus } from '@hubspot/local-dev-lib/types/Deploy';
3
+ import { appComponent, marketplaceDistribution, oAuth, privateDistribution, staticAuth } from '../lib/constants';
3
4
  export type ProjectTemplate = {
4
5
  name: string;
5
6
  label: string;
6
7
  path: string;
7
- insertPath: string;
8
8
  };
9
9
  export type ComponentTemplate = {
10
10
  path: string;
11
11
  label: string;
12
- insertPath: string;
12
+ type: string;
13
+ parentComponent?: string;
14
+ supportedAuthTypes?: string[];
15
+ supportedDistributions?: string[];
16
+ };
17
+ export type ComponentTemplateChoice = {
18
+ name: string;
19
+ value: ComponentTemplate;
20
+ disabled?: string | boolean;
13
21
  };
14
22
  export type ProjectConfig = {
15
23
  name: string;
@@ -32,9 +40,18 @@ export type ProjectPollStatusFunctionText = {
32
40
  TYPE_KEY: string;
33
41
  SUBTASK_NAME_KEY: string;
34
42
  };
43
+ export type ParentComponent = {
44
+ label: string;
45
+ type: typeof appComponent;
46
+ authType: typeof staticAuth | typeof oAuth;
47
+ distribution: typeof privateDistribution | typeof marketplaceDistribution;
48
+ path: string;
49
+ };
35
50
  export type ProjectTemplateRepoConfig = {
36
51
  projects?: ProjectTemplate[];
37
52
  components?: ComponentTemplate[];
53
+ defaultFiles?: string;
54
+ parentComponents?: ParentComponent[];
38
55
  };
39
56
  export type ProjectPollResult = {
40
57
  succeeded: boolean;
@@ -1,4 +1,3 @@
1
- import { DeveloperTestAccount } from '@hubspot/local-dev-lib/types/developerTestAccounts';
2
1
  export type GenericPromptResponse = {
3
2
  [key: string]: any;
4
3
  };
@@ -23,10 +22,4 @@ export type PromptConfig<T extends GenericPromptResponse> = {
23
22
  mask?: string;
24
23
  filter?: (input: string) => string;
25
24
  };
26
- export type ProjectDevTargetAccountPromptResponse = {
27
- targetAccountId: number | null;
28
- createNestedAccount: boolean;
29
- parentAccountId?: number | null;
30
- notInConfigAccount?: DeveloperTestAccount | null;
31
- };
32
25
  export {};
package/types/Yargs.d.ts CHANGED
@@ -1,4 +1,5 @@
1
- import { Options } from 'yargs';
1
+ import { Options, CommandModule, Argv } from 'yargs';
2
+ import { CmsPublishMode } from '@hubspot/local-dev-lib/types/Files';
2
3
  export type CommonArgs = {
3
4
  derivedAccountId: number;
4
5
  providedAccountId?: number;
@@ -23,20 +24,19 @@ export type OverwriteArgs = Options & {
23
24
  export type StringArgType = Options & {
24
25
  type: 'string';
25
26
  };
26
- export type ProjectDevArgs = CommonArgs & ConfigArgs & EnvironmentArgs;
27
+ export type ProjectDevArgs = CommonArgs & ConfigArgs & EnvironmentArgs & {
28
+ profile?: string;
29
+ testingAccount?: string | number;
30
+ projectAccount?: string | number;
31
+ };
27
32
  export type TestingArgs = {
28
33
  qa?: boolean;
29
34
  };
30
- export type MigrateAppOptions = CommonArgs & AccountArgs & EnvironmentArgs & ConfigArgs & {
31
- name?: string;
32
- dest?: string;
33
- appId?: number;
34
- platformVersion: string;
35
- };
36
- export type ProjectMigrateOptions = CommonArgs & AccountArgs & EnvironmentArgs & ConfigArgs & {
37
- dest?: string;
38
- };
39
- export type CloneAppArgs = ConfigArgs & EnvironmentArgs & AccountArgs & CommonArgs & {
40
- dest: string;
41
- appId: number;
35
+ export type CmsPublishModeArgs = {
36
+ 'cms-publish-mode'?: CmsPublishMode;
37
+ m?: CmsPublishMode;
42
38
  };
39
+ export interface YargsCommandModule<T, U> extends CommandModule<T, U> {
40
+ builder: (yargs: Argv) => Promise<Argv<U>>;
41
+ }
42
+ export type YargsCommandModuleBucket = YargsCommandModule<unknown, object>;
@@ -1,33 +0,0 @@
1
- import { ProjectConfig } from '../types/Projects';
2
- import { IntermediateRepresentationNodeLocalDev } from '@hubspot/project-parsing-lib/src/lib/types';
3
- type DevServerInterface = {
4
- setup?: Function;
5
- start?: (options: object) => Promise<void>;
6
- fileChange?: (filePath: string, event: string) => Promise<void>;
7
- cleanup?: () => Promise<void>;
8
- };
9
- declare class DevServerManagerV2 {
10
- private initialized;
11
- private started;
12
- private devServers;
13
- constructor();
14
- iterateDevServers(callback: (serverInterface: DevServerInterface) => Promise<void>): Promise<void>;
15
- setup({ projectNodes, accountId, setActiveApp, }: {
16
- projectNodes: {
17
- [key: string]: IntermediateRepresentationNodeLocalDev;
18
- };
19
- accountId: number;
20
- setActiveApp: (appUid: string | undefined) => Promise<void>;
21
- }): Promise<void>;
22
- start({ accountId, projectConfig, }: {
23
- accountId: number;
24
- projectConfig: ProjectConfig;
25
- }): Promise<void>;
26
- fileChange({ filePath, event, }: {
27
- filePath: string;
28
- event: string;
29
- }): Promise<void>;
30
- cleanup(): Promise<void>;
31
- }
32
- declare const Manager: DevServerManagerV2;
33
- export default Manager;
@@ -1,64 +0,0 @@
1
- import { FSWatcher } from 'chokidar';
2
- import { Build } from '@hubspot/local-dev-lib/types/Build';
3
- import { PublicApp } from '@hubspot/local-dev-lib/types/Apps';
4
- import { Environment } from '@hubspot/local-dev-lib/types/Config';
5
- import { ProjectConfig } from '../types/Projects';
6
- import { IntermediateRepresentationNodeLocalDev } from '@hubspot/project-parsing-lib/src/lib/types';
7
- import { AppIRNode } from '../types/ProjectComponents';
8
- type LocalDevManagerConstructorOptions = {
9
- targetProjectAccountId: number;
10
- targetTestingAccountId: number;
11
- projectConfig: ProjectConfig;
12
- projectDir: string;
13
- projectId: number;
14
- debug?: boolean;
15
- deployedBuild?: Build;
16
- isGithubLinked: boolean;
17
- projectNodes: {
18
- [key: string]: IntermediateRepresentationNodeLocalDev;
19
- };
20
- env: Environment;
21
- };
22
- declare class LocalDevManagerV2 {
23
- targetProjectAccountId: number;
24
- targetTestingAccountId: number;
25
- projectConfig: ProjectConfig;
26
- projectDir: string;
27
- projectId: number;
28
- debug: boolean;
29
- deployedBuild?: Build;
30
- isGithubLinked: boolean;
31
- watcher: FSWatcher | null;
32
- uploadWarnings: {
33
- [key: string]: boolean;
34
- };
35
- projectNodes: {
36
- [key: string]: IntermediateRepresentationNodeLocalDev;
37
- };
38
- activeApp: AppIRNode | null;
39
- activePublicAppData: PublicApp | null;
40
- env: Environment;
41
- publicAppActiveInstalls: number | null;
42
- projectSourceDir: string;
43
- mostRecentUploadWarning: string | null;
44
- constructor(options: LocalDevManagerConstructorOptions);
45
- setActiveApp(appUid?: string): Promise<void>;
46
- setActivePublicAppData(): Promise<void>;
47
- checkActivePublicAppInstalls(): Promise<void>;
48
- start(): Promise<void>;
49
- stop(showProgress?: boolean): Promise<void>;
50
- checkPublicAppInstallation(): Promise<void>;
51
- updateKeypressListeners(): void;
52
- getUploadCommand(): string;
53
- logUploadWarning(reason?: string): void;
54
- monitorConsoleOutput(): void;
55
- compareLocalProjectToDeployed(): void;
56
- startWatching(): void;
57
- stopWatching(): Promise<void>;
58
- handleWatchEvent(filePath: string, event: string, configPaths: string[]): void;
59
- devServerSetup(): Promise<boolean>;
60
- devServerStart(): Promise<void>;
61
- devServerFileChange(filePath: string, event: string): void;
62
- devServerCleanup(): Promise<boolean>;
63
- }
64
- export default LocalDevManagerV2;