@hubspot/cli 6.2.2-experimental.0 → 6.3.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 (335) hide show
  1. package/LICENSE +12 -0
  2. package/README.md +71 -0
  3. package/commands/accounts/clean.d.ts +1 -4
  4. package/commands/accounts/clean.js +2 -0
  5. package/commands/accounts/info.d.ts +1 -4
  6. package/commands/accounts/info.js +3 -1
  7. package/commands/accounts/list.d.ts +1 -4
  8. package/commands/accounts/list.js +2 -0
  9. package/commands/accounts/remove.d.ts +1 -4
  10. package/commands/accounts/remove.js +2 -0
  11. package/commands/accounts/rename.d.ts +1 -4
  12. package/commands/accounts/rename.js +2 -0
  13. package/commands/accounts/use.d.ts +1 -4
  14. package/commands/accounts/use.js +2 -0
  15. package/commands/accounts.d.ts +1 -3
  16. package/commands/accounts.js +2 -0
  17. package/commands/auth.d.ts +1 -4
  18. package/commands/auth.js +2 -2
  19. package/commands/cms/convertFields.d.ts +1 -4
  20. package/commands/cms/convertFields.js +2 -0
  21. package/commands/cms/lighthouseScore.d.ts +1 -4
  22. package/commands/cms/lighthouseScore.js +2 -0
  23. package/commands/cms/reactModules.d.ts +1 -4
  24. package/commands/cms/reactModules.js +2 -0
  25. package/commands/cms.d.ts +1 -3
  26. package/commands/cms.js +2 -0
  27. package/commands/config/set.d.ts +1 -4
  28. package/commands/config/set.js +3 -3
  29. package/commands/config.d.ts +1 -3
  30. package/commands/config.js +2 -0
  31. package/commands/create/api-sample.d.ts +1 -13
  32. package/commands/create/api-sample.js +4 -2
  33. package/commands/create/app.d.ts +1 -10
  34. package/commands/create/app.js +2 -0
  35. package/commands/create/function.d.ts +1 -6
  36. package/commands/create/function.js +2 -0
  37. package/commands/create/index.d.ts +1 -109
  38. package/commands/create/index.js +2 -0
  39. package/commands/create/module.d.ts +1 -11
  40. package/commands/create/module.js +2 -0
  41. package/commands/create/react-app.d.ts +1 -9
  42. package/commands/create/react-app.js +2 -0
  43. package/commands/create/template.d.ts +1 -12
  44. package/commands/create/template.js +2 -0
  45. package/commands/create/vue-app.d.ts +1 -9
  46. package/commands/create/vue-app.js +2 -0
  47. package/commands/create/webpack-serverless.d.ts +1 -9
  48. package/commands/create/webpack-serverless.js +2 -0
  49. package/commands/create/website-theme.d.ts +1 -9
  50. package/commands/create/website-theme.js +2 -0
  51. package/commands/create.d.ts +24 -4
  52. package/commands/create.js +4 -3
  53. package/commands/customObject/create.d.ts +1 -4
  54. package/commands/customObject/create.js +2 -0
  55. package/commands/customObject/schema/create.d.ts +1 -4
  56. package/commands/customObject/schema/create.js +2 -0
  57. package/commands/customObject/schema/delete.d.ts +1 -4
  58. package/commands/customObject/schema/delete.js +3 -1
  59. package/commands/customObject/schema/fetch-all.d.ts +1 -4
  60. package/commands/customObject/schema/fetch-all.js +2 -0
  61. package/commands/customObject/schema/fetch.d.ts +1 -4
  62. package/commands/customObject/schema/fetch.js +3 -1
  63. package/commands/customObject/schema/list.d.ts +1 -3
  64. package/commands/customObject/schema/list.js +2 -0
  65. package/commands/customObject/schema/update.d.ts +1 -4
  66. package/commands/customObject/schema/update.js +2 -0
  67. package/commands/customObject/schema.d.ts +1 -3
  68. package/commands/customObject/schema.js +2 -0
  69. package/commands/customObject.d.ts +1 -3
  70. package/commands/customObject.js +2 -0
  71. package/commands/feedback.d.ts +1 -4
  72. package/commands/feedback.js +21 -4
  73. package/commands/fetch.d.ts +1 -4
  74. package/commands/fetch.js +2 -0
  75. package/commands/filemanager/fetch.d.ts +1 -4
  76. package/commands/filemanager/fetch.js +4 -2
  77. package/commands/filemanager/upload.d.ts +1 -4
  78. package/commands/filemanager/upload.js +2 -0
  79. package/commands/filemanager.d.ts +1 -3
  80. package/commands/filemanager.js +2 -0
  81. package/commands/functions/deploy.d.ts +1 -4
  82. package/commands/functions/deploy.js +2 -0
  83. package/commands/functions/list.d.ts +1 -4
  84. package/commands/functions/list.js +13 -2
  85. package/commands/functions/server.d.ts +1 -4
  86. package/commands/functions/server.js +2 -0
  87. package/commands/functions.d.ts +1 -3
  88. package/commands/functions.js +2 -0
  89. package/commands/hubdb/clear.d.ts +1 -4
  90. package/commands/hubdb/clear.js +2 -0
  91. package/commands/hubdb/create.d.ts +1 -4
  92. package/commands/hubdb/create.js +2 -0
  93. package/commands/hubdb/delete.d.ts +1 -4
  94. package/commands/hubdb/delete.js +2 -0
  95. package/commands/hubdb/fetch.d.ts +1 -4
  96. package/commands/hubdb/fetch.js +2 -0
  97. package/commands/hubdb.d.ts +1 -3
  98. package/commands/hubdb.js +2 -0
  99. package/commands/init.d.ts +1 -4
  100. package/commands/init.js +2 -2
  101. package/commands/lint.d.ts +1 -4
  102. package/commands/lint.js +30 -1
  103. package/commands/list.d.ts +1 -4
  104. package/commands/list.js +2 -0
  105. package/commands/logs.d.ts +1 -4
  106. package/commands/logs.js +2 -0
  107. package/commands/module/marketplace-validate.d.ts +1 -4
  108. package/commands/module/marketplace-validate.js +3 -1
  109. package/commands/module.d.ts +1 -3
  110. package/commands/module.js +2 -0
  111. package/commands/mv.d.ts +1 -4
  112. package/commands/mv.js +2 -0
  113. package/commands/open.d.ts +1 -4
  114. package/commands/open.js +2 -0
  115. package/commands/project/add.d.ts +1 -4
  116. package/commands/project/add.js +2 -0
  117. package/commands/project/cloneApp.d.ts +1 -4
  118. package/commands/project/cloneApp.js +2 -0
  119. package/commands/project/create.d.ts +1 -4
  120. package/commands/project/create.js +2 -0
  121. package/commands/project/deploy.d.ts +1 -4
  122. package/commands/project/deploy.js +12 -3
  123. package/commands/project/dev.d.ts +1 -4
  124. package/commands/project/dev.js +3 -0
  125. package/commands/project/download.d.ts +1 -4
  126. package/commands/project/download.js +4 -2
  127. package/commands/project/installDeps.d.ts +1 -6
  128. package/commands/project/installDeps.js +2 -0
  129. package/commands/project/listBuilds.d.ts +1 -4
  130. package/commands/project/listBuilds.js +2 -0
  131. package/commands/project/logs.d.ts +1 -4
  132. package/commands/project/logs.js +3 -1
  133. package/commands/project/migrateApp.d.ts +1 -4
  134. package/commands/project/migrateApp.js +2 -0
  135. package/commands/project/open.d.ts +1 -4
  136. package/commands/project/open.js +2 -0
  137. package/commands/project/upload.d.ts +1 -4
  138. package/commands/project/upload.js +2 -0
  139. package/commands/project/watch.d.ts +1 -4
  140. package/commands/project/watch.js +2 -0
  141. package/commands/project.d.ts +1 -3
  142. package/commands/project.js +2 -0
  143. package/commands/remove.d.ts +1 -4
  144. package/commands/remove.js +2 -0
  145. package/commands/sandbox/create.d.ts +1 -4
  146. package/commands/sandbox/create.js +2 -0
  147. package/commands/sandbox/delete.d.ts +1 -4
  148. package/commands/sandbox/delete.js +7 -3
  149. package/commands/sandbox.d.ts +1 -3
  150. package/commands/sandbox.js +2 -0
  151. package/commands/secrets/addSecret.d.ts +1 -4
  152. package/commands/secrets/addSecret.js +2 -0
  153. package/commands/secrets/deleteSecret.d.ts +1 -4
  154. package/commands/secrets/deleteSecret.js +2 -0
  155. package/commands/secrets/listSecrets.d.ts +1 -4
  156. package/commands/secrets/listSecrets.js +2 -0
  157. package/commands/secrets/updateSecret.d.ts +1 -4
  158. package/commands/secrets/updateSecret.js +2 -0
  159. package/commands/secrets.d.ts +1 -3
  160. package/commands/secrets.js +2 -0
  161. package/commands/theme/generate-selectors.d.ts +1 -4
  162. package/commands/theme/generate-selectors.js +3 -1
  163. package/commands/theme/marketplace-validate.d.ts +1 -4
  164. package/commands/theme/marketplace-validate.js +3 -1
  165. package/commands/theme/preview.d.ts +1 -4
  166. package/commands/theme/preview.js +56 -46
  167. package/commands/theme.d.ts +1 -3
  168. package/commands/theme.js +2 -0
  169. package/commands/upload.d.ts +1 -4
  170. package/commands/upload.js +2 -0
  171. package/commands/watch.d.ts +1 -4
  172. package/commands/watch.js +2 -0
  173. package/lang/en.lyaml +8 -13
  174. package/lib/DevServerManager.d.ts +1 -35
  175. package/lib/DevServerManager.js +2 -0
  176. package/lib/LocalDevManager.d.ts +1 -41
  177. package/lib/LocalDevManager.js +5 -3
  178. package/lib/ProjectLogsManager.d.ts +1 -0
  179. package/lib/{projectLogsManager.js → ProjectLogsManager.js} +2 -0
  180. package/lib/accountTypes.d.ts +7 -6
  181. package/lib/accountTypes.js +31 -17
  182. package/lib/buildAccount.d.ts +1 -22
  183. package/lib/buildAccount.js +2 -0
  184. package/lib/commonOpts.d.ts +23 -17
  185. package/lib/commonOpts.js +73 -54
  186. package/lib/configOptions.d.ts +1 -0
  187. package/lib/configOptions.js +110 -0
  188. package/lib/constants.d.ts +76 -83
  189. package/lib/constants.js +21 -46
  190. package/lib/dependencyManagement.d.ts +1 -7
  191. package/lib/dependencyManagement.js +2 -0
  192. package/lib/developerTestAccounts.d.ts +1 -7
  193. package/lib/developerTestAccounts.js +2 -0
  194. package/lib/enums/exitCodes.d.ts +5 -5
  195. package/lib/enums/exitCodes.js +3 -2
  196. package/lib/errorHandlers/index.d.ts +1 -19
  197. package/lib/errorHandlers/index.js +2 -0
  198. package/lib/errorHandlers/suppressError.d.ts +1 -1
  199. package/lib/errorHandlers/suppressError.js +2 -0
  200. package/lib/filesystem.d.ts +2 -2
  201. package/lib/filesystem.js +12 -10
  202. package/lib/generateSelectors.d.ts +1 -0
  203. package/lib/{generate-selectors.js → generateSelectors.js} +3 -1
  204. package/lib/hasFeature.d.ts +1 -1
  205. package/lib/hasFeature.js +7 -8
  206. package/lib/hasFlag.d.ts +1 -2
  207. package/lib/hasFlag.js +7 -3
  208. package/lib/interpolation.d.ts +5 -10
  209. package/lib/interpolation.js +39 -45
  210. package/lib/lang.d.ts +9 -3
  211. package/lib/lang.js +38 -31
  212. package/lib/links.d.ts +1 -127
  213. package/lib/links.js +2 -0
  214. package/lib/localDev.d.ts +1 -11
  215. package/lib/localDev.js +2 -0
  216. package/lib/marketplaceValidate.d.ts +1 -0
  217. package/lib/{marketplace-validate.js → marketplaceValidate.js} +2 -0
  218. package/lib/oauth.d.ts +1 -1
  219. package/lib/oauth.js +3 -1
  220. package/lib/polling.d.ts +1 -1
  221. package/lib/polling.js +2 -0
  222. package/lib/process.d.ts +12 -2
  223. package/lib/process.js +17 -15
  224. package/lib/projectStructure.d.ts +1 -13
  225. package/lib/projectStructure.js +4 -2
  226. package/lib/projects.d.ts +1 -40
  227. package/lib/projects.js +10 -5
  228. package/lib/projectsWatch.d.ts +1 -1
  229. package/lib/projectsWatch.js +8 -3
  230. package/lib/prompts/accountNamePrompt.d.ts +1 -11
  231. package/lib/prompts/accountNamePrompt.js +3 -2
  232. package/lib/prompts/accountsPrompt.d.ts +1 -3
  233. package/lib/prompts/accountsPrompt.js +2 -17
  234. package/lib/prompts/cleanUploadPrompt.d.ts +1 -1
  235. package/lib/prompts/cleanUploadPrompt.js +2 -0
  236. package/lib/prompts/cmsFieldPrompt.d.ts +1 -1
  237. package/lib/prompts/cmsFieldPrompt.js +2 -0
  238. package/lib/prompts/createApiSamplePrompt.d.ts +1 -1
  239. package/lib/prompts/createApiSamplePrompt.js +2 -0
  240. package/lib/prompts/createFunctionPrompt.d.ts +1 -1
  241. package/lib/prompts/createFunctionPrompt.js +5 -4
  242. package/lib/prompts/createModulePrompt.d.ts +1 -1
  243. package/lib/prompts/createModulePrompt.js +2 -0
  244. package/lib/prompts/createProjectPrompt.d.ts +1 -1
  245. package/lib/prompts/createProjectPrompt.js +10 -5
  246. package/lib/prompts/createTemplatePrompt.d.ts +1 -1
  247. package/lib/prompts/createTemplatePrompt.js +2 -0
  248. package/lib/prompts/downloadProjectPrompt.d.ts +1 -1
  249. package/lib/prompts/downloadProjectPrompt.js +3 -1
  250. package/lib/prompts/installPublicAppPrompt.d.ts +1 -1
  251. package/lib/prompts/installPublicAppPrompt.js +2 -0
  252. package/lib/prompts/personalAccessKeyPrompt.d.ts +1 -69
  253. package/lib/prompts/personalAccessKeyPrompt.js +2 -0
  254. package/lib/prompts/previewPrompt.d.ts +1 -2
  255. package/lib/prompts/previewPrompt.js +2 -0
  256. package/lib/prompts/projectAddPrompt.d.ts +1 -1
  257. package/lib/prompts/projectAddPrompt.js +2 -0
  258. package/lib/prompts/projectDevTargetAccountPrompt.d.ts +1 -4
  259. package/lib/prompts/projectDevTargetAccountPrompt.js +2 -0
  260. package/lib/prompts/projectNamePrompt.d.ts +1 -1
  261. package/lib/prompts/projectNamePrompt.js +2 -0
  262. package/lib/prompts/projectsLogsPrompt.d.ts +1 -5
  263. package/lib/prompts/projectsLogsPrompt.js +2 -0
  264. package/lib/prompts/promptUtils.d.ts +12 -2
  265. package/lib/prompts/promptUtils.js +25 -12
  266. package/lib/prompts/sandboxesPrompt.d.ts +1 -2
  267. package/lib/prompts/sandboxesPrompt.js +2 -0
  268. package/lib/prompts/secretPrompt.d.ts +1 -1
  269. package/lib/prompts/secretPrompt.js +2 -0
  270. package/lib/prompts/selectPublicAppPrompt.d.ts +1 -5
  271. package/lib/prompts/selectPublicAppPrompt.js +3 -1
  272. package/lib/prompts/setAsDefaultAccountPrompt.d.ts +1 -1
  273. package/lib/prompts/setAsDefaultAccountPrompt.js +2 -0
  274. package/lib/prompts/uploadPrompt.d.ts +1 -1
  275. package/lib/prompts/uploadPrompt.js +2 -0
  276. package/lib/sandboxSync.d.ts +1 -8
  277. package/lib/sandboxSync.js +3 -1
  278. package/lib/sandboxes.d.ts +1 -40
  279. package/lib/sandboxes.js +2 -0
  280. package/lib/schema.d.ts +3 -2
  281. package/lib/schema.js +20 -18
  282. package/lib/serverlessLogs.d.ts +1 -8
  283. package/lib/serverlessLogs.js +3 -1
  284. package/lib/ui/SpinniesManager.d.ts +1 -61
  285. package/lib/ui/SpinniesManager.js +2 -0
  286. package/lib/ui/git.d.ts +1 -1
  287. package/lib/ui/git.js +2 -0
  288. package/lib/ui/index.d.ts +1 -36
  289. package/lib/ui/index.js +2 -0
  290. package/lib/ui/serverlessFunctionLogs.d.ts +1 -1
  291. package/lib/ui/serverlessFunctionLogs.js +2 -0
  292. package/lib/ui/spinniesUtils.d.ts +1 -60
  293. package/lib/ui/spinniesUtils.js +2 -0
  294. package/lib/ui/supportHyperlinks.d.ts +1 -3
  295. package/lib/ui/supportHyperlinks.js +3 -1
  296. package/lib/ui/supportsColor.d.ts +1 -13
  297. package/lib/ui/supportsColor.js +3 -1
  298. package/lib/ui/table.d.ts +1 -2
  299. package/lib/ui/table.js +2 -0
  300. package/lib/upload.d.ts +1 -1
  301. package/lib/upload.js +4 -2
  302. package/lib/usageTracking.d.ts +1 -6
  303. package/lib/usageTracking.js +12 -1
  304. package/lib/validation.d.ts +1 -16
  305. package/lib/validation.js +2 -2
  306. package/package.json +17 -9
  307. package/commands/config/set/allowUsageTracking.d.ts +0 -4
  308. package/commands/config/set/allowUsageTracking.js +0 -45
  309. package/commands/config/set/defaultMode.d.ts +0 -4
  310. package/commands/config/set/defaultMode.js +0 -48
  311. package/commands/config/set/httpTimeout.d.ts +0 -4
  312. package/commands/config/set/httpTimeout.js +0 -33
  313. package/lib/debugInfo.d.ts +0 -3
  314. package/lib/debugInfo.js +0 -18
  315. package/lib/environment.d.ts +0 -1
  316. package/lib/environment.js +0 -14
  317. package/lib/generate-selectors.d.ts +0 -6
  318. package/lib/getFunctionArrays.d.ts +0 -1
  319. package/lib/getFunctionArrays.js +0 -17
  320. package/lib/hublValidate.d.ts +0 -4
  321. package/lib/hublValidate.js +0 -28
  322. package/lib/interpolationHelpers.d.ts +0 -6
  323. package/lib/interpolationHelpers.js +0 -26
  324. package/lib/marketplace-validate.d.ts +0 -5
  325. package/lib/projectLogsManager.d.ts +0 -19
  326. package/lib/prompts/activeInstallConfirmationPrompt.d.ts +0 -1
  327. package/lib/prompts/activeInstallConfirmationPrompt.js +0 -18
  328. package/lib/prompts/deployBuildIdPrompt.d.ts +0 -1
  329. package/lib/prompts/deployBuildIdPrompt.js +0 -20
  330. package/lib/prompts/feedbackPrompt.d.ts +0 -2
  331. package/lib/prompts/feedbackPrompt.js +0 -37
  332. package/lib/prompts/folderOverwritePrompt.d.ts +0 -1
  333. package/lib/prompts/folderOverwritePrompt.js +0 -15
  334. package/lib/regex.d.ts +0 -1
  335. package/lib/regex.js +0 -5
@@ -1,4 +1,6 @@
1
1
  "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ // @ts-nocheck
2
4
  const { promptUser } = require('./promptUtils');
3
5
  const { i18n } = require('../lang');
4
6
  const { uiAccountDescription } = require('../ui');
@@ -1 +1 @@
1
- export function secretValuePrompt(): Promise<any>;
1
+ export {};
@@ -1,4 +1,6 @@
1
1
  "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ // @ts-nocheck
2
4
  const { promptUser } = require('./promptUtils');
3
5
  const { i18n } = require('../lang');
4
6
  const i18nKey = 'lib.prompts.secretPrompt';
@@ -1,5 +1 @@
1
- export function selectPublicAppPrompt({ accountId, accountName, isMigratingApp, }: {
2
- accountId: any;
3
- accountName: any;
4
- isMigratingApp?: boolean | undefined;
5
- }): Promise<any>;
1
+ export {};
@@ -1,11 +1,13 @@
1
1
  "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ // @ts-nocheck
2
4
  const { promptUser } = require('./promptUtils');
3
5
  const { i18n } = require('../lang');
4
6
  const { uiLine } = require('../ui');
5
7
  const { logError } = require('../errorHandlers/index');
6
8
  const { logger } = require('@hubspot/local-dev-lib/logger');
7
9
  const { fetchPublicAppsForPortal, } = require('@hubspot/local-dev-lib/api/appsDev');
8
- const { EXIT_CODES } = require('../../lib/enums/exitCodes');
10
+ const { EXIT_CODES } = require('../enums/exitCodes');
9
11
  const i18nKey = 'lib.prompts.selectPublicAppPrompt';
10
12
  const fetchPublicAppOptions = async (accountId, accountName, isMigratingApp = false) => {
11
13
  try {
@@ -1 +1 @@
1
- export function setAsDefaultAccountPrompt(accountName: any): Promise<any>;
1
+ export {};
@@ -1,4 +1,6 @@
1
1
  "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ // @ts-nocheck
2
4
  const { getConfig, updateDefaultAccount, } = require('@hubspot/local-dev-lib/config');
3
5
  const { promptUser } = require('./promptUtils');
4
6
  const { i18n } = require('../lang');
@@ -1 +1 @@
1
- export function uploadPrompt(promptOptions?: {}): Promise<any>;
1
+ export {};
@@ -1,4 +1,6 @@
1
1
  "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ // @ts-nocheck
2
4
  const path = require('path');
3
5
  const { getCwd } = require('@hubspot/local-dev-lib/path');
4
6
  const { promptUser } = require('./promptUtils');
@@ -1,8 +1 @@
1
- /**
2
- * @param {Object} accountConfig - Account config of sandbox portal
3
- * @param {Object} parentAccountConfig - Account config of parent portal
4
- * @param {String} env - Environment (QA/Prod)
5
- * @param {Array} syncTasks - Array of available sync tasks
6
- * @returns
7
- */
8
- export function syncSandbox({ accountConfig, parentAccountConfig, env, syncTasks, slimInfoMessage, }: Object): Promise<void>;
1
+ export {};
@@ -1,4 +1,6 @@
1
1
  "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ // @ts-nocheck
2
4
  const SpinniesManager = require('./ui/SpinniesManager');
3
5
  const { getHubSpotWebsiteOrigin } = require('@hubspot/local-dev-lib/urls');
4
6
  const { logger } = require('@hubspot/local-dev-lib/logger');
@@ -40,7 +42,7 @@ const syncSandbox = async ({ accountConfig, parentAccountConfig, env, syncTasks,
40
42
  text: i18n(`${i18nKey}.loading.startSync`),
41
43
  });
42
44
  await initiateSync(parentAccountId, accountId, availableSyncTasks, accountId);
43
- let spinniesText = isDevSandbox
45
+ const spinniesText = isDevSandbox
44
46
  ? `${i18nKey}.loading.succeedDevSb`
45
47
  : `${i18nKey}.loading.succeed`;
46
48
  SpinniesManager.succeed('sandboxSync', {
@@ -1,40 +1 @@
1
- export namespace sandboxTypeMap {
2
- let dev: "DEVELOPMENT_SANDBOX";
3
- let developer: "DEVELOPMENT_SANDBOX";
4
- let development: "DEVELOPMENT_SANDBOX";
5
- let standard: "STANDARD_SANDBOX";
6
- }
7
- export namespace sandboxApiTypeMap {
8
- let STANDARD_SANDBOX: number;
9
- let DEVELOPMENT_SANDBOX: number;
10
- }
11
- export namespace syncTypes {
12
- let OBJECT_RECORDS: string;
13
- }
14
- export function getSandboxTypeAsString(accountType: any): "development" | "standard";
15
- export function getHasSandboxesByType(parentAccountConfig: any, type: any): boolean;
16
- export function getSandboxLimit(error: any): number;
17
- /**
18
- * @param {Object} accountConfig - Account config of sandbox portal
19
- * @param {String} sandboxType - Sandbox type for limit validation
20
- * @param {String} env - Environment
21
- * @returns {null}
22
- */
23
- export function validateSandboxUsageLimits(accountConfig: Object, sandboxType: string, env: string): null;
24
- export function getAvailableSyncTypes(parentAccountConfig: any, config: any): Promise<{
25
- type: string;
26
- }[]>;
27
- /**
28
- * @param {Object} accountConfig - Account config of sandbox portal
29
- * @param {Array} availableSyncTasks - Array of available sync tasks
30
- * @param {Boolean} skipPrompt - Option to skip contact records prompt and return all available sync tasks
31
- * @returns {Array} Adjusted available sync task items
32
- */
33
- export function getSyncTypesWithContactRecordsPrompt(accountConfig: Object, syncTasks: any, skipPrompt?: boolean): any[];
34
- export function handleSandboxCreateError({ err, env, accountId, name, accountConfig, }: {
35
- err: any;
36
- env: any;
37
- accountId: any;
38
- name: any;
39
- accountConfig: any;
40
- }): void;
1
+ export {};
package/lib/sandboxes.js CHANGED
@@ -1,4 +1,6 @@
1
1
  "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ // @ts-nocheck
2
4
  const { i18n } = require('./lang');
3
5
  const { logger } = require('@hubspot/local-dev-lib/logger');
4
6
  const { getSandboxUsageLimits, } = require('@hubspot/local-dev-lib/api/sandboxHubs');
package/lib/schema.d.ts CHANGED
@@ -1,2 +1,3 @@
1
- export function logSchemas(schemas: any): void;
2
- export function listSchemas(accountId: any): Promise<void>;
1
+ import { Schema } from '@hubspot/local-dev-lib/types/Schemas';
2
+ export declare function logSchemas(schemas: Array<Schema>): void;
3
+ export declare function listSchemas(accountId: number): Promise<void>;
package/lib/schema.js CHANGED
@@ -1,28 +1,30 @@
1
1
  "use strict";
2
- const chalk = require('chalk');
3
- const { logger } = require('@hubspot/local-dev-lib/logger');
4
- const { table, getBorderCharacters } = require('table');
5
- const { fetchObjectSchemas, } = require('@hubspot/local-dev-lib/api/customObjects');
6
- const logSchemas = schemas => {
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.logSchemas = logSchemas;
7
+ exports.listSchemas = listSchemas;
8
+ const chalk_1 = __importDefault(require("chalk"));
9
+ const table_1 = require("table");
10
+ const logger_1 = require("@hubspot/local-dev-lib/logger");
11
+ const customObjects_1 = require("@hubspot/local-dev-lib/api/customObjects");
12
+ function logSchemas(schemas) {
7
13
  const data = schemas
8
14
  .map(r => [r.labels.singular, r.name, r.objectTypeId || ''])
9
15
  .sort((a, b) => (a[1] > b[1] ? 1 : -1));
10
16
  data.unshift([
11
- chalk.bold('Label'),
12
- chalk.bold('Name'),
13
- chalk.bold('objectTypeId'),
17
+ chalk_1.default.bold('Label'),
18
+ chalk_1.default.bold('Name'),
19
+ chalk_1.default.bold('objectTypeId'),
14
20
  ]);
15
21
  const tableConfig = {
16
22
  singleLine: true,
17
- border: getBorderCharacters('honeywell'),
23
+ border: (0, table_1.getBorderCharacters)('honeywell'),
18
24
  };
19
- logger.log(data.length ? table(data, tableConfig) : 'No Schemas were found');
20
- };
21
- const listSchemas = async (accountId) => {
22
- const { data } = await fetchObjectSchemas(accountId);
25
+ logger_1.logger.log(data.length ? (0, table_1.table)(data, tableConfig) : 'No Schemas were found');
26
+ }
27
+ async function listSchemas(accountId) {
28
+ const { data } = await (0, customObjects_1.fetchObjectSchemas)(accountId);
23
29
  logSchemas(data.results);
24
- };
25
- module.exports = {
26
- logSchemas,
27
- listSchemas,
28
- };
30
+ }
@@ -1,8 +1 @@
1
- export function outputBuildLog(buildLogUrl: any): Promise<any>;
2
- export function tailLogs({ accountId, compact, fetchLatest, tailCall, name, }: {
3
- accountId: any;
4
- compact: any;
5
- fetchLatest: any;
6
- tailCall: any;
7
- name: any;
8
- }): Promise<void>;
1
+ export {};
@@ -1,4 +1,6 @@
1
1
  "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ // @ts-nocheck
2
4
  const https = require('https');
3
5
  const SpinniesManager = require('./ui/SpinniesManager');
4
6
  const { handleExit, handleKeypress } = require('./process');
@@ -6,7 +8,7 @@ const chalk = require('chalk');
6
8
  const { logger } = require('@hubspot/local-dev-lib/logger');
7
9
  const { outputLogs } = require('./ui/serverlessFunctionLogs');
8
10
  const { logError, ApiErrorContext } = require('./errorHandlers/index');
9
- const { EXIT_CODES } = require('../lib/enums/exitCodes');
11
+ const { EXIT_CODES } = require('./enums/exitCodes');
10
12
  const { isHubSpotHttpError, isMissingScopeError, } = require('@hubspot/local-dev-lib/errors/index');
11
13
  const { SCOPE_GROUPS, PERSONAL_ACCESS_KEY_AUTH_METHOD, } = require('@hubspot/local-dev-lib/constants/auth');
12
14
  const { getAccountConfig } = require('@hubspot/local-dev-lib/config');
@@ -1,61 +1 @@
1
- declare const _exports: SpinniesManager;
2
- export = _exports;
3
- declare class SpinniesManager {
4
- init(options?: {}): void;
5
- options: {
6
- spinner: any;
7
- disableSpins: boolean;
8
- succeedPrefix: any;
9
- failPrefix: any;
10
- color: any;
11
- succeedColor: any;
12
- failColor: any;
13
- spinnerColor: any;
14
- } | {
15
- spinner: any;
16
- disableSpins: boolean;
17
- succeedPrefix: any;
18
- failPrefix: any;
19
- color: any;
20
- succeedColor: any;
21
- failColor: any;
22
- spinnerColor: any;
23
- } | undefined;
24
- spin: boolean | undefined;
25
- resetState(): void;
26
- spinners: {} | undefined;
27
- isCursorHidden: boolean | undefined;
28
- currentInterval: NodeJS.Timeout | null | undefined;
29
- stream: (NodeJS.WriteStream & {
30
- fd: 2;
31
- }) | undefined;
32
- lineCount: number | undefined;
33
- currentFrameIndex: any;
34
- pick(name: any): any;
35
- add(name: any, options?: {}): {
36
- text: any;
37
- status: any;
38
- indent: any;
39
- color: any;
40
- succeedColor: any;
41
- failColor: any;
42
- spinnerColor: any;
43
- succeedPrefix: any;
44
- failPrefix: any;
45
- name: any;
46
- };
47
- update(name: any, options?: {}): any;
48
- succeed(name: any, options?: {}): any;
49
- fail(name: any, options?: {}): any;
50
- remove(name: any): any;
51
- stopAll(newStatus?: string): {} | undefined;
52
- hasAnySpinners(): boolean;
53
- hasActiveSpinners(): boolean;
54
- setSpinnerProperties(name: any, options: any, status: any): void;
55
- updateSpinnerState(): void;
56
- loopStream(): NodeJS.Timeout;
57
- setStreamOutput(frame?: string): void;
58
- setRawStreamOutput(): void;
59
- checkIfActiveSpinners(): void;
60
- bindSigint(): void;
61
- }
1
+ export {};
@@ -1,4 +1,5 @@
1
1
  "use strict";
2
+ // @ts-nocheck
2
3
  /*
3
4
  https://github.com/jbcarpanelli/spinnies
4
5
 
@@ -8,6 +9,7 @@ Permission is hereby granted, free of charge, to any person obtaining a copy of
8
9
 
9
10
  The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
10
11
  **/
12
+ Object.defineProperty(exports, "__esModule", { value: true });
11
13
  const readline = require('readline');
12
14
  const chalk = require('chalk');
13
15
  const cliCursor = require('cli-cursor');
package/lib/ui/git.d.ts CHANGED
@@ -1 +1 @@
1
- export function checkAndWarnGitInclusion(configPath: any): void;
1
+ export {};
package/lib/ui/git.js CHANGED
@@ -1,4 +1,6 @@
1
1
  "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ // @ts-nocheck
2
4
  const os = require('os');
3
5
  const { checkGitInclusion } = require('@hubspot/local-dev-lib/gitignore');
4
6
  const { logger } = require('@hubspot/local-dev-lib/logger');
package/lib/ui/index.d.ts CHANGED
@@ -1,36 +1 @@
1
- export namespace UI_COLORS {
2
- let SORBET: string;
3
- let MARIGOLD: string;
4
- let MARIGOLD_DARK: string;
5
- }
6
- /**
7
- * Returns formatted account name, account type (if applicable), and ID
8
- *
9
- * @param {number} accountId
10
- * @param {boolean} bold
11
- * @returns {string}
12
- */
13
- export function uiAccountDescription(accountId: number, bold?: boolean): string;
14
- export function uiCommandReference(command: any): string;
15
- export function uiBetaTag(message: any, log?: boolean): string | undefined;
16
- export function uiDeprecatedTag(message: any, log?: boolean): string | undefined;
17
- export function uiFeatureHighlight(commands: any, title: any): void;
18
- export function uiInfoSection(title: any, logContent: any): void;
19
- /**
20
- * Outputs horizontal line
21
- *
22
- * @returns
23
- */
24
- export function uiLine(): void;
25
- /**
26
- * Returns a hyperlink or link and description
27
- *
28
- * @param {string} linkText
29
- * @param {string} url
30
- * @param {object} options
31
- * @returns {string}
32
- */
33
- export function uiLink(linkText: string, url: string): string;
34
- export function uiDeprecatedMessage(command: any, url?: undefined, message?: undefined): void;
35
- export function uiDeprecatedDescription(message: any, command: any, url?: undefined, log?: boolean): string | undefined;
36
- export function uiCommandDisabledBanner(command: any, url?: undefined, message?: undefined): void;
1
+ export {};
package/lib/ui/index.js CHANGED
@@ -1,4 +1,6 @@
1
1
  "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ // @ts-nocheck
2
4
  const chalk = require('chalk');
3
5
  const { getAccountConfig } = require('@hubspot/local-dev-lib/config');
4
6
  const { logger } = require('@hubspot/local-dev-lib/logger');
@@ -1 +1 @@
1
- export function outputLogs(logsResp: any, options: any): void;
1
+ export {};
@@ -1,4 +1,6 @@
1
1
  "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ // @ts-nocheck
2
4
  const moment = require('moment');
3
5
  const chalk = require('chalk');
4
6
  const { logger, Styles } = require('@hubspot/local-dev-lib/logger');
@@ -1,60 +1 @@
1
- export function breakText(text: any, prefixLength: any): any;
2
- export function cleanStream(stream: any, rawLines: any): void;
3
- export function colorOptions({ color, succeedColor, failColor, spinnerColor }: {
4
- color: any;
5
- succeedColor: any;
6
- failColor: any;
7
- spinnerColor: any;
8
- }): {
9
- color: any;
10
- succeedColor: any;
11
- failColor: any;
12
- spinnerColor: any;
13
- };
14
- export function getLinesLength(text: any, prefixLength: any): any;
15
- export function purgeSpinnerOptions(options: any): {
16
- text: any;
17
- status: any;
18
- indent: any;
19
- color: any;
20
- succeedColor: any;
21
- failColor: any;
22
- spinnerColor: any;
23
- };
24
- export function purgeSpinnersOptions({ spinner, disableSpins, ...others }: {
25
- [x: string]: any;
26
- spinner: any;
27
- disableSpins: any;
28
- }): {
29
- spinner: any;
30
- disableSpins: boolean;
31
- succeedPrefix: any;
32
- failPrefix: any;
33
- color: any;
34
- succeedColor: any;
35
- failColor: any;
36
- spinnerColor: any;
37
- } | {
38
- spinner: any;
39
- disableSpins?: undefined;
40
- succeedPrefix: any;
41
- failPrefix: any;
42
- color: any;
43
- succeedColor: any;
44
- failColor: any;
45
- spinnerColor: any;
46
- };
47
- export namespace SPINNERS {
48
- namespace dots {
49
- let interval: number;
50
- let frames: string[];
51
- }
52
- namespace dashes {
53
- let interval_1: number;
54
- export { interval_1 as interval };
55
- let frames_1: string[];
56
- export { frames_1 as frames };
57
- }
58
- }
59
- export function terminalSupportsUnicode(): boolean;
60
- export function writeStream(stream: any, output: any, rawLines: any): void;
1
+ export {};
@@ -1,4 +1,6 @@
1
1
  "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ // @ts-nocheck
2
4
  /*
3
5
  https://github.com/jbcarpanelli/spinnies
4
6
 
@@ -1,3 +1 @@
1
- export function supportsHyperlink(stream: any): boolean;
2
- export declare let stdout: boolean;
3
- export declare let stderr: boolean;
1
+ export {};
@@ -1,5 +1,7 @@
1
+ // @ts-nocheck
1
2
  'use strict';
2
- const hasFlag = require('../hasFlag');
3
+ Object.defineProperty(exports, "__esModule", { value: true });
4
+ const { hasFlag } = require('../hasFlag');
3
5
  //See https://github.com/jamestalmage/supports-hyperlinks (License: https://github.com/jamestalmage/supports-hyperlinks/blob/master/license)
4
6
  function parseVersion(versionString) {
5
7
  if (/^\d{3,4}$/.test(versionString)) {
@@ -1,13 +1 @@
1
- export function createSupportsColor(stream: any, options?: {}): {
2
- level: any;
3
- hasBasic: boolean;
4
- has256: boolean;
5
- has16m: boolean;
6
- };
7
- export declare namespace stdout {
8
- export { level };
9
- export let hasBasic: boolean;
10
- export let has256: boolean;
11
- export let has16m: boolean;
12
- }
13
- export declare namespace stderr { }
1
+ export {};
@@ -1,8 +1,10 @@
1
1
  "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ // @ts-nocheck
2
4
  const process = require('process');
3
5
  const os = require('os');
4
6
  const tty = require('tty');
5
- const hasFlag = require('../hasFlag');
7
+ const { hasFlag } = require('../hasFlag');
6
8
  const { env } = process;
7
9
  //From: https://github.com/chalk/supports-color/blob/main/index.js (License: https://github.com/chalk/supports-color/blob/main/license)
8
10
  function translateLevel(level) {
package/lib/ui/table.d.ts CHANGED
@@ -1,2 +1 @@
1
- export function getTableContents(tableData?: any[], tableConfig?: {}): string;
2
- export function getTableHeader(headerItems: any): any;
1
+ export {};
package/lib/ui/table.js CHANGED
@@ -1,4 +1,6 @@
1
1
  "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ // @ts-nocheck
2
4
  const chalk = require('chalk');
3
5
  const { table } = require('table');
4
6
  function isObject(item) {
package/lib/upload.d.ts CHANGED
@@ -1 +1 @@
1
- export function getUploadableFileList(src: any, convertFields: any): Promise<any[]>;
1
+ export {};
package/lib/upload.js CHANGED
@@ -1,8 +1,10 @@
1
1
  "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ // @ts-nocheck
2
4
  const path = require('path');
3
5
  const { walk } = require('@hubspot/local-dev-lib/fs');
4
6
  const { createIgnoreFilter } = require('@hubspot/local-dev-lib/ignoreRules');
5
- const { fieldsJsPrompt } = require('../lib/prompts/cmsFieldPrompt');
7
+ const { fieldsJsPrompt } = require('./prompts/cmsFieldPrompt');
6
8
  const { isAllowedExtension } = require('@hubspot/local-dev-lib/path');
7
9
  const { isConvertableFieldJs, } = require('@hubspot/local-dev-lib/cms/handleFieldsJS');
8
10
  const { logError } = require('./errorHandlers/index');
@@ -29,7 +31,7 @@ const getUploadableFileList = async (src, convertFields) => {
29
31
  if (!convertFields) {
30
32
  return allowedFiles;
31
33
  }
32
- let uploadableFiles = [];
34
+ const uploadableFiles = [];
33
35
  let skipFiles = [];
34
36
  for (const filePath of allowedFiles) {
35
37
  const fileName = path.basename(filePath);
@@ -1,6 +1 @@
1
- export function trackCommandUsage(command: any, meta: {} | undefined, accountId: any): void;
2
- export function trackHelpUsage(command: any): Promise<void>;
3
- export function addHelpUsageTracking(program: any, command: any): void;
4
- export function trackConvertFieldsUsage(command: any): Promise<void>;
5
- export function trackAuthAction(command: any, authType: any, step: any, accountId: any): Promise<void>;
6
- export function trackCommandMetadataUsage(command: any, meta: {} | undefined, accountId: any): void;
1
+ export {};
@@ -1,10 +1,11 @@
1
1
  "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ // @ts-nocheck
2
4
  const { trackUsage } = require('@hubspot/local-dev-lib/trackUsage');
3
5
  const { isTrackingAllowed, getAccountConfig, } = require('@hubspot/local-dev-lib/config');
4
6
  const { API_KEY_AUTH_METHOD, } = require('@hubspot/local-dev-lib/constants/auth');
5
7
  const { logger } = require('@hubspot/local-dev-lib/logger');
6
8
  const { version } = require('../package.json');
7
- const { getPlatform } = require('./environment');
8
9
  const { setLogLevel } = require('./commonOpts');
9
10
  /* **
10
11
  Available tracking meta properties
@@ -34,6 +35,16 @@ const getNodeVersionData = () => ({
34
35
  nodeVersion: process.version,
35
36
  nodeMajorVersion: (process.version || '').split('.')[0],
36
37
  });
38
+ const getPlatform = () => {
39
+ switch (process.platform) {
40
+ case 'darwin':
41
+ return 'macos';
42
+ case 'win32':
43
+ return 'windows';
44
+ default:
45
+ return process.platform;
46
+ }
47
+ };
37
48
  function trackCommandUsage(command, meta = {}, accountId) {
38
49
  if (!isTrackingAllowed()) {
39
50
  return;
@@ -1,16 +1 @@
1
- /**
2
- * @param {object} command options
3
- * @returns {boolean}
4
- */
5
- export function validateMode(options: any): boolean;
6
- /**
7
- * Validate that an account was passed to the command and that the account's configuration is valid
8
- *
9
- *
10
- * @param {object} command options
11
- * @returns {boolean}
12
- */
13
- export function validateAccount(options: any): boolean;
14
- export function checkAndConvertToJson(_path: any): any;
15
- export function fileExists(_path: any): boolean;
16
- export function loadAndValidateOptions(options: any, shouldValidateAccount?: boolean): Promise<void>;
1
+ export {};
package/lib/validation.js CHANGED
@@ -1,4 +1,6 @@
1
1
  "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ // @ts-nocheck
2
4
  const fs = require('fs');
3
5
  const path = require('path');
4
6
  const { logger } = require('@hubspot/local-dev-lib/logger');
@@ -10,13 +12,11 @@ const { getOauthManager } = require('@hubspot/local-dev-lib/oauth');
10
12
  const { accessTokenForPersonalAccessKey, } = require('@hubspot/local-dev-lib/personalAccessKey');
11
13
  const { getAbsoluteFilePath, getCwd, getExt, } = require('@hubspot/local-dev-lib/path');
12
14
  const { getAccountId, getMode, setLogLevel } = require('./commonOpts');
13
- const { logDebugInfo } = require('./debugInfo');
14
15
  const { EXIT_CODES } = require('./enums/exitCodes');
15
16
  const { checkAndWarnGitInclusion } = require('./ui/git');
16
17
  const { logError } = require('./errorHandlers/index');
17
18
  async function loadAndValidateOptions(options, shouldValidateAccount = true) {
18
19
  setLogLevel(options);
19
- logDebugInfo(options);
20
20
  const { config: configPath } = options;
21
21
  loadConfig(configPath, options);
22
22
  checkAndWarnGitInclusion(getConfigPath());