@hubspot/cli 7.4.8 → 7.4.9-beta.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (206) hide show
  1. package/commands/account/auth.d.ts +3 -7
  2. package/commands/account/auth.js +19 -9
  3. package/commands/account/clean.d.ts +3 -7
  4. package/commands/account/clean.js +16 -9
  5. package/commands/account/createOverride.d.ts +3 -7
  6. package/commands/account/createOverride.js +23 -6
  7. package/commands/account/info.d.ts +3 -7
  8. package/commands/account/info.js +13 -5
  9. package/commands/account/list.d.ts +3 -7
  10. package/commands/account/list.js +15 -8
  11. package/commands/account/remove.d.ts +3 -7
  12. package/commands/account/remove.js +21 -9
  13. package/commands/account/removeOverride.d.ts +3 -7
  14. package/commands/account/removeOverride.js +23 -6
  15. package/commands/account/rename.d.ts +3 -7
  16. package/commands/account/rename.js +16 -9
  17. package/commands/account/use.d.ts +5 -9
  18. package/commands/account/use.js +14 -6
  19. package/commands/account.d.ts +3 -4
  20. package/commands/account.js +35 -58
  21. package/commands/cms/convertFields.d.ts +7 -1
  22. package/commands/cms/convertFields.js +57 -41
  23. package/commands/cms/getReactModule.d.ts +7 -1
  24. package/commands/cms/getReactModule.js +52 -34
  25. package/commands/cms/lighthouseScore.d.ts +8 -1
  26. package/commands/cms/lighthouseScore.js +129 -100
  27. package/commands/cms.d.ts +3 -1
  28. package/commands/cms.js +24 -15
  29. package/commands/completion.d.ts +3 -1
  30. package/commands/completion.js +25 -12
  31. package/commands/config/migrate.d.ts +1 -1
  32. package/commands/config/migrate.js +16 -12
  33. package/commands/create/api-sample.d.ts +3 -1
  34. package/commands/create/api-sample.js +34 -38
  35. package/commands/create/app.d.ts +3 -1
  36. package/commands/create/app.js +9 -7
  37. package/commands/create/function.d.ts +3 -1
  38. package/commands/create/function.js +11 -10
  39. package/commands/create/index.d.ts +5 -1
  40. package/commands/create/index.js +23 -11
  41. package/commands/create/module.d.ts +3 -1
  42. package/commands/create/module.js +14 -13
  43. package/commands/create/react-app.d.ts +3 -1
  44. package/commands/create/react-app.js +10 -7
  45. package/commands/create/template.d.ts +3 -1
  46. package/commands/create/template.js +14 -14
  47. package/commands/create/vue-app.d.ts +3 -1
  48. package/commands/create/vue-app.js +10 -7
  49. package/commands/create/webpack-serverless.d.ts +3 -1
  50. package/commands/create/webpack-serverless.js +10 -7
  51. package/commands/create/website-theme.d.ts +3 -1
  52. package/commands/create/website-theme.js +10 -9
  53. package/commands/create.d.ts +4 -24
  54. package/commands/create.js +63 -74
  55. package/commands/customObject/create.d.ts +4 -9
  56. package/commands/customObject/create.js +17 -10
  57. package/commands/customObject/schema/create.d.ts +4 -9
  58. package/commands/customObject/schema/create.js +18 -11
  59. package/commands/customObject/schema/delete.d.ts +4 -9
  60. package/commands/customObject/schema/delete.js +17 -10
  61. package/commands/customObject/schema/fetch-all.d.ts +4 -9
  62. package/commands/customObject/schema/fetch-all.js +17 -10
  63. package/commands/customObject/schema/fetch.d.ts +4 -9
  64. package/commands/customObject/schema/fetch.js +17 -10
  65. package/commands/customObject/schema/list.d.ts +4 -8
  66. package/commands/customObject/schema/list.js +17 -10
  67. package/commands/customObject/schema/update.d.ts +4 -9
  68. package/commands/customObject/schema/update.js +18 -11
  69. package/commands/customObject/schema.d.ts +3 -5
  70. package/commands/customObject/schema.js +27 -54
  71. package/commands/customObject.d.ts +3 -4
  72. package/commands/customObject.js +20 -45
  73. package/commands/feedback.d.ts +4 -1
  74. package/commands/feedback.js +40 -47
  75. package/commands/fetch.d.ts +12 -1
  76. package/commands/fetch.js +49 -33
  77. package/commands/filemanager/fetch.d.ts +4 -9
  78. package/commands/filemanager/fetch.js +18 -11
  79. package/commands/filemanager/upload.d.ts +4 -9
  80. package/commands/filemanager/upload.js +17 -11
  81. package/commands/filemanager.d.ts +3 -4
  82. package/commands/filemanager.js +20 -41
  83. package/commands/function/deploy.d.ts +6 -1
  84. package/commands/function/deploy.js +70 -50
  85. package/commands/function/list.d.ts +6 -1
  86. package/commands/function/list.js +44 -32
  87. package/commands/function/server.d.ts +10 -1
  88. package/commands/function/server.js +49 -38
  89. package/commands/function.d.ts +5 -1
  90. package/commands/function.js +24 -10
  91. package/commands/hubdb/clear.d.ts +4 -9
  92. package/commands/hubdb/clear.js +17 -10
  93. package/commands/hubdb/create.d.ts +4 -9
  94. package/commands/hubdb/create.js +17 -10
  95. package/commands/hubdb/delete.d.ts +4 -9
  96. package/commands/hubdb/delete.js +17 -10
  97. package/commands/hubdb/fetch.d.ts +4 -9
  98. package/commands/hubdb/fetch.js +17 -10
  99. package/commands/hubdb.d.ts +3 -2
  100. package/commands/hubdb.js +23 -45
  101. package/commands/lint.d.ts +6 -4
  102. package/commands/lint.js +44 -43
  103. package/commands/logs.d.ts +10 -1
  104. package/commands/logs.js +53 -44
  105. package/commands/module/marketplace-validate.d.ts +6 -1
  106. package/commands/module/marketplace-validate.js +39 -27
  107. package/commands/module.d.ts +3 -1
  108. package/commands/module.js +22 -10
  109. package/commands/project/cloneApp.d.ts +1 -1
  110. package/commands/project/create.js +3 -3
  111. package/commands/project/deploy.d.ts +1 -0
  112. package/commands/project/deploy.js +40 -12
  113. package/commands/project/dev/index.d.ts +1 -4
  114. package/commands/project/dev/index.js +44 -15
  115. package/commands/project/dev/unifiedFlow.d.ts +2 -1
  116. package/commands/project/dev/unifiedFlow.js +52 -20
  117. package/commands/project/migrate.d.ts +1 -0
  118. package/commands/project/profile/add.d.ts +7 -0
  119. package/commands/project/profile/add.js +190 -0
  120. package/commands/project/profile/remove.d.ts +6 -0
  121. package/commands/project/profile/remove.js +119 -0
  122. package/commands/project/profile.d.ts +3 -0
  123. package/commands/project/profile.js +25 -0
  124. package/commands/project/upload.d.ts +1 -0
  125. package/commands/project/upload.js +38 -8
  126. package/commands/project.js +2 -0
  127. package/commands/sandbox/create.d.ts +4 -9
  128. package/commands/sandbox/create.js +18 -11
  129. package/commands/sandbox/delete.d.ts +4 -9
  130. package/commands/sandbox/delete.js +18 -11
  131. package/commands/sandbox.d.ts +3 -4
  132. package/commands/sandbox.js +20 -43
  133. package/commands/secret/addSecret.d.ts +4 -9
  134. package/commands/secret/addSecret.js +17 -10
  135. package/commands/secret/deleteSecret.d.ts +4 -9
  136. package/commands/secret/deleteSecret.js +17 -10
  137. package/commands/secret/listSecret.d.ts +4 -9
  138. package/commands/secret/listSecret.js +17 -10
  139. package/commands/secret/updateSecret.d.ts +4 -9
  140. package/commands/secret/updateSecret.js +17 -10
  141. package/commands/secret.d.ts +3 -4
  142. package/commands/secret.js +25 -48
  143. package/commands/theme/generate-selectors.d.ts +3 -7
  144. package/commands/theme/generate-selectors.js +14 -6
  145. package/commands/theme/marketplace-validate.d.ts +4 -9
  146. package/commands/theme/marketplace-validate.js +17 -10
  147. package/commands/theme/preview.d.ts +4 -9
  148. package/commands/theme/preview.js +16 -9
  149. package/commands/theme.d.ts +3 -4
  150. package/commands/theme.js +23 -46
  151. package/commands/upload.d.ts +12 -1
  152. package/commands/upload.js +118 -97
  153. package/commands/watch.d.ts +14 -1
  154. package/commands/watch.js +76 -65
  155. package/lang/en.d.ts +654 -558
  156. package/lang/en.js +443 -353
  157. package/lang/en.lyaml +23 -13
  158. package/lib/app/migrate.d.ts +23 -0
  159. package/lib/app/migrate.js +14 -3
  160. package/lib/app/migrate_legacy.js +5 -5
  161. package/lib/configMigrate.js +24 -10
  162. package/lib/constants.d.ts +6 -0
  163. package/lib/constants.js +7 -1
  164. package/lib/errorHandlers/suppressError.js +12 -19
  165. package/lib/filesystem.d.ts +1 -1
  166. package/lib/interpolation.d.ts +2 -3
  167. package/lib/lang.d.ts +2 -3
  168. package/lib/middleware/configMiddleware.js +8 -0
  169. package/lib/projectProfiles.d.ts +6 -0
  170. package/lib/projectProfiles.js +65 -0
  171. package/lib/projects/buildAndDeploy.js +17 -2
  172. package/lib/projects/localDev/AppDevModeInterface.d.ts +25 -0
  173. package/lib/projects/localDev/AppDevModeInterface.js +117 -0
  174. package/lib/projects/localDev/DevServerManagerV2.d.ts +11 -22
  175. package/lib/projects/localDev/DevServerManagerV2.js +19 -15
  176. package/lib/projects/localDev/LocalDevLogger.d.ts +30 -0
  177. package/lib/projects/localDev/LocalDevLogger.js +158 -0
  178. package/lib/projects/localDev/LocalDevManager.js +2 -3
  179. package/lib/projects/localDev/LocalDevProcess.d.ts +27 -0
  180. package/lib/projects/localDev/LocalDevProcess.js +171 -0
  181. package/lib/projects/localDev/LocalDevState.d.ts +37 -0
  182. package/lib/projects/localDev/LocalDevState.js +78 -0
  183. package/lib/projects/localDev/LocalDevWatcher.d.ts +10 -0
  184. package/lib/projects/localDev/LocalDevWatcher.js +56 -0
  185. package/lib/projects/localDev/LocalDevWebsocketServer.d.ts +17 -0
  186. package/lib/projects/localDev/LocalDevWebsocketServer.js +92 -0
  187. package/lib/projects/localDev/helpers.d.ts +1 -1
  188. package/lib/projects/localDev/helpers.js +2 -1
  189. package/lib/projects/upload.d.ts +2 -1
  190. package/lib/projects/upload.js +2 -2
  191. package/lib/prompts/createApiSamplePrompt.d.ts +2 -10
  192. package/lib/prompts/createTemplatePrompt.d.ts +22 -4
  193. package/lib/testUtils.d.ts +3 -3
  194. package/lib/testUtils.js +8 -9
  195. package/lib/upload.d.ts +1 -1
  196. package/lib/validation.js +4 -5
  197. package/lib/yargsUtils.d.ts +4 -0
  198. package/lib/yargsUtils.js +6 -0
  199. package/package.json +5 -3
  200. package/types/Cms.d.ts +30 -0
  201. package/types/Cms.js +2 -0
  202. package/types/LocalDev.d.ts +24 -0
  203. package/types/LocalDev.js +2 -0
  204. package/types/Yargs.d.ts +8 -1
  205. package/lib/projects/localDev/LocalDevManagerV2.d.ts +0 -64
  206. package/lib/projects/localDev/LocalDevManagerV2.js +0 -345
package/lang/en.js CHANGED
@@ -4,10 +4,10 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
4
4
  };
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
6
  exports.lib = exports.commands = void 0;
7
- // @ts-nocheck
8
7
  const chalk_1 = __importDefault(require("chalk"));
9
8
  const ui_1 = require("../lib/ui");
10
9
  const urls_1 = require("../lib/projects/urls");
10
+ const ui_2 = require("../lib/ui");
11
11
  exports.commands = {
12
12
  generalErrors: {
13
13
  updateNotify: {
@@ -20,7 +20,7 @@ exports.commands = {
20
20
  portalEnvVarDeprecated: 'The HUBSPOT_PORTAL_ID environment variable is deprecated. Please use HUBSPOT_ACCOUNT_ID instead.',
21
21
  },
22
22
  loadConfigMiddleware: {
23
- configFileExists: configPath => `A configuration file already exists at ${configPath}. To specify a new configuration file, delete the existing one and try again.`,
23
+ configFileExists: (configPath) => `A configuration file already exists at ${configPath}. To specify a new configuration file, delete the existing one and try again.`,
24
24
  },
25
25
  },
26
26
  completion: {
@@ -34,9 +34,9 @@ exports.commands = {
34
34
  subcommands: {
35
35
  list: {
36
36
  accounts: `${chalk_1.default.bold('Accounts')}:`,
37
- defaultAccount: account => `${chalk_1.default.bold('Default account')}: ${account}`,
37
+ defaultAccount: (account) => `${chalk_1.default.bold('Default account')}: ${account}`,
38
38
  describe: 'List names of accounts defined in config.',
39
- configPath: configPath => `${chalk_1.default.bold('Config path')}: ${configPath}`,
39
+ configPath: (configPath) => `${chalk_1.default.bold('Config path')}: ${configPath}`,
40
40
  labels: {
41
41
  accountId: 'Account ID',
42
42
  authType: 'Auth Type',
@@ -74,7 +74,7 @@ exports.commands = {
74
74
  },
75
75
  promptMessage: 'Select an account to use as the default',
76
76
  success: {
77
- defaultAccountUpdated: accountName => `Default account updated to "${accountName}"`,
77
+ defaultAccountUpdated: (accountName) => `Default account updated to "${accountName}"`,
78
78
  },
79
79
  },
80
80
  remove: {
@@ -99,11 +99,11 @@ exports.commands = {
99
99
  },
100
100
  promptMessage: 'Select an account to remove',
101
101
  success: {
102
- accountRemoved: accountName => `Account "${accountName}" removed from the config`,
102
+ accountRemoved: (accountName) => `Account "${accountName}" removed from the config`,
103
103
  },
104
104
  },
105
105
  info: {
106
- accountId: accountId => `${chalk_1.default.bold('Account ID')}: ${accountId}`,
106
+ accountId: (accountId) => `${chalk_1.default.bold('Account ID')}: ${accountId}`,
107
107
  describe: 'Print information about the default account, or about the account specified with the "account" option.',
108
108
  errors: {
109
109
  notUsingPersonalAccessKey: 'This command currently only supports fetching scopes for the personal access key auth type.',
@@ -113,7 +113,7 @@ exports.commands = {
113
113
  idBased: 'Print information for the account with accountId equal to "1234567"',
114
114
  nameBased: 'Print information for the account in the config with name equal to "MyAccount"',
115
115
  },
116
- name: name => `${chalk_1.default.bold('Account name')}: ${name}`,
116
+ name: (name) => `${chalk_1.default.bold('Account name')}: ${name}`,
117
117
  scopeGroups: `${chalk_1.default.bold('Scopes available')}:`,
118
118
  },
119
119
  clean: {
@@ -124,18 +124,18 @@ exports.commands = {
124
124
  },
125
125
  inactiveAccountsFound: {
126
126
  one: '1 inactive account found:',
127
- other: count => `${count} inactive accounts found:`,
127
+ other: (count) => `${count} inactive accounts found:`,
128
128
  },
129
129
  confirm: {
130
130
  one: 'Remove 1 inactive account from the CLI config?',
131
- other: count => `Remove ${count} inactive accounts from the CLI config?`,
131
+ other: (count) => `Remove ${count} inactive accounts from the CLI config?`,
132
132
  },
133
- removeSuccess: accountName => `Removed ${accountName} from the CLI config.`,
133
+ removeSuccess: (accountName) => `Removed ${accountName} from the CLI config.`,
134
134
  },
135
135
  },
136
136
  },
137
137
  auth: {
138
- describe: configName => `Configure authentication for your HubSpot account. This will update the ${configName} file that stores your account information.`,
138
+ describe: (configName) => `Configure authentication for your HubSpot account. This will update the ${configName} file that stores your account information.`,
139
139
  errors: {
140
140
  noConfigFileFound: 'No config file was found. To create a new config file, use the "hs init" command.',
141
141
  unsupportedAuthType: (type, supportedProtocols) => `Unsupported auth type: ${type}. The only supported authentication protocols are ${supportedProtocols}.`,
@@ -143,7 +143,7 @@ exports.commands = {
143
143
  options: {
144
144
  authType: {
145
145
  describe: 'Authentication mechanism',
146
- defaultDescription: authMethod => `"${authMethod}": An access token tied to a specific user account. This is the recommended way of authenticating with local development tools.`,
146
+ defaultDescription: (authMethod) => `"${authMethod}": An access token tied to a specific user account. This is the recommended way of authenticating with local development tools.`,
147
147
  },
148
148
  account: {
149
149
  describe: 'HubSpot account to authenticate',
@@ -166,13 +166,13 @@ exports.commands = {
166
166
  defaultMode: {
167
167
  describe: 'Set the default CMS publish mode',
168
168
  promptMessage: 'Select CMS publish mode to be used as the default',
169
- error: validModes => `The provided CMS publish mode is invalid. Valid values are ${validModes}.`,
170
- success: mode => `Default mode updated to: ${mode}`,
169
+ error: (validModes) => `The provided CMS publish mode is invalid. Valid values are ${validModes}.`,
170
+ success: (mode) => `Default mode updated to: ${mode}`,
171
171
  },
172
172
  allowUsageTracking: {
173
173
  describe: 'Enable or disable usage tracking',
174
174
  promptMessage: 'Choose to enable or disable usage tracking',
175
- success: isEnabled => `Allow usage tracking set to: "${isEnabled}"`,
175
+ success: (isEnabled) => `Allow usage tracking set to: "${isEnabled}"`,
176
176
  labels: {
177
177
  enabled: 'Enabled',
178
178
  disabled: 'Disabled',
@@ -181,7 +181,7 @@ exports.commands = {
181
181
  httpTimeout: {
182
182
  describe: 'Set the http timeout duration',
183
183
  promptMessage: 'Enter http timeout duration',
184
- success: timeout => `The http timeout has been set to: ${timeout}`,
184
+ success: (timeout) => `The http timeout has been set to: ${timeout}`,
185
185
  },
186
186
  },
187
187
  },
@@ -198,8 +198,8 @@ exports.commands = {
198
198
  info: {
199
199
  promptMessage: 'Select a theme to score',
200
200
  fetchingThemes: 'Fetching available themes',
201
- generatingScore: theme => `Generating Google Lighthouse score for ${theme}`,
202
- targetDeviceNote: target => `Scores are being shown for ${target} only.`,
201
+ generatingScore: (theme) => `Generating Google Lighthouse score for ${theme}`,
202
+ targetDeviceNote: (target) => `Scores are being shown for ${target} only.`,
203
203
  verboseOptionNote: 'Theme scores are averages of all theme templates. Use the [--verbose] option to include individual template scores.',
204
204
  pageTemplateScoreTitle: 'Page template scores',
205
205
  lighthouseLinksTitle: 'Lighthouse links',
@@ -208,7 +208,7 @@ exports.commands = {
208
208
  errors: {
209
209
  targetOptionRequired: '[--target] is required for detailed view',
210
210
  invalidTargetOption: '[--target] can only be used for detailed view',
211
- themeNotFound: theme => `Theme "${theme}" not found. Please rerun using a valid theme path.`,
211
+ themeNotFound: (theme) => `Theme "${theme}" not found. Please rerun using a valid theme path.`,
212
212
  failedToFetchThemes: 'Failed to fetch available themes. Try running again with the [--theme] option',
213
213
  failedToGetLighthouseScore: 'Failed to generate a Google Lighthouse score',
214
214
  },
@@ -239,18 +239,18 @@ exports.commands = {
239
239
  moduleDownloaded: (moduleName, path) => `"${moduleName}" successfully downloaded to "${path}"`,
240
240
  },
241
241
  errors: {
242
- pathExists: path => `Folder already exists at "${path}"`,
242
+ pathExists: (path) => `Folder already exists at "${path}"`,
243
243
  invalidName: 'Module not found with that name, please check the spelling of the module you are trying to download.',
244
244
  },
245
245
  },
246
246
  },
247
247
  },
248
248
  create: {
249
- describe: supportedAssetTypes => `Create HubSpot sample apps and CMS assets. Supported assets are ${supportedAssetTypes}.`,
249
+ describe: (supportedAssetTypes) => `Create HubSpot sample apps and CMS assets. Supported assets are ${supportedAssetTypes}.`,
250
250
  errors: {
251
- deprecatedAssetType: (assetType, newCommand, type) => `The CLI command for asset type ${assetType} has been deprecated in an effort to make it easier to know what asset types can be created. Run the "${newCommand}" command instead. Then when prompted select "${type}".`,
251
+ deprecatedAssetType: (assetType, newCommand, type) => `The CLI command for asset type ${assetType} has been deprecated in an effort to make it easier to know what asset types can be created. Run the ${(0, ui_1.uiCommandReference)(newCommand)}" command instead. Then when prompted select "${type}".`,
252
252
  unsupportedAssetType: (assetType, supportedAssetTypes) => `The asset type ${assetType} is not supported. Supported asset types are ${supportedAssetTypes}.`,
253
- unusablePath: path => `The "${path}" is not a usable path to a directory.`,
253
+ unusablePath: (path) => `The "${path}" is not a usable path to a directory.`,
254
254
  },
255
255
  positionals: {
256
256
  dest: {
@@ -265,7 +265,7 @@ exports.commands = {
265
265
  },
266
266
  subcommands: {
267
267
  apiSample: {
268
- folderOverwritePrompt: folderName => `The folder with name "${folderName}" already exists. Overwrite?`,
268
+ folderOverwritePrompt: (folderName) => `The folder with name "${folderName}" already exists. Overwrite?`,
269
269
  errors: {
270
270
  nameRequired: 'The "name" argument is required when creating an API Sample.',
271
271
  noSamples: 'Currently there are no samples available. Please try again later.',
@@ -274,7 +274,7 @@ exports.commands = {
274
274
  sampleChosen: (sampleType, sampleLanguage) => `You've chosen ${sampleType} sample written on ${sampleLanguage} language`,
275
275
  },
276
276
  success: {
277
- sampleCreated: filePath => `Please follow ${filePath}/README.md to find out how to run the sample`,
277
+ sampleCreated: (filePath) => `Please follow ${filePath}/README.md to find out how to run the sample`,
278
278
  },
279
279
  },
280
280
  module: {
@@ -298,7 +298,7 @@ exports.commands = {
298
298
  describe: 'Create custom object instances.',
299
299
  errors: {
300
300
  invalidObjectDefinition: 'The object definition is invalid. Please check the schema and try again.',
301
- creationFailed: definition => `Object creation from ${definition} failed`,
301
+ creationFailed: (definition) => `Object creation from ${definition} failed`,
302
302
  },
303
303
  options: {
304
304
  path: {
@@ -323,7 +323,7 @@ exports.commands = {
323
323
  describe: 'Create a custom object schema.',
324
324
  errors: {
325
325
  invalidSchema: 'The schema definition is invalid. Please check the schema and try again.',
326
- creationFailed: definition => `Schema creation from ${definition} failed`,
326
+ creationFailed: (definition) => `Schema creation from ${definition} failed`,
327
327
  },
328
328
  options: {
329
329
  definition: {
@@ -331,14 +331,14 @@ exports.commands = {
331
331
  },
332
332
  },
333
333
  success: {
334
- schemaCreated: accountId => `Your schema has been created in account "${accountId}"`,
335
- schemaViewable: url => `Schema can be viewed at ${url}`,
334
+ schemaCreated: (accountId) => `Your schema has been created in account "${accountId}"`,
335
+ schemaViewable: (url) => `Schema can be viewed at ${url}`,
336
336
  },
337
337
  },
338
338
  delete: {
339
339
  describe: 'Delete a custom object schema.',
340
340
  errors: {
341
- delete: name => `Unable to delete ${name}`,
341
+ delete: (name) => `Unable to delete ${name}`,
342
342
  },
343
343
  examples: {
344
344
  default: 'Delete "schemaName" schema',
@@ -354,10 +354,10 @@ exports.commands = {
354
354
  },
355
355
  },
356
356
  success: {
357
- delete: name => `Successfully initiated deletion of ${name}`,
357
+ delete: (name) => `Successfully initiated deletion of ${name}`,
358
358
  },
359
- confirmDelete: name => `Are you sure you want to delete the schema "${name}"?`,
360
- deleteCancelled: name => `Deletion of schema "${name}" cancelled.`,
359
+ confirmDelete: (name) => `Are you sure you want to delete the schema "${name}"?`,
360
+ deleteCancelled: (name) => `Deletion of schema "${name}" cancelled.`,
361
361
  selectSchema: 'Which schema would you like to delete?',
362
362
  },
363
363
  fetchAll: {
@@ -375,14 +375,14 @@ exports.commands = {
375
375
  },
376
376
  },
377
377
  success: {
378
- fetch: path => `Saved schemas to ${path}`,
378
+ fetch: (path) => `Saved schemas to ${path}`,
379
379
  },
380
380
  inputDest: 'Where would you like to save the schemas?',
381
381
  },
382
382
  fetch: {
383
383
  describe: 'Fetch a custom object schema.',
384
384
  errors: {
385
- fetch: name => `Unable to fetch ${name}`,
385
+ fetch: (name) => `Unable to fetch ${name}`,
386
386
  },
387
387
  examples: {
388
388
  default: 'Fetch "schemaId" schema and put it in the current working directory',
@@ -400,7 +400,7 @@ exports.commands = {
400
400
  inputDest: 'What would you like to name the destination file?',
401
401
  success: {
402
402
  save: (name, path) => `The schema "${name}" has been saved to "${path}"`,
403
- savedToPath: path => `Saved schema to ${path}`,
403
+ savedToPath: (path) => `Saved schema to ${path}`,
404
404
  },
405
405
  },
406
406
  list: {
@@ -413,7 +413,7 @@ exports.commands = {
413
413
  describe: 'Update an existing custom object schema.',
414
414
  errors: {
415
415
  invalidSchema: 'The schema definition is invalid. Please check the schema and try again.',
416
- update: definition => `Schema update from ${definition} failed`,
416
+ update: (definition) => `Schema update from ${definition} failed`,
417
417
  },
418
418
  options: {
419
419
  path: {
@@ -426,8 +426,8 @@ exports.commands = {
426
426
  },
427
427
  },
428
428
  success: {
429
- update: accountId => `Your schema has been updated in account "${accountId}"`,
430
- viewAtUrl: url => `Schema can be viewed at ${url}`,
429
+ update: (accountId) => `Your schema has been updated in account "${accountId}"`,
430
+ viewAtUrl: (url) => `Schema can be viewed at ${url}`,
431
431
  },
432
432
  selectSchema: 'Which schema would you like to update?',
433
433
  },
@@ -444,7 +444,7 @@ exports.commands = {
444
444
  generatingDiagnosis: 'Error generating diagnosis',
445
445
  unableToWriteOutputFile: (file, errorMessage) => `Unable to write output to ${chalk_1.default.bold(file)}, ${errorMessage}`,
446
446
  },
447
- outputWritten: filename => `Output written to ${chalk_1.default.bold(filename)}`,
447
+ outputWritten: (filename) => `Output written to ${chalk_1.default.bold(filename)}`,
448
448
  },
449
449
  fetch: {
450
450
  describe: 'Fetch a file, directory or module from HubSpot and write to a path on your computer.',
@@ -494,8 +494,8 @@ exports.commands = {
494
494
  describe: 'Upload a folder or file to the File Manager.',
495
495
  errors: {
496
496
  destinationRequired: 'A destination path needs to be passed',
497
- fileIgnored: path => `The file "${path}" is being ignored via an .hsignore rule`,
498
- invalidPath: path => `The path "${path}" is not a path to a file or folder`,
497
+ fileIgnored: (path) => `The file "${path}" is being ignored via an .hsignore rule`,
498
+ invalidPath: (path) => `The path "${path}" is not a path to a file or folder`,
499
499
  upload: (src, dest) => `Uploading file "${src}" to "${dest}" failed`,
500
500
  uploadingFailed: 'Uploading failed',
501
501
  },
@@ -512,7 +512,7 @@ exports.commands = {
512
512
  },
513
513
  success: {
514
514
  upload: (src, dest, accountId) => `Uploaded file from "${src}" to "${dest}" in the File Manager of account ${accountId}`,
515
- uploadComplete: dest => `Uploading files to "${dest}" in the File Manager is complete`,
515
+ uploadComplete: (dest) => `Uploading files to "${dest}" in the File Manager is complete`,
516
516
  },
517
517
  },
518
518
  },
@@ -522,12 +522,12 @@ exports.commands = {
522
522
  subcommands: {
523
523
  deploy: {
524
524
  debug: {
525
- startingBuildAndDeploy: functionPath => `Starting build and deploy for .functions folder with path: ${functionPath}`,
525
+ startingBuildAndDeploy: (functionPath) => `Starting build and deploy for .functions folder with path: ${functionPath}`,
526
526
  },
527
527
  errors: {
528
- buildError: details => `Build error: ${details}`,
529
- noPackageJson: functionPath => `Unable to find package.json for function ${functionPath}.`,
530
- notFunctionsFolder: functionPath => `Specified path ${functionPath} is not a .functions folder.`,
528
+ buildError: (details) => `Build error: ${details}`,
529
+ noPackageJson: (functionPath) => `Unable to find package.json for function ${functionPath}.`,
530
+ notFunctionsFolder: (functionPath) => `Specified path ${functionPath} is not a .functions folder.`,
531
531
  },
532
532
  examples: {
533
533
  default: 'Build and deploy a new bundle for all functions within the myFunctionFolder.functions folder',
@@ -559,7 +559,7 @@ exports.commands = {
559
559
  },
560
560
  server: {
561
561
  debug: {
562
- startingServer: functionPath => `Starting local test server for .functions folder with path: ${functionPath}`,
562
+ startingServer: (functionPath) => `Starting local test server for .functions folder with path: ${functionPath}`,
563
563
  },
564
564
  examples: {
565
565
  default: 'Run a local function test server.',
@@ -594,7 +594,7 @@ exports.commands = {
594
594
  logs: {
595
595
  removedRows: (deletedRowCount, tableId) => `Removed ${deletedRowCount} rows from HubDB table ${tableId}`,
596
596
  rowCount: (tableId, rowCount) => `HubDB table ${tableId} now contains ${rowCount} rows`,
597
- tableEmpty: tableId => `HubDB table ${tableId} is already empty`,
597
+ tableEmpty: (tableId) => `HubDB table ${tableId} is already empty`,
598
598
  },
599
599
  positionals: {
600
600
  tableId: {
@@ -606,7 +606,7 @@ exports.commands = {
606
606
  describe: 'Create a HubDB table.',
607
607
  enterPath: '[--path] Enter the local path to the file used for import:',
608
608
  errors: {
609
- create: filePath => `Creating the table at "${filePath}" failed`,
609
+ create: (filePath) => `Creating the table at "${filePath}" failed`,
610
610
  pathRequired: 'A path to a local file with a HubDB schema is required to create a HubDB table',
611
611
  invalidCharacters: 'The selected file path contains invalid characters. Please provide a new path and try again.',
612
612
  },
@@ -621,9 +621,9 @@ exports.commands = {
621
621
  },
622
622
  delete: {
623
623
  describe: 'Delete a HubDB table.',
624
- shouldDeleteTable: tableId => `Proceed with deleting HubDB table ${tableId}?`,
624
+ shouldDeleteTable: (tableId) => `Proceed with deleting HubDB table ${tableId}?`,
625
625
  errors: {
626
- delete: tableId => `Deleting the table ${tableId} failed`,
626
+ delete: (tableId) => `Deleting the table ${tableId} failed`,
627
627
  },
628
628
  positionals: {
629
629
  tableId: {
@@ -656,11 +656,11 @@ exports.commands = {
656
656
  },
657
657
  },
658
658
  init: {
659
- describe: configName => `Configure authentication for your HubSpot account. This will create a ${configName} file to store your account information.`,
659
+ describe: (configName) => `Configure authentication for your HubSpot account. This will create a ${configName} file to store your account information.`,
660
660
  options: {
661
661
  authType: {
662
662
  describe: 'Authentication mechanism',
663
- defaultDescription: authMethod => `"${authMethod}": An access token tied to a specific user account. This is the recommended way of authenticating with local development tools.`,
663
+ defaultDescription: (authMethod) => `"${authMethod}": An access token tied to a specific user account. This is the recommended way of authenticating with local development tools.`,
664
664
  },
665
665
  account: {
666
666
  describe: 'HubSpot account to authenticate',
@@ -670,20 +670,20 @@ exports.commands = {
670
670
  },
671
671
  },
672
672
  success: {
673
- configFileCreated: configPath => `Created config file "${configPath}"`,
673
+ configFileCreated: (configPath) => `Created config file "${configPath}"`,
674
674
  configFileUpdated: (account, authType) => `Connected account "${account}" using "${authType}" and set it as the default account`,
675
675
  },
676
676
  logs: {
677
677
  updateConfig: 'To update an existing config file, use the "hs auth" command.',
678
678
  },
679
679
  errors: {
680
- configFileExists: configPath => `The config file ${configPath} already exists.`,
681
- bothConfigFilesNotAllowed: path => `Unable to create config file, because there is an existing one at "${path}". To create a new config file, delete the existing one and try again.`,
680
+ configFileExists: (configPath) => `The config file ${configPath} already exists.`,
681
+ bothConfigFilesNotAllowed: (path) => `Unable to create config file, because there is an existing one at "${path}". To create a new config file, delete the existing one and try again.`,
682
682
  },
683
683
  },
684
684
  lint: {
685
- issuesFound: count => `${count} issues found.`,
686
- groupName: path => `Linting ${path}`,
685
+ issuesFound: (count) => `${count} issues found.`,
686
+ groupName: (path) => `Linting ${path}`,
687
687
  positionals: {
688
688
  path: {
689
689
  describe: 'Local folder to lint',
@@ -692,8 +692,8 @@ exports.commands = {
692
692
  },
693
693
  list: {
694
694
  describe: 'List remote contents of a directory.',
695
- gettingPathContents: path => `Getting contents of ${path}.`,
696
- noFilesFoundAtPath: path => `No files found in ${path}.`,
695
+ gettingPathContents: (path) => `Getting contents of ${path}.`,
696
+ noFilesFoundAtPath: (path) => `No files found in ${path}.`,
697
697
  positionals: {
698
698
  path: {
699
699
  describe: 'Remote directory to list contents',
@@ -756,6 +756,66 @@ exports.commands = {
756
756
  selectLink: 'Select a link to open',
757
757
  },
758
758
  project: {
759
+ profile: {
760
+ describe: 'Commands for managing project profiles',
761
+ verboseDescribe: `Commands for managing project profiles\n\nProfiles are stored at the root of your project's source directory and they make configuration dynamic. Use them to couple specialized configurations of your project to specific HubSpot accounts.\n\nRun ${(0, ui_1.uiCommandReference)('hs project profile add')} to get started!`,
762
+ add: {
763
+ describe: 'Add a new project profile',
764
+ verboseDescribe: `Add a new project profile\n\nProfiles enable you to reference variables in your component configuration files. Use the syntax ${chalk_1.default.bold('\${VARIABLE_NAME}')} to reference profile variables in your component configuration files. Then target the profile using the ${(0, ui_1.uiCommandReference)('--profile')} flag when you upload your project.`,
765
+ example: 'Add a new project profile named hsprofile.qa.json',
766
+ logs: {
767
+ copyExistingProfile: (profileName) => `Found an existing profile. We can copy the variables from ${chalk_1.default.bold(profileName)} into your new profile.`,
768
+ copyExistingProfiles: 'Found existing project profiles. We can copy the variables from one of them into your new profile.',
769
+ profileAdded: (profileName) => `Project profile ${chalk_1.default.bold(profileName)} was successfully added`,
770
+ },
771
+ prompts: {
772
+ namePrompt: '[name] Enter a name for the new project profile: ',
773
+ emptyName: 'Profile name cannot be empty',
774
+ targetAccountPrompt: '[target-account] Select a target account for this profile',
775
+ copyExistingProfilePrompt: 'Select a profile to copy variables from',
776
+ copyExistingProfilePromptEmpty: "Skip (don't copy any variables)",
777
+ invalidProfileName: 'Profile name cannot contain special characters or spaces',
778
+ },
779
+ errors: {
780
+ noProjectConfig: 'No project config found. Please run this command from a project directory.',
781
+ profileExists: (profileName) => `Profile ${chalk_1.default.bold(profileName)} already exists. Please choose a different name.`,
782
+ invalidTargetAccount: 'Target account is not configured in the CLI',
783
+ noAccountsConfigured: 'No accounts configured in the CLI',
784
+ failedToLoadProfile: (profileName) => `Unable to copy variables. Failed to load profile ${chalk_1.default.bold(profileName)}`,
785
+ failedToCreateProfile: 'Failed to create profile',
786
+ },
787
+ positionals: {
788
+ name: 'The name of the project profile',
789
+ },
790
+ options: {
791
+ targetAccount: 'The target account ID for this profile',
792
+ },
793
+ },
794
+ remove: {
795
+ describe: 'Remove an existing project profile',
796
+ example: 'Remove a project profile named hsprofile.qa.json',
797
+ logs: {
798
+ profileRemoved: (profileName) => `Project profile ${chalk_1.default.bold(profileName)} was successfully removed`,
799
+ removedProject: (accountId) => `Successfully removed the project from ${(0, ui_1.uiAccountDescription)(accountId)}`,
800
+ didNotRemoveProject: (accountId) => `Did not remove the project from ${(0, ui_1.uiAccountDescription)(accountId)}`,
801
+ },
802
+ debug: {
803
+ failedToLoadProfile: (profileName) => `Failed to load profile ${chalk_1.default.bold(profileName)}`,
804
+ },
805
+ prompts: {
806
+ removeProfilePrompt: 'Select a profile to remove from your project',
807
+ removeProjectPrompt: (accountId) => `Would you like to remove this project from ${(0, ui_1.uiAccountDescription)(accountId)}?`,
808
+ },
809
+ errors: {
810
+ noProjectConfig: 'No project config found. Please run this command from a project directory.',
811
+ noProfileFound: (profileName) => `No profile with filename ${chalk_1.default.bold(profileName)} found in your project.`,
812
+ failedToRemoveProfile: (profileName) => `Unable to remove profile ${chalk_1.default.bold(profileName)}. Please try again.`,
813
+ },
814
+ positionals: {
815
+ name: 'The name of the project profile',
816
+ },
817
+ },
818
+ },
759
819
  dev: {
760
820
  describe: 'Start local dev for the current project.',
761
821
  logs: {
@@ -766,9 +826,9 @@ exports.commands = {
766
826
  errors: {
767
827
  noProjectConfig: 'No project detected. Please run this command again from a project directory.',
768
828
  noAccount: (accountId, authCommand) => `An error occurred while reading account ${accountId} from your config. Run ${chalk_1.default.bold(authCommand)} to re-auth this account.`,
769
- noAccountsInConfig: authCommand => `No accounts found in your config. Run ${chalk_1.default.bold(authCommand)} to configure a HubSpot account with the CLI.`,
829
+ noAccountsInConfig: (authCommand) => `No accounts found in your config. Run ${chalk_1.default.bold(authCommand)} to configure a HubSpot account with the CLI.`,
770
830
  invalidProjectComponents: 'Projects cannot contain both private and public apps. Move your apps to separate projects before attempting local development.',
771
- noRunnableComponents: command => `No supported components were found in this project. Run ${chalk_1.default.bold(command)} to see a list of available components and add one to your project.`,
831
+ noRunnableComponents: (command) => `No supported components were found in this project. Run ${chalk_1.default.bold(command)} to see a list of available components and add one to your project.`,
772
832
  },
773
833
  examples: {
774
834
  default: 'Start local dev for the current project',
@@ -780,7 +840,7 @@ exports.commands = {
780
840
  failedToDownloadProject: 'Failed to download project. Please try again later.',
781
841
  invalidTemplateSource: 'Invalid template source provided. Use the format <Owner>/<Repo> and try again.',
782
842
  failedToFetchProjectList: 'Failed to fetch the list of available project templates. Please try again later.',
783
- cannotNestProjects: projectDir => `A project already exists at ${projectDir}. Projects cannot be nested within other projects. Please choose a different destination and try again.`,
843
+ cannotNestProjects: (projectDir) => `A project already exists at ${projectDir}. Projects cannot be nested within other projects. Please choose a different destination and try again.`,
784
844
  },
785
845
  logs: {
786
846
  success: (projectName, projectDest) => `Project ${chalk_1.default.bold(projectName)} was successfully created in ${projectDest}`,
@@ -848,7 +908,7 @@ exports.commands = {
848
908
  preamble: (platformVersion) => `This command will migrate an existing project to platformVersion ${platformVersion}. It will walk you through the fields required to complete the migration and download the new project source code into the project source directory. It will also copy all of your existing files to a new directory (archive) in case you need access to your old files later.`,
849
909
  describe: 'Migrate an existing project to the new version of the projects framework.',
850
910
  errors: {
851
- noProjectConfig: command => `No project detected. Please run this command again from a project directory. If you are trying to migrate an app, run ${command}`,
911
+ noProjectConfig: (command) => `No project detected. Please run this command again from a project directory. If you are trying to migrate an app, run ${command}`,
852
912
  },
853
913
  examples: {
854
914
  default: 'Migrate an existing project to the new version of the projects framework.',
@@ -870,13 +930,13 @@ exports.commands = {
870
930
  cloneStatus: {
871
931
  inProgress: () => `Cloning app configuration to ${chalk_1.default.bold('public-app.json')} component definition ...`,
872
932
  done: 'Cloning app configuration to public-app.json component definition ... DONE',
873
- success: dest => `Your cloned project was created in ${dest}`,
933
+ success: (dest) => `Your cloned project was created in ${dest}`,
874
934
  failure: 'Cloning app configuration to public-app.json component definition ... FAILED',
875
935
  },
876
936
  errors: {
877
937
  invalidAccountTypeTitle: () => `${chalk_1.default.bold('Developer account not targeted')}`,
878
938
  invalidAccountTypeDescription: (useCommand, authCommand) => `Only public apps created in a developer account can be converted to a project component. Select a connected developer account with ${useCommand} or ${authCommand} and try again.`,
879
- couldNotWriteConfigPath: configPath => `Failed to write project config at ${configPath}`,
939
+ couldNotWriteConfigPath: (configPath) => `Failed to write project config at ${configPath}`,
880
940
  },
881
941
  },
882
942
  add: {
@@ -889,8 +949,8 @@ exports.commands = {
889
949
  describe: "The path to the component type's location within the hubspot-project-components Github repo: https://github.com/HubSpot/hubspot-project-components",
890
950
  },
891
951
  },
892
- creatingComponent: projectName => `Adding a new component to ${chalk_1.default.bold(projectName)}`,
893
- success: componentName => `${componentName} was successfully added to your project.`,
952
+ creatingComponent: (projectName) => `Adding a new component to ${chalk_1.default.bold(projectName)}`,
953
+ success: (componentName) => `${componentName} was successfully added to your project.`,
894
954
  error: {
895
955
  failedToDownloadComponent: 'Failed to download project component. Please try again later.',
896
956
  locationInProject: 'This command must be run from within a project directory.',
@@ -906,10 +966,10 @@ exports.commands = {
906
966
  describe: 'Deploy a project build.',
907
967
  deployBuildIdPrompt: '[--build] Deploy which build?',
908
968
  debug: {
909
- deploying: path => `Deploying project at path: ${path}`,
969
+ deploying: (path) => `Deploying project at path: ${path}`,
910
970
  },
911
971
  errors: {
912
- deploy: details => `Deploy error: ${details}`,
972
+ deploy: (details) => `Deploy error: ${details}`,
913
973
  noBuilds: 'Deploy error: no builds for this project were found.',
914
974
  noBuildId: 'You must specify a build to deploy',
915
975
  projectNotFound: (projectName, accountIdentifier, command) => `The project ${chalk_1.default.bold(projectName)} does not exist in account ${accountIdentifier}. Run ${command} to upload your project files to HubSpot.`,
@@ -938,7 +998,7 @@ exports.commands = {
938
998
  showingRecentBuilds: (count, projectName, viewAllBuildsLink) => `Showing the most ${count} recent builds for ${projectName}. ${viewAllBuildsLink}.`,
939
999
  errors: {
940
1000
  noBuilds: 'No builds for this project were found.',
941
- projectNotFound: projectName => `Project ${projectName} not found.`,
1001
+ projectNotFound: (projectName) => `Project ${projectName} not found.`,
942
1002
  },
943
1003
  options: {
944
1004
  project: {
@@ -959,15 +1019,15 @@ exports.commands = {
959
1019
  failedToFetchProjectDetails: 'There was an error fetching project details',
960
1020
  noFunctionsLinkText: 'Visit developer docs',
961
1021
  noFunctionsInProject: `There aren't any functions in this project\n\t- Run ${(0, ui_1.uiCommandReference)('hs project logs --help')} to learn more about logs\n\t- ${(0, ui_1.uiLink)('Visit developer docs', 'https://developers.hubspot.com/docs/platform/serverless-functions')} to learn more about serverless functions`,
962
- noFunctionWithName: name => `No function with name "${name}"`,
963
- functionNotDeployed: name => `The function with name "${name}" is not deployed`,
1022
+ noFunctionWithName: (name) => `No function with name "${name}"`,
1023
+ functionNotDeployed: (name) => `The function with name "${name}" is not deployed`,
964
1024
  projectLogsManagerNotInitialized: 'Function called on ProjectLogsManager before initialization',
965
1025
  generic: 'Error fetching logs',
966
1026
  },
967
1027
  logs: {
968
1028
  showingLogs: 'Showing logs for:',
969
1029
  hubspotLogsDirectLink: 'View function logs in HubSpot',
970
- noLogsFound: name => `No logs were found for "${name}"`,
1030
+ noLogsFound: (name) => `No logs were found for "${name}"`,
971
1031
  },
972
1032
  table: {
973
1033
  accountHeader: 'Account',
@@ -1005,10 +1065,10 @@ exports.commands = {
1005
1065
  default: 'Upload a project into your HubSpot account',
1006
1066
  },
1007
1067
  logs: {
1008
- buildSucceeded: buildId => `Build #${buildId} succeeded\n`,
1068
+ buildSucceeded: (buildId) => `Build #${buildId} succeeded\n`,
1009
1069
  readyToGoLive: '🚀 Ready to take your project live?',
1010
- runCommand: command => `Run \`${command}\``,
1011
- autoDeployDisabled: deployCommand => `Automatic deploys are disabled for this project. Run ${deployCommand} to deploy this build.`,
1070
+ runCommand: (command) => `Run \`${command}\``,
1071
+ autoDeployDisabled: (deployCommand) => `Automatic deploys are disabled for this project. Run ${deployCommand} to deploy this build.`,
1012
1072
  },
1013
1073
  errors: {
1014
1074
  projectLockedError: () => `Your project is locked. This may mean that another user is running the ${chalk_1.default.bold('`hs project dev`')} command for this project. If this is you, unlock the project in Projects UI.`,
@@ -1032,9 +1092,9 @@ exports.commands = {
1032
1092
  watchCancelledFromUi: `The watch process has been cancelled from the UI. Any changes made since cancelling have not been uploaded. To resume watching, rerun ${(0, ui_1.uiCommandReference)('hs project watch')}.`,
1033
1093
  resuming: 'Resuming watcher...',
1034
1094
  uploadSucceeded: (remotePath, filePath) => `Uploaded file "${filePath}" to "${remotePath}"`,
1035
- deleteFileSucceeded: remotePath => `Deleted file "${remotePath}"`,
1036
- deleteFolderSucceeded: remotePath => `Deleted folder "${remotePath}"`,
1037
- watching: projectDir => `Watcher is ready and watching "${projectDir}". Any changes detected will be automatically uploaded.`,
1095
+ deleteFileSucceeded: (remotePath) => `Deleted file "${remotePath}"`,
1096
+ deleteFolderSucceeded: (remotePath) => `Deleted folder "${remotePath}"`,
1097
+ watching: (projectDir) => `Watcher is ready and watching "${projectDir}". Any changes detected will be automatically uploaded.`,
1038
1098
  previousStagingBuildCancelled: 'Killed the previous watch process. Please try running `hs project watch` again',
1039
1099
  },
1040
1100
  options: {
@@ -1045,18 +1105,18 @@ exports.commands = {
1045
1105
  debug: {
1046
1106
  pause: 'Pausing watcher, attempting to queue build',
1047
1107
  buildStarted: 'Build queued.',
1048
- extensionNotAllowed: filePath => `Skipping "${filePath}" due to unsupported extension`,
1049
- ignored: filePath => `Skipping "${filePath}" due to an ignore rule`,
1108
+ extensionNotAllowed: (filePath) => `Skipping "${filePath}" due to unsupported extension`,
1109
+ ignored: (filePath) => `Skipping "${filePath}" due to an ignore rule`,
1050
1110
  uploading: (filePath, remotePath) => `Attempting to upload file "${filePath}" to "${remotePath}"`,
1051
1111
  attemptNewBuild: 'Attempting to create a new build',
1052
- fileAlreadyQueued: filePath => `File "${filePath}" is already queued for upload`,
1112
+ fileAlreadyQueued: (filePath) => `File "${filePath}" is already queued for upload`,
1053
1113
  },
1054
1114
  errors: {
1055
1115
  projectConfigNotFound: 'No project config found. Please ensure that you are in a project directory.',
1056
1116
  projectLockedError: `Your project is locked. This may mean that another user is running the ${chalk_1.default.bold(`hs project dev`)} command for this project. If this is you, unlock the project in Projects UI.`,
1057
1117
  uploadFailed: (remotePath, filePath) => `Failed to upload file "${filePath}" to "${remotePath}"`,
1058
- deleteFileFailed: remotePath => `Failed to delete file "${remotePath}"`,
1059
- deleteFolderFailed: remotePath => `Failed to delete folder "${remotePath}"`,
1118
+ deleteFileFailed: (remotePath) => `Failed to delete file "${remotePath}"`,
1119
+ deleteFolderFailed: (remotePath) => `Failed to delete folder "${remotePath}"`,
1060
1120
  },
1061
1121
  },
1062
1122
  download: {
@@ -1097,25 +1157,13 @@ exports.commands = {
1097
1157
  examples: {
1098
1158
  default: 'Opens the projects page for the specified account',
1099
1159
  },
1100
- success: projectName => `Successfully opened "${projectName}"`,
1160
+ success: (projectName) => `Successfully opened "${projectName}"`,
1101
1161
  },
1102
1162
  feedback: {
1103
- describe: 'Leave feedback on HubSpot projects or file a bug report.',
1104
- feedbackType: {
1105
- prompt: 'What type of feedback would you like to leave?',
1106
- bug: '[--bug] Report a bug',
1107
- general: "[--general] Tell us about your experience with HubSpot's developer tools",
1108
- },
1109
- openPrompt: 'Create a Github issue in your browser?',
1110
- success: url => `We opened ${url} in your browser.`,
1111
- options: {
1112
- bug: {
1113
- describe: 'Open Github issues in your browser to report a bug.',
1114
- },
1115
- general: {
1116
- describe: 'Open Github issues in your browser to give feedback.',
1117
- },
1118
- },
1163
+ describe: 'Leave feedback or file a bug report.',
1164
+ openPrompt: 'Open the feedback form in your browser?',
1165
+ success: (url) => `We opened ${(0, ui_1.uiLink)('the developer feedback form', url)} in your browser.`,
1166
+ error: (url) => `Navigate to ${(0, ui_1.uiLink)('the developer feedback form', url)} to leave feedback.`,
1119
1167
  },
1120
1168
  installDeps: {
1121
1169
  help: {
@@ -1125,10 +1173,10 @@ exports.commands = {
1125
1173
  },
1126
1174
  installLocationPrompt: 'Choose the project components to install the dependencies:',
1127
1175
  installLocationPromptRequired: 'You must choose at least one subcomponent',
1128
- installingDependencies: directory => `Installing dependencies in ${directory}`,
1129
- installationSuccessful: directory => `Installed dependencies in ${directory}`,
1176
+ installingDependencies: (directory) => `Installing dependencies in ${directory}`,
1177
+ installationSuccessful: (directory) => `Installed dependencies in ${directory}`,
1130
1178
  addingDependenciesToLocation: (dependencies, directory) => `Installing ${dependencies} in ${directory}`,
1131
- installingDependenciesFailed: directory => `Installing dependencies for ${directory} failed`,
1179
+ installingDependenciesFailed: (directory) => `Installing dependencies for ${directory} failed`,
1132
1180
  noProjectConfig: 'No project detected. Run this command from a project directory.',
1133
1181
  noPackageJsonInProject: (projectName, link) => `No dependencies to install. The project ${projectName} folder might be missing component or subcomponent files. ${link}`,
1134
1182
  packageManagerNotInstalled: (packageManager, link) => `This command depends on ${packageManager}, install ${chalk_1.default.bold(link)}`,
@@ -1152,8 +1200,8 @@ exports.commands = {
1152
1200
  create: {
1153
1201
  developer: {
1154
1202
  loading: {
1155
- add: accountName => `Creating developer sandbox ${chalk_1.default.bold(accountName)}`,
1156
- fail: accountName => `Failed to create a developer sandbox ${chalk_1.default.bold(accountName)}.`,
1203
+ add: (accountName) => `Creating developer sandbox ${chalk_1.default.bold(accountName)}`,
1204
+ fail: (accountName) => `Failed to create a developer sandbox ${chalk_1.default.bold(accountName)}.`,
1157
1205
  succeed: (accountName, accountId) => `Successfully created a developer sandbox ${chalk_1.default.bold(accountName)} with portalId ${chalk_1.default.bold(accountId)}.`,
1158
1206
  },
1159
1207
  success: {
@@ -1171,8 +1219,8 @@ exports.commands = {
1171
1219
  },
1172
1220
  standard: {
1173
1221
  loading: {
1174
- add: accountName => `Creating standard sandbox ${chalk_1.default.bold(accountName)}`,
1175
- fail: accountName => `Failed to create a standard sandbox ${chalk_1.default.bold(accountName)}.`,
1222
+ add: (accountName) => `Creating standard sandbox ${chalk_1.default.bold(accountName)}`,
1223
+ fail: (accountName) => `Failed to create a standard sandbox ${chalk_1.default.bold(accountName)}.`,
1176
1224
  succeed: (accountName, accountId) => `Successfully created a standard sandbox ${chalk_1.default.bold(accountName)} with portalId ${chalk_1.default.bold(accountId)}.`,
1177
1225
  },
1178
1226
  success: {
@@ -1192,14 +1240,14 @@ exports.commands = {
1192
1240
  delete: {
1193
1241
  describe: 'Delete a sandbox account.',
1194
1242
  debug: {
1195
- deleting: account => `Deleting sandbox account "${account}"`,
1243
+ deleting: (account) => `Deleting sandbox account "${account}"`,
1196
1244
  error: 'Error deleting sandbox account:',
1197
1245
  },
1198
1246
  examples: {
1199
1247
  default: 'Deletes the sandbox account named MySandboxAccount.',
1200
1248
  },
1201
- confirm: account => `Delete sandbox ${chalk_1.default.bold(account)}? All data for this sandbox will be permanently deleted.`,
1202
- defaultAccountWarning: account => `The sandbox ${chalk_1.default.bold(account)} is currently set as the default account.`,
1249
+ confirm: (account) => `Delete sandbox ${chalk_1.default.bold(account)}? All data for this sandbox will be permanently deleted.`,
1250
+ defaultAccountWarning: (account) => `The sandbox ${chalk_1.default.bold(account)} is currently set as the default account.`,
1203
1251
  success: {
1204
1252
  delete: (account, sandboxHubId) => `Sandbox "${account}" with portalId "${sandboxHubId}" was deleted successfully.`,
1205
1253
  deleteDefault: (account, sandboxHubId) => `Sandbox "${account}" with portalId "${sandboxHubId}" was deleted successfully and removed as the default account.`,
@@ -1208,10 +1256,10 @@ exports.commands = {
1208
1256
  failure: {
1209
1257
  invalidUser: (accountName, parentAccountName) => `Couldn't delete ${accountName} because your account has been removed from ${parentAccountName} or your permission set doesn't allow you to delete the sandbox. To update your permissions, contact a super admin in ${parentAccountName}.`,
1210
1258
  noAccount: 'No account specified. Specify an account by using the --account flag.',
1211
- noSandboxAccounts: authCommand => `There are no sandboxes connected to the CLI. To add a sandbox, run ${authCommand}.`,
1259
+ noSandboxAccounts: (authCommand) => `There are no sandboxes connected to the CLI. To add a sandbox, run ${authCommand}.`,
1212
1260
  noSandboxAccountId: "This sandbox can't be deleted from the CLI because we could not find the associated sandbox account.",
1213
- noParentAccount: authCommand => `This sandbox can't be deleted from the CLI because you haven't given the CLI access to its parent account. To do this, run ${authCommand} and add the parent account.`,
1214
- objectNotFound: account => `Sandbox ${chalk_1.default.bold(account)} may have been deleted through the UI. The account has been removed from the config.`,
1261
+ noParentAccount: (authCommand) => `This sandbox can't be deleted from the CLI because you haven't given the CLI access to its parent account. To do this, run ${authCommand} and add the parent account.`,
1262
+ objectNotFound: (account) => `Sandbox ${chalk_1.default.bold(account)} may have been deleted through the UI. The account has been removed from the config.`,
1215
1263
  noParentPortalAvailable: (command, url) => `This sandbox can't be deleted from the CLI because you haven't given the CLI access to its parent account. To do this, run ${command}. You can also delete the sandbox from the HubSpot management tool: ${chalk_1.default.bold(url)}.`,
1216
1264
  invalidKey: (account, authCommand) => `Your personal access key for account ${chalk_1.default.bold(account)} is inactive. To re-authenticate, please run ${authCommand}.`,
1217
1265
  },
@@ -1227,9 +1275,9 @@ exports.commands = {
1227
1275
  },
1228
1276
  sync: {
1229
1277
  loading: {
1230
- add: accountName => `Syncing sandbox ${chalk_1.default.bold(accountName)}`,
1231
- fail: accountName => `Failed to sync sandbox ${chalk_1.default.bold(accountName)}.`,
1232
- succeed: accountName => `Successfully synced sandbox ${chalk_1.default.bold(accountName)}.`,
1278
+ add: (accountName) => `Syncing sandbox ${chalk_1.default.bold(accountName)}`,
1279
+ fail: (accountName) => `Failed to sync sandbox ${chalk_1.default.bold(accountName)}.`,
1280
+ succeed: (accountName) => `Successfully synced sandbox ${chalk_1.default.bold(accountName)}.`,
1233
1281
  },
1234
1282
  success: {
1235
1283
  configFileUpdated: (accountName, authType) => `Account "${accountName}" updated using "${authType}"`,
@@ -1249,7 +1297,7 @@ exports.commands = {
1249
1297
  add: {
1250
1298
  describe: 'Create a new secret.',
1251
1299
  errors: {
1252
- add: secretName => `The secret "${secretName}" was not added`,
1300
+ add: (secretName) => `The secret "${secretName}" was not added`,
1253
1301
  alreadyExists: (secretName, command) => `The secret "${secretName}" already exists, it's value can be modified with ${command}`,
1254
1302
  },
1255
1303
  positionals: {
@@ -1265,10 +1313,10 @@ exports.commands = {
1265
1313
  describe: 'Delete a secret.',
1266
1314
  selectSecret: 'Select the secret you want to delete',
1267
1315
  deleteCanceled: 'Delete canceled',
1268
- confirmDelete: secretName => `Are you sure you want to delete the secret "${secretName}"?`,
1316
+ confirmDelete: (secretName) => `Are you sure you want to delete the secret "${secretName}"?`,
1269
1317
  errors: {
1270
- delete: secretName => `The secret "${secretName}" was not deleted`,
1271
- noSecret: secretName => `Unable to delete secret with name "${secretName}", it does not exist`,
1318
+ delete: (secretName) => `The secret "${secretName}" was not deleted`,
1319
+ noSecret: (secretName) => `Unable to delete secret with name "${secretName}", it does not exist`,
1272
1320
  },
1273
1321
  positionals: {
1274
1322
  name: {
@@ -1284,14 +1332,14 @@ exports.commands = {
1284
1332
  errors: {
1285
1333
  list: 'The secrets could not be listed',
1286
1334
  },
1287
- groupLabel: accountIdentifier => `Secrets for account ${accountIdentifier}:`,
1335
+ groupLabel: (accountIdentifier) => `Secrets for account ${accountIdentifier}:`,
1288
1336
  },
1289
1337
  update: {
1290
1338
  describe: 'Update an existing secret.',
1291
1339
  selectSecret: 'Select the secret you want to update',
1292
1340
  errors: {
1293
- update: secretName => `The secret "${secretName}" was not updated`,
1294
- noSecret: secretName => `Unable to update secret with name "${secretName}", it does not exist`,
1341
+ update: (secretName) => `The secret "${secretName}" was not updated`,
1342
+ noSecret: (secretName) => `Unable to update secret with name "${secretName}", it does not exist`,
1295
1343
  },
1296
1344
  positionals: {
1297
1345
  name: {
@@ -1311,7 +1359,7 @@ exports.commands = {
1311
1359
  generateSelectors: {
1312
1360
  describe: 'Automatically generates an editor-preview.json file for the given theme. The selectors this command generates are not perfect, so please edit editor-preview.json after running.',
1313
1361
  errors: {
1314
- invalidPath: themePath => `Could not find directory "${themePath}"`,
1362
+ invalidPath: (themePath) => `Could not find directory "${themePath}"`,
1315
1363
  fieldsNotFound: "Unable to find theme's fields.json.",
1316
1364
  noSelectorsFound: 'No selectors found.',
1317
1365
  },
@@ -1325,17 +1373,17 @@ exports.commands = {
1325
1373
  marketplaceValidate: {
1326
1374
  describe: 'Validate a theme for the marketplace.',
1327
1375
  errors: {
1328
- invalidPath: path => `The path "${path}" is not a path to a folder in the Design Manager`,
1376
+ invalidPath: (path) => `The path "${path}" is not a path to a folder in the Design Manager`,
1329
1377
  },
1330
1378
  logs: {
1331
- validatingTheme: path => `Validating theme "${path}" \n`,
1379
+ validatingTheme: (path) => `Validating theme "${path}" \n`,
1332
1380
  },
1333
1381
  results: {
1334
1382
  required: 'Required validation results:',
1335
1383
  recommended: 'Recommended validation results:',
1336
1384
  warnings: {
1337
- file: file => `File: ${file}`,
1338
- lineNumber: line => `Line number: ${line}`,
1385
+ file: (file) => `File: ${file}`,
1386
+ lineNumber: (line) => `Line number: ${line}`,
1339
1387
  },
1340
1388
  noErrors: 'No errors',
1341
1389
  },
@@ -1348,7 +1396,7 @@ exports.commands = {
1348
1396
  preview: {
1349
1397
  describe: 'Upload and watch a theme directory on your computer for changes and start a local development server to preview theme changes on a site.',
1350
1398
  errors: {
1351
- invalidPath: path => `The path "${path}" is not a path to a directory`,
1399
+ invalidPath: (path) => `The path "${path}" is not a path to a directory`,
1352
1400
  noThemeComponents: 'Your project has no theme components available to preview.',
1353
1401
  },
1354
1402
  positionals: {
@@ -1387,10 +1435,10 @@ exports.commands = {
1387
1435
  marketplaceValidate: {
1388
1436
  describe: 'Validate a module for the marketplace. Make sure to include the suffix .module in the path to the module within the Design Manager.',
1389
1437
  errors: {
1390
- invalidPath: path => `The path "${path}" is not a path to a module within the Design Manager.`,
1438
+ invalidPath: (path) => `The path "${path}" is not a path to a module within the Design Manager.`,
1391
1439
  },
1392
1440
  logs: {
1393
- validatingModule: path => `Validating module "${path}" \n`,
1441
+ validatingModule: (path) => `Validating module "${path}" \n`,
1394
1442
  },
1395
1443
  options: {
1396
1444
  json: {
@@ -1401,8 +1449,8 @@ exports.commands = {
1401
1449
  required: 'Required validation results:',
1402
1450
  recommended: 'Recommended validation results:',
1403
1451
  warnings: {
1404
- file: file => `File: ${file}`,
1405
- lineNumber: line => `Line number: ${line}`,
1452
+ file: (file) => `File: ${file}`,
1453
+ lineNumber: (line) => `Line number: ${line}`,
1406
1454
  },
1407
1455
  noErrors: 'No errors',
1408
1456
  },
@@ -1418,10 +1466,10 @@ exports.commands = {
1418
1466
  describe: 'Upload a folder or file from your computer to the HubSpot CMS.',
1419
1467
  errors: {
1420
1468
  destinationRequired: 'A destination path needs to be passed',
1421
- fileIgnored: path => `The file "${path}" is being ignored via an .hsignore rule`,
1422
- invalidPath: path => `The path "${path}" is not a path to a file or folder`,
1469
+ fileIgnored: (path) => `The file "${path}" is being ignored via an .hsignore rule`,
1470
+ invalidPath: (path) => `The path "${path}" is not a path to a file or folder`,
1423
1471
  uploadFailed: (src, dest) => `Uploading file "${src}" to "${dest}" failed`,
1424
- someFilesFailed: dest => `One or more files failed to upload to "${dest}" in the Design Manager`,
1472
+ someFilesFailed: (dest) => `One or more files failed to upload to "${dest}" in the Design Manager`,
1425
1473
  deleteFailed: (path, accountId) => `Deleting "${path}" from account ${accountId} failed`,
1426
1474
  },
1427
1475
  options: {
@@ -1441,7 +1489,7 @@ exports.commands = {
1441
1489
  describe: 'Skips confirmation prompts when doing a clean upload.',
1442
1490
  },
1443
1491
  },
1444
- previewUrl: previewUrl => `To preview this theme, visit: ${previewUrl}`,
1492
+ previewUrl: (previewUrl) => `To preview this theme, visit: ${previewUrl}`,
1445
1493
  positionals: {
1446
1494
  src: {
1447
1495
  describe: 'Path to the local file, relative to your current working directory.',
@@ -1452,10 +1500,10 @@ exports.commands = {
1452
1500
  },
1453
1501
  success: {
1454
1502
  fileUploaded: (src, dest, accountId) => `Uploaded file from "${src}" to "${dest}" in the Design Manager of account ${accountId}`,
1455
- uploadComplete: dest => `Uploading files to "${dest}" in the Design Manager is complete`,
1503
+ uploadComplete: (dest) => `Uploading files to "${dest}" in the Design Manager is complete`,
1456
1504
  },
1457
1505
  uploading: (src, dest, accountId) => `Uploading files from "${src}" to "${dest}" in the Design Manager of account ${accountId}`,
1458
- notUploaded: src => `There was an error processing "${src}". The file has not been uploaded.`,
1506
+ notUploaded: (src) => `There was an error processing "${src}". The file has not been uploaded.`,
1459
1507
  cleaning: (filePath, accountId) => `Removing "${filePath}" from account ${accountId} and uploading local...`,
1460
1508
  confirmCleanUpload: (filePath, accountId) => `You are about to delete the directory "${filePath}" and its contents on HubSpot account ${accountId} before uploading. This will also clear the global content associated with any global partial templates and modules. Are you sure you want to do this?`,
1461
1509
  },
@@ -1465,7 +1513,7 @@ exports.commands = {
1465
1513
  folderFailed: (src, dest, accountId) => `Initial uploading of folder "${src}" to "${dest}" in account ${accountId} had failures`,
1466
1514
  fileFailed: (file, dest, accountId) => `Upload of file "${file}" to "${dest}" in account ${accountId} failed`,
1467
1515
  destinationRequired: 'A destination directory needs to be passed',
1468
- invalidPath: path => `The "${path}" is not a path to a directory`,
1516
+ invalidPath: (path) => `The "${path}" is not a path to a directory`,
1469
1517
  },
1470
1518
  options: {
1471
1519
  disableInitial: {
@@ -1501,7 +1549,7 @@ exports.commands = {
1501
1549
  warnings: {
1502
1550
  disableInitial: () => `Passing the "${chalk_1.default.bold('--disable-initial')}" option is no longer necessary. Running "${chalk_1.default.bold('hs watch')}" no longer uploads the watched directory by default.`,
1503
1551
  initialUpload: () => `To upload the directory run "${chalk_1.default.bold('hs upload')}" beforehand or add the "${chalk_1.default.bold('--initial-upload')}" option when running "${chalk_1.default.bold('hs watch')}".`,
1504
- notUploaded: path => `The "${chalk_1.default.bold('hs watch')}" command no longer uploads the watched directory when started. The directory "${path}" was not uploaded.`,
1552
+ notUploaded: (path) => `The "${chalk_1.default.bold('hs watch')}" command no longer uploads the watched directory when started. The directory "${path}" was not uploaded.`,
1505
1553
  },
1506
1554
  },
1507
1555
  convertFields: {
@@ -1517,16 +1565,16 @@ exports.commands = {
1517
1565
  },
1518
1566
  },
1519
1567
  errors: {
1520
- invalidPath: path => `The path "${path}" specified in the "--src" flag is not a path to a file or directory`,
1568
+ invalidPath: (path) => `The path "${path}" specified in the "--src" flag is not a path to a file or directory`,
1521
1569
  missingSrc: 'Please specify the path to your javascript fields file or directory with the --src flag.',
1522
1570
  },
1523
1571
  },
1524
1572
  secrets: {
1525
1573
  add: {
1526
1574
  loading: {
1527
- add: secretName => `Adding secret ${chalk_1.default.bold(secretName)}`,
1528
- fail: secretName => `Failed to add secret ${chalk_1.default.bold(secretName)}.`,
1529
- succeed: secretName => `Successfully added secret ${chalk_1.default.bold(secretName)}.`,
1575
+ add: (secretName) => `Adding secret ${chalk_1.default.bold(secretName)}`,
1576
+ fail: (secretName) => `Failed to add secret ${chalk_1.default.bold(secretName)}.`,
1577
+ succeed: (secretName) => `Successfully added secret ${chalk_1.default.bold(secretName)}.`,
1530
1578
  },
1531
1579
  success: {
1532
1580
  configFileUpdated: (secretName, authType) => `Secret "${secretName}" updated using "${authType}"`,
@@ -1541,9 +1589,9 @@ exports.commands = {
1541
1589
  },
1542
1590
  delete: {
1543
1591
  loading: {
1544
- add: secretName => `Deleting secret ${chalk_1.default.bold(secretName)}`,
1545
- fail: secretName => `Failed to delete secret ${chalk_1.default.bold(secretName)}.`,
1546
- succeed: secretName => `Successfully deleted secret ${chalk_1.default.bold(secretName)}.`,
1592
+ add: (secretName) => `Deleting secret ${chalk_1.default.bold(secretName)}`,
1593
+ fail: (secretName) => `Failed to delete secret ${chalk_1.default.bold(secretName)}.`,
1594
+ succeed: (secretName) => `Successfully deleted secret ${chalk_1.default.bold(secretName)}.`,
1547
1595
  },
1548
1596
  success: {
1549
1597
  configFileUpdated: (secretName, authType) => `Secret "${secretName}" updated using "${authType}"`,
@@ -1563,13 +1611,13 @@ exports.commands = {
1563
1611
  succeed: () => `Successfully listed secrets.`,
1564
1612
  },
1565
1613
  success: {
1566
- configFileUpdated: authType => `Secrets updated using "${authType}"`,
1614
+ configFileUpdated: (authType) => `Secrets updated using "${authType}"`,
1567
1615
  },
1568
1616
  failure: {
1569
- invalidUser: parentAccountName => `Couldn't list secrets because your account has been removed from ${chalk_1.default.bold(parentAccountName)} or your permission set doesn't allow you to list secrets. To update your permissions, contact a super admin in ${chalk_1.default.bold(parentAccountName)}.`,
1617
+ invalidUser: (parentAccountName) => `Couldn't list secrets because your account has been removed from ${chalk_1.default.bold(parentAccountName)} or your permission set doesn't allow you to list secrets. To update your permissions, contact a super admin in ${chalk_1.default.bold(parentAccountName)}.`,
1570
1618
  scopes: {
1571
1619
  message: "The personal access key you provided doesn't include secrets permissions.",
1572
- instructions: url => `To update CLI permissions: \n- Go to ${url}, deactivate the existing personal access key, and create a new one that includes secrets permissions. \n- Update the CLI config for this account by running ${chalk_1.default.bold('hs auth')} and entering the new key.\n`,
1620
+ instructions: (url) => `To update CLI permissions: \n- Go to ${url}, deactivate the existing personal access key, and create a new one that includes secrets permissions. \n- Update the CLI config for this account by running ${chalk_1.default.bold('hs auth')} and entering the new key.\n`,
1573
1621
  },
1574
1622
  },
1575
1623
  },
@@ -1577,9 +1625,9 @@ exports.commands = {
1577
1625
  serverless: {
1578
1626
  add: {
1579
1627
  loading: {
1580
- add: functionName => `Adding serverless function ${chalk_1.default.bold(functionName)}`,
1581
- fail: functionName => `Failed to add serverless function ${chalk_1.default.bold(functionName)}.`,
1582
- succeed: functionName => `Successfully added serverless function ${chalk_1.default.bold(functionName)}.`,
1628
+ add: (functionName) => `Adding serverless function ${chalk_1.default.bold(functionName)}`,
1629
+ fail: (functionName) => `Failed to add serverless function ${chalk_1.default.bold(functionName)}.`,
1630
+ succeed: (functionName) => `Successfully added serverless function ${chalk_1.default.bold(functionName)}.`,
1583
1631
  },
1584
1632
  success: {
1585
1633
  configFileUpdated: (functionName, authType) => `Serverless function "${functionName}" updated using "${authType}"`,
@@ -1594,9 +1642,9 @@ exports.commands = {
1594
1642
  },
1595
1643
  delete: {
1596
1644
  loading: {
1597
- add: functionName => `Deleting serverless function ${chalk_1.default.bold(functionName)}`,
1598
- fail: functionName => `Failed to delete serverless function ${chalk_1.default.bold(functionName)}.`,
1599
- succeed: functionName => `Successfully deleted serverless function ${chalk_1.default.bold(functionName)}.`,
1645
+ add: (functionName) => `Deleting serverless function ${chalk_1.default.bold(functionName)}`,
1646
+ fail: (functionName) => `Failed to delete serverless function ${chalk_1.default.bold(functionName)}.`,
1647
+ succeed: (functionName) => `Successfully deleted serverless function ${chalk_1.default.bold(functionName)}.`,
1600
1648
  },
1601
1649
  success: {
1602
1650
  configFileUpdated: (functionName, authType) => `Serverless function "${functionName}" updated using "${authType}"`,
@@ -1616,13 +1664,13 @@ exports.commands = {
1616
1664
  succeed: () => `Successfully listed serverless functions.`,
1617
1665
  },
1618
1666
  success: {
1619
- configFileUpdated: authType => `Serverless functions updated using "${authType}"`,
1667
+ configFileUpdated: (authType) => `Serverless functions updated using "${authType}"`,
1620
1668
  },
1621
1669
  failure: {
1622
- invalidUser: parentAccountName => `Couldn't list serverless functions because your account has been removed from ${chalk_1.default.bold(parentAccountName)} or your permission set doesn't allow you to list serverless functions. To update your permissions, contact a super admin in ${chalk_1.default.bold(parentAccountName)}.`,
1670
+ invalidUser: (parentAccountName) => `Couldn't list serverless functions because your account has been removed from ${chalk_1.default.bold(parentAccountName)} or your permission set doesn't allow you to list serverless functions. To update your permissions, contact a super admin in ${chalk_1.default.bold(parentAccountName)}.`,
1623
1671
  scopes: {
1624
1672
  message: "The personal access key you provided doesn't include serverless function permissions.",
1625
- instructions: url => `To update CLI permissions: \n- Go to ${url}, deactivate the existing personal access key, and create a new one that includes serverless function permissions. \n- Update the CLI config for this account by running ${chalk_1.default.bold('hs auth')} and entering the new key.\n`,
1673
+ instructions: (url) => `To update CLI permissions: \n- Go to ${url}, deactivate the existing personal access key, and create a new one that includes serverless function permissions. \n- Update the CLI config for this account by running ${chalk_1.default.bold('hs auth')} and entering the new key.\n`,
1626
1674
  },
1627
1675
  },
1628
1676
  },
@@ -1630,9 +1678,9 @@ exports.commands = {
1630
1678
  serverlessFunctionLogs: {
1631
1679
  add: {
1632
1680
  loading: {
1633
- add: functionName => `Adding serverless function logs ${chalk_1.default.bold(functionName)}`,
1634
- fail: functionName => `Failed to add serverless function logs ${chalk_1.default.bold(functionName)}.`,
1635
- succeed: functionName => `Successfully added serverless function logs ${chalk_1.default.bold(functionName)}.`,
1681
+ add: (functionName) => `Adding serverless function logs ${chalk_1.default.bold(functionName)}`,
1682
+ fail: (functionName) => `Failed to add serverless function logs ${chalk_1.default.bold(functionName)}.`,
1683
+ succeed: (functionName) => `Successfully added serverless function logs ${chalk_1.default.bold(functionName)}.`,
1636
1684
  },
1637
1685
  success: {
1638
1686
  configFileUpdated: (functionName, authType) => `Serverless function logs "${functionName}" updated using "${authType}"`,
@@ -1647,9 +1695,9 @@ exports.commands = {
1647
1695
  },
1648
1696
  delete: {
1649
1697
  loading: {
1650
- add: functionName => `Deleting serverless function logs ${chalk_1.default.bold(functionName)}`,
1651
- fail: functionName => `Failed to delete serverless function logs ${chalk_1.default.bold(functionName)}.`,
1652
- succeed: functionName => `Successfully deleted serverless function logs ${chalk_1.default.bold(functionName)}.`,
1698
+ add: (functionName) => `Deleting serverless function logs ${chalk_1.default.bold(functionName)}`,
1699
+ fail: (functionName) => `Failed to delete serverless function logs ${chalk_1.default.bold(functionName)}.`,
1700
+ succeed: (functionName) => `Successfully deleted serverless function logs ${chalk_1.default.bold(functionName)}.`,
1653
1701
  },
1654
1702
  success: {
1655
1703
  configFileUpdated: (functionName, authType) => `Serverless function logs "${functionName}" updated using "${authType}"`,
@@ -1669,13 +1717,13 @@ exports.commands = {
1669
1717
  succeed: () => `Successfully listed serverless function logs.`,
1670
1718
  },
1671
1719
  success: {
1672
- configFileUpdated: authType => `Serverless function logs updated using "${authType}"`,
1720
+ configFileUpdated: (authType) => `Serverless function logs updated using "${authType}"`,
1673
1721
  },
1674
1722
  failure: {
1675
- invalidUser: parentAccountName => `Couldn't list serverless function logs because your account has been removed from ${chalk_1.default.bold(parentAccountName)} or your permission set doesn't allow you to list serverless function logs. To update your permissions, contact a super admin in ${chalk_1.default.bold(parentAccountName)}.`,
1723
+ invalidUser: (parentAccountName) => `Couldn't list serverless function logs because your account has been removed from ${chalk_1.default.bold(parentAccountName)} or your permission set doesn't allow you to list serverless function logs. To update your permissions, contact a super admin in ${chalk_1.default.bold(parentAccountName)}.`,
1676
1724
  scopes: {
1677
1725
  message: "The personal access key you provided doesn't include serverless function log permissions.",
1678
- instructions: url => `To update CLI permissions: \n- Go to ${url}, deactivate the existing personal access key, and create a new one that includes serverless function log permissions. \n- Update the CLI config for this account by running ${chalk_1.default.bold('hs auth')} and entering the new key.\n`,
1726
+ instructions: (url) => `To update CLI permissions: \n- Go to ${url}, deactivate the existing personal access key, and create a new one that includes serverless function log permissions. \n- Update the CLI config for this account by running ${chalk_1.default.bold('hs auth')} and entering the new key.\n`,
1679
1727
  },
1680
1728
  },
1681
1729
  },
@@ -1683,9 +1731,9 @@ exports.commands = {
1683
1731
  serverlessFunctionMetrics: {
1684
1732
  add: {
1685
1733
  loading: {
1686
- add: functionName => `Adding serverless function metrics ${chalk_1.default.bold(functionName)}`,
1687
- fail: functionName => `Failed to add serverless function metrics ${chalk_1.default.bold(functionName)}.`,
1688
- succeed: functionName => `Successfully added serverless function metrics ${chalk_1.default.bold(functionName)}.`,
1734
+ add: (functionName) => `Adding serverless function metrics ${chalk_1.default.bold(functionName)}`,
1735
+ fail: (functionName) => `Failed to add serverless function metrics ${chalk_1.default.bold(functionName)}.`,
1736
+ succeed: (functionName) => `Successfully added serverless function metrics ${chalk_1.default.bold(functionName)}.`,
1689
1737
  },
1690
1738
  success: {
1691
1739
  configFileUpdated: (functionName, authType) => `Serverless function metrics "${functionName}" updated using "${authType}"`,
@@ -1700,9 +1748,9 @@ exports.commands = {
1700
1748
  },
1701
1749
  delete: {
1702
1750
  loading: {
1703
- add: functionName => `Deleting serverless function metrics ${chalk_1.default.bold(functionName)}`,
1704
- fail: functionName => `Failed to delete serverless function metrics ${chalk_1.default.bold(functionName)}.`,
1705
- succeed: functionName => `Successfully deleted serverless function metrics ${chalk_1.default.bold(functionName)}.`,
1751
+ add: (functionName) => `Deleting serverless function metrics ${chalk_1.default.bold(functionName)}`,
1752
+ fail: (functionName) => `Failed to delete serverless function metrics ${chalk_1.default.bold(functionName)}.`,
1753
+ succeed: (functionName) => `Successfully deleted serverless function metrics ${chalk_1.default.bold(functionName)}.`,
1706
1754
  },
1707
1755
  success: {
1708
1756
  configFileUpdated: (functionName, authType) => `Serverless function metrics "${functionName}" updated using "${authType}"`,
@@ -1722,13 +1770,13 @@ exports.commands = {
1722
1770
  succeed: () => `Successfully listed serverless function metrics.`,
1723
1771
  },
1724
1772
  success: {
1725
- configFileUpdated: authType => `Serverless function metrics updated using "${authType}"`,
1773
+ configFileUpdated: (authType) => `Serverless function metrics updated using "${authType}"`,
1726
1774
  },
1727
1775
  failure: {
1728
- invalidUser: parentAccountName => `Couldn't list serverless function metrics because your account has been removed from ${chalk_1.default.bold(parentAccountName)} or your permission set doesn't allow you to list serverless function metrics. To update your permissions, contact a super admin in ${chalk_1.default.bold(parentAccountName)}.`,
1776
+ invalidUser: (parentAccountName) => `Couldn't list serverless function metrics because your account has been removed from ${chalk_1.default.bold(parentAccountName)} or your permission set doesn't allow you to list serverless function metrics. To update your permissions, contact a super admin in ${chalk_1.default.bold(parentAccountName)}.`,
1729
1777
  scopes: {
1730
1778
  message: "The personal access key you provided doesn't include serverless function metric permissions.",
1731
- instructions: url => `To update CLI permissions: \n- Go to ${url}, deactivate the existing personal access key, and create a new one that includes serverless function metric permissions. \n- Update the CLI config for this account by running ${chalk_1.default.bold('hs auth')} and entering the new key.\n`,
1779
+ instructions: (url) => `To update CLI permissions: \n- Go to ${url}, deactivate the existing personal access key, and create a new one that includes serverless function metric permissions. \n- Update the CLI config for this account by running ${chalk_1.default.bold('hs auth')} and entering the new key.\n`,
1732
1780
  },
1733
1781
  },
1734
1782
  },
@@ -1736,9 +1784,9 @@ exports.commands = {
1736
1784
  serverlessFunctionSettings: {
1737
1785
  add: {
1738
1786
  loading: {
1739
- add: functionName => `Adding serverless function settings ${chalk_1.default.bold(functionName)}`,
1740
- fail: functionName => `Failed to add serverless function settings ${chalk_1.default.bold(functionName)}.`,
1741
- succeed: functionName => `Successfully added serverless function settings ${chalk_1.default.bold(functionName)}.`,
1787
+ add: (functionName) => `Adding serverless function settings ${chalk_1.default.bold(functionName)}`,
1788
+ fail: (functionName) => `Failed to add serverless function settings ${chalk_1.default.bold(functionName)}.`,
1789
+ succeed: (functionName) => `Successfully added serverless function settings ${chalk_1.default.bold(functionName)}.`,
1742
1790
  },
1743
1791
  success: {
1744
1792
  configFileUpdated: (functionName, authType) => `Serverless function settings "${functionName}" updated using "${authType}"`,
@@ -1753,9 +1801,9 @@ exports.commands = {
1753
1801
  },
1754
1802
  delete: {
1755
1803
  loading: {
1756
- add: functionName => `Deleting serverless function settings ${chalk_1.default.bold(functionName)}`,
1757
- fail: functionName => `Failed to delete serverless function settings ${chalk_1.default.bold(functionName)}.`,
1758
- succeed: functionName => `Successfully deleted serverless function settings ${chalk_1.default.bold(functionName)}.`,
1804
+ add: (functionName) => `Deleting serverless function settings ${chalk_1.default.bold(functionName)}`,
1805
+ fail: (functionName) => `Failed to delete serverless function settings ${chalk_1.default.bold(functionName)}.`,
1806
+ succeed: (functionName) => `Successfully deleted serverless function settings ${chalk_1.default.bold(functionName)}.`,
1759
1807
  },
1760
1808
  success: {
1761
1809
  configFileUpdated: (functionName, authType) => `Serverless function settings "${functionName}" updated using "${authType}"`,
@@ -1775,13 +1823,13 @@ exports.commands = {
1775
1823
  succeed: () => `Successfully listed serverless function settings.`,
1776
1824
  },
1777
1825
  success: {
1778
- configFileUpdated: authType => `Serverless function settings updated using "${authType}"`,
1826
+ configFileUpdated: (authType) => `Serverless function settings updated using "${authType}"`,
1779
1827
  },
1780
1828
  failure: {
1781
- invalidUser: parentAccountName => `Couldn't list serverless function settings because your account has been removed from ${chalk_1.default.bold(parentAccountName)} or your permission set doesn't allow you to list serverless function settings. To update your permissions, contact a super admin in ${chalk_1.default.bold(parentAccountName)}.`,
1829
+ invalidUser: (parentAccountName) => `Couldn't list serverless function settings because your account has been removed from ${chalk_1.default.bold(parentAccountName)} or your permission set doesn't allow you to list serverless function settings. To update your permissions, contact a super admin in ${chalk_1.default.bold(parentAccountName)}.`,
1782
1830
  scopes: {
1783
1831
  message: "The personal access key you provided doesn't include serverless function setting permissions.",
1784
- instructions: url => `To update CLI permissions: \n- Go to ${url}, deactivate the existing personal access key, and create a new one that includes serverless function setting permissions. \n- Update the CLI config for this account by running ${chalk_1.default.bold('hs auth')} and entering the new key.\n`,
1832
+ instructions: (url) => `To update CLI permissions: \n- Go to ${url}, deactivate the existing personal access key, and create a new one that includes serverless function setting permissions. \n- Update the CLI config for this account by running ${chalk_1.default.bold('hs auth')} and entering the new key.\n`,
1785
1833
  },
1786
1834
  },
1787
1835
  },
@@ -1789,9 +1837,9 @@ exports.commands = {
1789
1837
  serverlessFunctionVersions: {
1790
1838
  add: {
1791
1839
  loading: {
1792
- add: functionName => `Adding serverless function versions ${chalk_1.default.bold(functionName)}`,
1793
- fail: functionName => `Failed to add serverless function versions ${chalk_1.default.bold(functionName)}.`,
1794
- succeed: functionName => `Successfully added serverless function versions ${chalk_1.default.bold(functionName)}.`,
1840
+ add: (functionName) => `Adding serverless function versions ${chalk_1.default.bold(functionName)}`,
1841
+ fail: (functionName) => `Failed to add serverless function versions ${chalk_1.default.bold(functionName)}.`,
1842
+ succeed: (functionName) => `Successfully added serverless function versions ${chalk_1.default.bold(functionName)}.`,
1795
1843
  },
1796
1844
  success: {
1797
1845
  configFileUpdated: (functionName, authType) => `Serverless function versions "${functionName}" updated using "${authType}"`,
@@ -1806,9 +1854,9 @@ exports.commands = {
1806
1854
  },
1807
1855
  delete: {
1808
1856
  loading: {
1809
- add: functionName => `Deleting serverless function versions ${chalk_1.default.bold(functionName)}`,
1810
- fail: functionName => `Failed to delete serverless function versions ${chalk_1.default.bold(functionName)}.`,
1811
- succeed: functionName => `Successfully deleted serverless function versions ${chalk_1.default.bold(functionName)}.`,
1857
+ add: (functionName) => `Deleting serverless function versions ${chalk_1.default.bold(functionName)}`,
1858
+ fail: (functionName) => `Failed to delete serverless function versions ${chalk_1.default.bold(functionName)}.`,
1859
+ succeed: (functionName) => `Successfully deleted serverless function versions ${chalk_1.default.bold(functionName)}.`,
1812
1860
  },
1813
1861
  success: {
1814
1862
  configFileUpdated: (functionName, authType) => `Serverless function versions "${functionName}" updated using "${authType}"`,
@@ -1828,13 +1876,13 @@ exports.commands = {
1828
1876
  succeed: () => `Successfully listed serverless function versions.`,
1829
1877
  },
1830
1878
  success: {
1831
- configFileUpdated: authType => `Serverless function versions updated using "${authType}"`,
1879
+ configFileUpdated: (authType) => `Serverless function versions updated using "${authType}"`,
1832
1880
  },
1833
1881
  failure: {
1834
- invalidUser: parentAccountName => `Couldn't list serverless function versions because your account has been removed from ${chalk_1.default.bold(parentAccountName)} or your permission set doesn't allow you to list serverless function versions. To update your permissions, contact a super admin in ${chalk_1.default.bold(parentAccountName)}.`,
1882
+ invalidUser: (parentAccountName) => `Couldn't list serverless function versions because your account has been removed from ${chalk_1.default.bold(parentAccountName)} or your permission set doesn't allow you to list serverless function versions. To update your permissions, contact a super admin in ${chalk_1.default.bold(parentAccountName)}.`,
1835
1883
  scopes: {
1836
1884
  message: "The personal access key you provided doesn't include serverless function version permissions.",
1837
- instructions: url => `To update CLI permissions: \n- Go to ${url}, deactivate the existing personal access key, and create a new one that includes serverless function version permissions. \n- Update the CLI config for this account by running ${chalk_1.default.bold('hs auth')} and entering the new key.\n`,
1885
+ instructions: (url) => `To update CLI permissions: \n- Go to ${url}, deactivate the existing personal access key, and create a new one that includes serverless function version permissions. \n- Update the CLI config for this account by running ${chalk_1.default.bold('hs auth')} and entering the new key.\n`,
1838
1886
  },
1839
1887
  },
1840
1888
  },
@@ -1842,9 +1890,9 @@ exports.commands = {
1842
1890
  serverlessFunctionWebhooks: {
1843
1891
  add: {
1844
1892
  loading: {
1845
- add: functionName => `Adding serverless function webhooks ${chalk_1.default.bold(functionName)}`,
1846
- fail: functionName => `Failed to add serverless function webhooks ${chalk_1.default.bold(functionName)}.`,
1847
- succeed: functionName => `Successfully added serverless function webhooks ${chalk_1.default.bold(functionName)}.`,
1893
+ add: (functionName) => `Adding serverless function webhooks ${chalk_1.default.bold(functionName)}`,
1894
+ fail: (functionName) => `Failed to add serverless function webhooks ${chalk_1.default.bold(functionName)}.`,
1895
+ succeed: (functionName) => `Successfully added serverless function webhooks ${chalk_1.default.bold(functionName)}.`,
1848
1896
  },
1849
1897
  success: {
1850
1898
  configFileUpdated: (functionName, authType) => `Serverless function webhooks "${functionName}" updated using "${authType}"`,
@@ -1859,9 +1907,9 @@ exports.commands = {
1859
1907
  },
1860
1908
  delete: {
1861
1909
  loading: {
1862
- add: functionName => `Deleting serverless function webhooks ${chalk_1.default.bold(functionName)}`,
1863
- fail: functionName => `Failed to delete serverless function webhooks ${chalk_1.default.bold(functionName)}.`,
1864
- succeed: functionName => `Successfully deleted serverless function webhooks ${chalk_1.default.bold(functionName)}.`,
1910
+ add: (functionName) => `Deleting serverless function webhooks ${chalk_1.default.bold(functionName)}`,
1911
+ fail: (functionName) => `Failed to delete serverless function webhooks ${chalk_1.default.bold(functionName)}.`,
1912
+ succeed: (functionName) => `Successfully deleted serverless function webhooks ${chalk_1.default.bold(functionName)}.`,
1865
1913
  },
1866
1914
  success: {
1867
1915
  configFileUpdated: (functionName, authType) => `Serverless function webhooks "${functionName}" updated using "${authType}"`,
@@ -1881,13 +1929,13 @@ exports.commands = {
1881
1929
  succeed: () => `Successfully listed serverless function webhooks.`,
1882
1930
  },
1883
1931
  success: {
1884
- configFileUpdated: authType => `Serverless function webhooks updated using "${authType}"`,
1932
+ configFileUpdated: (authType) => `Serverless function webhooks updated using "${authType}"`,
1885
1933
  },
1886
1934
  failure: {
1887
- invalidUser: parentAccountName => `Couldn't list serverless function webhooks because your account has been removed from ${chalk_1.default.bold(parentAccountName)} or your permission set doesn't allow you to list serverless function webhooks. To update your permissions, contact a super admin in ${chalk_1.default.bold(parentAccountName)}.`,
1935
+ invalidUser: (parentAccountName) => `Couldn't list serverless function webhooks because your account has been removed from ${chalk_1.default.bold(parentAccountName)} or your permission set doesn't allow you to list serverless function webhooks. To update your permissions, contact a super admin in ${chalk_1.default.bold(parentAccountName)}.`,
1888
1936
  scopes: {
1889
1937
  message: "The personal access key you provided doesn't include serverless function webhook permissions.",
1890
- instructions: url => `To update CLI permissions: \n- Go to ${url}, deactivate the existing personal access key, and create a new one that includes serverless function webhook permissions. \n- Update the CLI config for this account by running ${chalk_1.default.bold('hs auth')} and entering the new key.\n`,
1938
+ instructions: (url) => `To update CLI permissions: \n- Go to ${url}, deactivate the existing personal access key, and create a new one that includes serverless function webhook permissions. \n- Update the CLI config for this account by running ${chalk_1.default.bold('hs auth')} and entering the new key.\n`,
1891
1939
  },
1892
1940
  },
1893
1941
  },
@@ -1895,9 +1943,9 @@ exports.commands = {
1895
1943
  serverlessFunctionWebhookSubscriptions: {
1896
1944
  add: {
1897
1945
  loading: {
1898
- add: functionName => `Adding serverless function webhook subscriptions ${chalk_1.default.bold(functionName)}`,
1899
- fail: functionName => `Failed to add serverless function webhook subscriptions ${chalk_1.default.bold(functionName)}.`,
1900
- succeed: functionName => `Successfully added serverless function webhook subscriptions ${chalk_1.default.bold(functionName)}.`,
1946
+ add: (functionName) => `Adding serverless function webhook subscriptions ${chalk_1.default.bold(functionName)}`,
1947
+ fail: (functionName) => `Failed to add serverless function webhook subscriptions ${chalk_1.default.bold(functionName)}.`,
1948
+ succeed: (functionName) => `Successfully added serverless function webhook subscriptions ${chalk_1.default.bold(functionName)}.`,
1901
1949
  },
1902
1950
  success: {
1903
1951
  configFileUpdated: (functionName, authType) => `Serverless function webhook subscriptions "${functionName}" updated using "${authType}"`,
@@ -1912,9 +1960,9 @@ exports.commands = {
1912
1960
  },
1913
1961
  delete: {
1914
1962
  loading: {
1915
- add: functionName => `Deleting serverless function webhook subscriptions ${chalk_1.default.bold(functionName)}`,
1916
- fail: functionName => `Failed to delete serverless function webhook subscriptions ${chalk_1.default.bold(functionName)}.`,
1917
- succeed: functionName => `Successfully deleted serverless function webhook subscriptions ${chalk_1.default.bold(functionName)}.`,
1963
+ add: (functionName) => `Deleting serverless function webhook subscriptions ${chalk_1.default.bold(functionName)}`,
1964
+ fail: (functionName) => `Failed to delete serverless function webhook subscriptions ${chalk_1.default.bold(functionName)}.`,
1965
+ succeed: (functionName) => `Successfully deleted serverless function webhook subscriptions ${chalk_1.default.bold(functionName)}.`,
1918
1966
  },
1919
1967
  success: {
1920
1968
  configFileUpdated: (functionName, authType) => `Serverless function webhook subscriptions "${functionName}" updated using "${authType}"`,
@@ -1934,13 +1982,13 @@ exports.commands = {
1934
1982
  succeed: () => `Successfully listed serverless function webhook subscriptions.`,
1935
1983
  },
1936
1984
  success: {
1937
- configFileUpdated: authType => `Serverless function webhook subscriptions updated using "${authType}"`,
1985
+ configFileUpdated: (authType) => `Serverless function webhook subscriptions updated using "${authType}"`,
1938
1986
  },
1939
1987
  failure: {
1940
- invalidUser: parentAccountName => `Couldn't list serverless function webhook subscriptions because your account has been removed from ${chalk_1.default.bold(parentAccountName)} or your permission set doesn't allow you to list serverless function webhook subscriptions. To update your permissions, contact a super admin in ${chalk_1.default.bold(parentAccountName)}.`,
1988
+ invalidUser: (parentAccountName) => `Couldn't list serverless function webhook subscriptions because your account has been removed from ${chalk_1.default.bold(parentAccountName)} or your permission set doesn't allow you to list serverless function webhook subscriptions. To update your permissions, contact a super admin in ${chalk_1.default.bold(parentAccountName)}.`,
1941
1989
  scopes: {
1942
1990
  message: "The personal access key you provided doesn't include serverless function webhook subscription permissions.",
1943
- instructions: url => `To update CLI permissions: \n- Go to ${url}, deactivate the existing personal access key, and create a new one that includes serverless function webhook subscription permissions. \n- Update the CLI config for this account by running ${chalk_1.default.bold('hs auth')} and entering the new key.\n`,
1991
+ instructions: (url) => `To update CLI permissions: \n- Go to ${url}, deactivate the existing personal access key, and create a new one that includes serverless function webhook subscription permissions. \n- Update the CLI config for this account by running ${chalk_1.default.bold('hs auth')} and entering the new key.\n`,
1944
1992
  },
1945
1993
  },
1946
1994
  },
@@ -1948,9 +1996,9 @@ exports.commands = {
1948
1996
  serverlessFunctionWebhookSubscriptionEvents: {
1949
1997
  add: {
1950
1998
  loading: {
1951
- add: functionName => `Adding serverless function webhook subscription events ${chalk_1.default.bold(functionName)}`,
1952
- fail: functionName => `Failed to add serverless function webhook subscription events ${chalk_1.default.bold(functionName)}.`,
1953
- succeed: functionName => `Successfully added serverless function webhook subscription events ${chalk_1.default.bold(functionName)}.`,
1999
+ add: (functionName) => `Adding serverless function webhook subscription events ${chalk_1.default.bold(functionName)}`,
2000
+ fail: (functionName) => `Failed to add serverless function webhook subscription events ${chalk_1.default.bold(functionName)}.`,
2001
+ succeed: (functionName) => `Successfully added serverless function webhook subscription events ${chalk_1.default.bold(functionName)}.`,
1954
2002
  },
1955
2003
  success: {
1956
2004
  configFileUpdated: (functionName, authType) => `Serverless function webhook subscription events "${functionName}" updated using "${authType}"`,
@@ -1965,9 +2013,9 @@ exports.commands = {
1965
2013
  },
1966
2014
  delete: {
1967
2015
  loading: {
1968
- add: functionName => `Deleting serverless function webhook subscription events ${chalk_1.default.bold(functionName)}`,
1969
- fail: functionName => `Failed to delete serverless function webhook subscription events ${chalk_1.default.bold(functionName)}.`,
1970
- succeed: functionName => `Successfully deleted serverless function webhook subscription events ${chalk_1.default.bold(functionName)}.`,
2016
+ add: (functionName) => `Deleting serverless function webhook subscription events ${chalk_1.default.bold(functionName)}`,
2017
+ fail: (functionName) => `Failed to delete serverless function webhook subscription events ${chalk_1.default.bold(functionName)}.`,
2018
+ succeed: (functionName) => `Successfully deleted serverless function webhook subscription events ${chalk_1.default.bold(functionName)}.`,
1971
2019
  },
1972
2020
  success: {
1973
2021
  configFileUpdated: (functionName, authType) => `Serverless function webhook subscription events "${functionName}" updated using "${authType}"`,
@@ -1987,13 +2035,13 @@ exports.commands = {
1987
2035
  succeed: () => `Successfully listed serverless function webhook subscription events.`,
1988
2036
  },
1989
2037
  success: {
1990
- configFileUpdated: authType => `Serverless function webhook subscription events updated using "${authType}"`,
2038
+ configFileUpdated: (authType) => `Serverless function webhook subscription events updated using "${authType}"`,
1991
2039
  },
1992
2040
  failure: {
1993
- invalidUser: parentAccountName => `Couldn't list serverless function webhook subscription events because your account has been removed from ${chalk_1.default.bold(parentAccountName)} or your permission set doesn't allow you to list serverless function webhook subscription events. To update your permissions, contact a super admin in ${chalk_1.default.bold(parentAccountName)}.`,
2041
+ invalidUser: (parentAccountName) => `Couldn't list serverless function webhook subscription events because your account has been removed from ${chalk_1.default.bold(parentAccountName)} or your permission set doesn't allow you to list serverless function webhook subscription events. To update your permissions, contact a super admin in ${chalk_1.default.bold(parentAccountName)}.`,
1994
2042
  scopes: {
1995
2043
  message: "The personal access key you provided doesn't include serverless function webhook subscription event permissions.",
1996
- instructions: url => `To update CLI permissions: \n- Go to ${url}, deactivate the existing personal access key, and create a new one that includes serverless function webhook subscription event permissions. \n- Update the CLI config for this account by running ${chalk_1.default.bold('hs auth')} and entering the new key.\n`,
2044
+ instructions: (url) => `To update CLI permissions: \n- Go to ${url}, deactivate the existing personal access key, and create a new one that includes serverless function webhook subscription event permissions. \n- Update the CLI config for this account by running ${chalk_1.default.bold('hs auth')} and entering the new key.\n`,
1997
2045
  },
1998
2046
  },
1999
2047
  },
@@ -2001,9 +2049,9 @@ exports.commands = {
2001
2049
  serverlessFunctionWebhookSubscriptionEventTypes: {
2002
2050
  add: {
2003
2051
  loading: {
2004
- add: functionName => `Adding serverless function webhook subscription event types ${chalk_1.default.bold(functionName)}`,
2005
- fail: functionName => `Failed to add serverless function webhook subscription event types ${chalk_1.default.bold(functionName)}.`,
2006
- succeed: functionName => `Successfully added serverless function webhook subscription event types ${chalk_1.default.bold(functionName)}.`,
2052
+ add: (functionName) => `Adding serverless function webhook subscription event types ${chalk_1.default.bold(functionName)}`,
2053
+ fail: (functionName) => `Failed to add serverless function webhook subscription event types ${chalk_1.default.bold(functionName)}.`,
2054
+ succeed: (functionName) => `Successfully added serverless function webhook subscription event types ${chalk_1.default.bold(functionName)}.`,
2007
2055
  },
2008
2056
  success: {
2009
2057
  configFileUpdated: (functionName, authType) => `Serverless function webhook subscription event types "${functionName}" updated using "${authType}"`,
@@ -2018,9 +2066,9 @@ exports.commands = {
2018
2066
  },
2019
2067
  delete: {
2020
2068
  loading: {
2021
- add: functionName => `Deleting serverless function webhook subscription event types ${chalk_1.default.bold(functionName)}`,
2022
- fail: functionName => `Failed to delete serverless function webhook subscription event types ${chalk_1.default.bold(functionName)}.`,
2023
- succeed: functionName => `Successfully deleted serverless function webhook subscription event types ${chalk_1.default.bold(functionName)}.`,
2069
+ add: (functionName) => `Deleting serverless function webhook subscription event types ${chalk_1.default.bold(functionName)}`,
2070
+ fail: (functionName) => `Failed to delete serverless function webhook subscription event types ${chalk_1.default.bold(functionName)}.`,
2071
+ succeed: (functionName) => `Successfully deleted serverless function webhook subscription event types ${chalk_1.default.bold(functionName)}.`,
2024
2072
  },
2025
2073
  success: {
2026
2074
  configFileUpdated: (functionName, authType) => `Serverless function webhook subscription event types "${functionName}" updated using "${authType}"`,
@@ -2040,13 +2088,13 @@ exports.commands = {
2040
2088
  succeed: () => `Successfully listed serverless function webhook subscription event types.`,
2041
2089
  },
2042
2090
  success: {
2043
- configFileUpdated: authType => `Serverless function webhook subscription event types updated using "${authType}"`,
2091
+ configFileUpdated: (authType) => `Serverless function webhook subscription event types updated using "${authType}"`,
2044
2092
  },
2045
2093
  failure: {
2046
- invalidUser: parentAccountName => `Couldn't list serverless function webhook subscription event types because your account has been removed from ${chalk_1.default.bold(parentAccountName)} or your permission set doesn't allow you to list serverless function webhook subscription event types. To update your permissions, contact a super admin in ${chalk_1.default.bold(parentAccountName)}.`,
2094
+ invalidUser: (parentAccountName) => `Couldn't list serverless function webhook subscription event types because your account has been removed from ${chalk_1.default.bold(parentAccountName)} or your permission set doesn't allow you to list serverless function webhook subscription event types. To update your permissions, contact a super admin in ${chalk_1.default.bold(parentAccountName)}.`,
2047
2095
  scopes: {
2048
2096
  message: "The personal access key you provided doesn't include serverless function webhook subscription event type permissions.",
2049
- instructions: url => `To update CLI permissions: \n- Go to ${url}, deactivate the existing personal access key, and create a new one that includes serverless function webhook subscription event type permissions. \n- Update the CLI config for this account by running ${chalk_1.default.bold('hs auth')} and entering the new key.\n`,
2097
+ instructions: (url) => `To update CLI permissions: \n- Go to ${url}, deactivate the existing personal access key, and create a new one that includes serverless function webhook subscription event type permissions. \n- Update the CLI config for this account by running ${chalk_1.default.bold('hs auth')} and entering the new key.\n`,
2050
2098
  },
2051
2099
  },
2052
2100
  },
@@ -2054,9 +2102,9 @@ exports.commands = {
2054
2102
  serverlessFunctionWebhookSubscriptionEventTypeOptions: {
2055
2103
  add: {
2056
2104
  loading: {
2057
- add: functionName => `Adding serverless function webhook subscription event type options ${chalk_1.default.bold(functionName)}`,
2058
- fail: functionName => `Failed to add serverless function webhook subscription event type options ${chalk_1.default.bold(functionName)}.`,
2059
- succeed: functionName => `Successfully added serverless function webhook subscription event type options ${chalk_1.default.bold(functionName)}.`,
2105
+ add: (functionName) => `Adding serverless function webhook subscription event type options ${chalk_1.default.bold(functionName)}`,
2106
+ fail: (functionName) => `Failed to add serverless function webhook subscription event type options ${chalk_1.default.bold(functionName)}.`,
2107
+ succeed: (functionName) => `Successfully added serverless function webhook subscription event type options ${chalk_1.default.bold(functionName)}.`,
2060
2108
  },
2061
2109
  success: {
2062
2110
  configFileUpdated: (functionName, authType) => `Serverless function webhook subscription event type options "${functionName}" updated using "${authType}"`,
@@ -2071,9 +2119,9 @@ exports.commands = {
2071
2119
  },
2072
2120
  delete: {
2073
2121
  loading: {
2074
- add: functionName => `Deleting serverless function webhook subscription event type options ${chalk_1.default.bold(functionName)}`,
2075
- fail: functionName => `Failed to delete serverless function webhook subscription event type options ${chalk_1.default.bold(functionName)}.`,
2076
- succeed: functionName => `Successfully deleted serverless function webhook subscription event type options ${chalk_1.default.bold(functionName)}.`,
2122
+ add: (functionName) => `Deleting serverless function webhook subscription event type options ${chalk_1.default.bold(functionName)}`,
2123
+ fail: (functionName) => `Failed to delete serverless function webhook subscription event type options ${chalk_1.default.bold(functionName)}.`,
2124
+ succeed: (functionName) => `Successfully deleted serverless function webhook subscription event type options ${chalk_1.default.bold(functionName)}.`,
2077
2125
  },
2078
2126
  success: {
2079
2127
  configFileUpdated: (functionName, authType) => `Serverless function webhook subscription event type options "${functionName}" updated using "${authType}"`,
@@ -2093,13 +2141,13 @@ exports.commands = {
2093
2141
  succeed: () => `Successfully listed serverless function webhook subscription event type options.`,
2094
2142
  },
2095
2143
  success: {
2096
- configFileUpdated: authType => `Serverless function webhook subscription event type options updated using "${authType}"`,
2144
+ configFileUpdated: (authType) => `Serverless function webhook subscription event type options updated using "${authType}"`,
2097
2145
  },
2098
2146
  failure: {
2099
- invalidUser: parentAccountName => `Couldn't list serverless function webhook subscription event type options because your account has been removed from ${chalk_1.default.bold(parentAccountName)} or your permission set doesn't allow you to list serverless function webhook subscription event type options. To update your permissions, contact a super admin in ${chalk_1.default.bold(parentAccountName)}.`,
2147
+ invalidUser: (parentAccountName) => `Couldn't list serverless function webhook subscription event type options because your account has been removed from ${chalk_1.default.bold(parentAccountName)} or your permission set doesn't allow you to list serverless function webhook subscription event type options. To update your permissions, contact a super admin in ${chalk_1.default.bold(parentAccountName)}.`,
2100
2148
  scopes: {
2101
2149
  message: "The personal access key you provided doesn't include serverless function webhook subscription event type option permissions.",
2102
- instructions: url => `To update CLI permissions: \n- Go to ${url}, deactivate the existing personal access key, and create a new one that includes serverless function webhook subscription event type option permissions. \n- Update the CLI config for this account by running ${chalk_1.default.bold('hs auth')} and entering the new key.\n`,
2150
+ instructions: (url) => `To update CLI permissions: \n- Go to ${url}, deactivate the existing personal access key, and create a new one that includes serverless function webhook subscription event type option permissions. \n- Update the CLI config for this account by running ${chalk_1.default.bold('hs auth')} and entering the new key.\n`,
2103
2151
  },
2104
2152
  },
2105
2153
  },
@@ -2107,22 +2155,22 @@ exports.commands = {
2107
2155
  };
2108
2156
  exports.lib = {
2109
2157
  process: {
2110
- exitDebug: signal => `Attempting to gracefully exit. Triggered by ${signal}`,
2158
+ exitDebug: (signal) => `Attempting to gracefully exit. Triggered by ${signal}`,
2111
2159
  },
2112
2160
  DevServerManager: {
2113
- portConflict: port => `The port ${port} is already in use.`,
2161
+ portConflict: (port) => `The port ${port} is already in use.`,
2114
2162
  notInitialized: 'The Dev Server Manager must be initialized before it is started.',
2115
- noCompatibleComponents: serverKey => `Skipping call to ${serverKey} because there are no compatible components in the project.`,
2163
+ noCompatibleComponents: (serverKey) => `Skipping call to ${serverKey} because there are no compatible components in the project.`,
2116
2164
  },
2117
2165
  LocalDevManager: {
2118
2166
  failedToInitialize: 'Missing required arguments to initialize Local Dev',
2119
2167
  noDeployedBuild: (projectName, accountIdentifier, uploadCommand) => `Your project ${chalk_1.default.bold(projectName)} exists in ${accountIdentifier}, but has no deployed build. Projects must be successfully deployed to be developed locally. Address any build and deploy errors your project may have, then run ${uploadCommand} to upload and deploy your project.`,
2120
2168
  noComponents: 'There are no components in this project.',
2121
2169
  betaMessage: 'HubSpot projects local development',
2122
- learnMoreLocalDevServer: 'Learn more about the projects local dev server',
2123
- running: (projectName, accountIdentifier) => `Running ${chalk_1.default.bold(projectName)} locally on ${accountIdentifier}, waiting for changes ...`,
2170
+ learnMoreLocalDevServer: (0, ui_1.uiLink)('Learn more about the projects local dev server', 'https://developers.hubspot.com/docs/platform/project-cli-commands#start-a-local-development-server'),
2171
+ running: (projectName, accountIdentifier) => chalk_1.default.hex(ui_2.UI_COLORS.SORBET)(`Running ${chalk_1.default.bold(projectName)} locally on ${accountIdentifier}, waiting for changes ...`),
2124
2172
  quitHelper: `Press ${chalk_1.default.bold('q')} to stop the local dev server`,
2125
- viewProjectLink: 'View project in HubSpot',
2173
+ viewProjectLink: (name, accountId) => (0, ui_1.uiLink)('View project in HubSpot', (0, urls_1.getProjectDetailUrl)(name, accountId) || ''),
2126
2174
  viewTestAccountLink: 'View developer test account in HubSpot',
2127
2175
  exitingStart: 'Stopping local dev server ...',
2128
2176
  exitingSucceed: 'Successfully exited',
@@ -2131,29 +2179,51 @@ exports.lib = {
2131
2179
  uploadWarning: {
2132
2180
  appLabel: '[App]',
2133
2181
  uiExtensionLabel: '[UI Extension]',
2134
- missingComponents: missingComponents => `Couldn't find the following components in the deployed build for this project: ${chalk_1.default.bold(missingComponents)}. This may cause issues in local development.`,
2182
+ missingComponents: (missingComponents) => `Couldn't find the following components in the deployed build for this project: ${chalk_1.default.bold(missingComponents)}. This may cause issues in local development.`,
2135
2183
  defaultWarning: chalk_1.default.bold('Changing project configuration requires a new project build.'),
2136
2184
  defaultPublicAppWarning: (installCount, installText) => `${chalk_1.default.bold('Changing project configuration requires a new project build.')}\n\nThis will affect your public app's ${chalk_1.default.bold(`${installCount} existing ${installText}`)}. If your app has users in production, we strongly recommend creating a copy of this app to test your changes before proceding.`,
2137
- header: warning => `${warning} To reflect these changes and continue testing:`,
2185
+ header: (warning) => `${warning} To reflect these changes and continue testing:`,
2186
+ instructionsHeader: 'To reflect these changes and continue testing:',
2138
2187
  stopDev: ` * Stop ${(0, ui_1.uiCommandReference)('hs project dev')}`,
2139
- runUpload: command => ` * Run ${command}`,
2188
+ runUpload: (command) => ` * Run ${command}`,
2140
2189
  restartDev: ` * Re-run ${(0, ui_1.uiCommandReference)('hs project dev')}`,
2141
2190
  pushToGithub: ' * Commit and push your changes to GitHub',
2142
2191
  defaultMarketplaceAppWarning: (installCount, accountText) => `${chalk_1.default.bold('Changing project configuration requires creating a new project build.')}\n\nYour marketplace app is currently installed in ${chalk_1.default.bold(`${installCount} ${accountText}`)}. Any uploaded changes will impact your app's users. We strongly recommend creating a copy of this app to test your changes before proceding.`,
2143
2192
  },
2144
2193
  activeInstallWarning: {
2145
- installCount: (appName, installCount, installText) => `${chalk_1.default.bold(`The app ${appName} has ${installCount} production ${installText}`)}`,
2194
+ installCount: (appName, installCount) => `${chalk_1.default.bold(`The app ${appName} is installed in ${installCount} production ${installCount === 1 ? 'account' : 'accounts'}`)}`,
2146
2195
  explanation: 'Some changes made during local development may need to be synced to HubSpot, which will impact those existing installs. We strongly recommend creating a copy of this app to use instead.',
2147
2196
  confirmation: `You will always be asked to confirm any permanent changes to your app's configuration before uploading them.`,
2148
2197
  confirmationPrompt: `Proceed with local development of this ${chalk_1.default.bold('production')} app?`,
2149
2198
  },
2150
2199
  devServer: {
2151
- cleanupError: message => `Failed to cleanup local dev server: ${message}`,
2152
- setupError: message => `Failed to setup local dev server: ${message}`,
2153
- startError: message => `Failed to start local dev server: ${message}`,
2154
- fileChangeError: message => `Failed to notify local dev server of file change: ${message}`,
2200
+ cleanupError: (message) => `Failed to cleanup local dev server: ${message}`,
2201
+ setupError: (message) => `Failed to setup local dev server: ${message}`,
2202
+ startError: (message) => `Failed to start local dev server: ${message}`,
2203
+ fileChangeError: (message) => `Failed to notify local dev server of file change: ${message}`,
2204
+ },
2205
+ },
2206
+ AppDevModeInterface: {
2207
+ defaultMarketplaceAppWarning: (installCount) => `\n\nYour marketplace app is currently installed in ${chalk_1.default.bold(`${installCount} ${installCount === 1 ? 'account' : 'accounts'}`)}. Any uploaded changes will impact your app's users. We strongly recommend creating a copy of this app to test your changes before proceding.`,
2208
+ },
2209
+ LocalDevWebsocketServer: {
2210
+ errors: {
2211
+ notInitialized: (prefix) => `${prefix}Error: Attempted to access websocket before initialization`,
2212
+ missingTypeField: (data) => `Unsupported message received. Missing type field: ${data}`,
2213
+ unknownMessageType: (type) => `Unsupported message received. Unknown message type: ${type}`,
2214
+ invalidJSON: (data) => `Unsupported message received. Invalid JSON: ${data}`,
2215
+ portManagerNotRunning: (prefix) => `${prefix}Error: PortManagerServing must be running before starting LocalDevWebsocketServer.`,
2216
+ },
2217
+ logs: {
2218
+ startup: (port) => `LocalDevWebsocketServer running on port ${port}`,
2155
2219
  },
2156
2220
  },
2221
+ LocalDevProcess: {
2222
+ projectConfigMismatch: `Unable to upload project. The project config has been modified since starting ${(0, ui_1.uiCommandReference)('hs project dev')}.`,
2223
+ uploadInitiated: 'Project upload initiated from Local Dev UI.',
2224
+ uploadFailed: 'Project upload failed. To proceed with local development, fix any necessary errors, then re-upload your project.',
2225
+ uploadSuccess: 'Project upload completed successfully. Resuming local dev...',
2226
+ },
2157
2227
  localDevHelpers: {
2158
2228
  confirmDefaultAccountIsTarget: {
2159
2229
  configError: `An error occurred while reading the default account from your config. Run ${(0, ui_1.uiCommandReference)('hs auth')} to re-auth this account`,
@@ -2187,6 +2257,26 @@ exports.lib = {
2187
2257
  notAuthedError: (parentAccountId, accountIdentifier) => `To develop this project locally, run ${(0, ui_1.uiCommandReference)(`hs auth --account=${parentAccountId}`)} to authenticate the App Developer Account ${parentAccountId} associated with ${accountIdentifier}.`,
2188
2258
  },
2189
2259
  },
2260
+ projectProfiles: {
2261
+ logs: {
2262
+ usingProfile: (profileName) => `Using profile from ${chalk_1.default.bold(profileName)}`,
2263
+ profileTargetAccount: (accountId) => `Targeting ${(0, ui_1.uiAccountDescription)(accountId)}`,
2264
+ profileVariables: 'Profile variables',
2265
+ },
2266
+ exitIfUsingProfiles: {
2267
+ errors: {
2268
+ noProfileSpecified: `This project is configured to use profiles, but no profile was specified. Target a profile using the ${(0, ui_1.uiCommandReference)('--profile')} flag.`,
2269
+ },
2270
+ },
2271
+ loadProfile: {
2272
+ errors: {
2273
+ noProjectConfig: 'No project config found. Please run this command from a project directory.',
2274
+ profileNotFound: (profileName) => `Profile ${chalk_1.default.bold(profileName)} not found.`,
2275
+ missingAccountId: (profileName) => `Profile ${chalk_1.default.bold(profileName)} is missing an account id.`,
2276
+ failedToLoadProfile: (profileName) => `Failed to load profile ${chalk_1.default.bold(profileName)}.`,
2277
+ },
2278
+ },
2279
+ },
2190
2280
  projects: {
2191
2281
  create: {
2192
2282
  errors: {
@@ -2211,7 +2301,7 @@ exports.lib = {
2211
2301
  notFound: (projectName, accountIdentifier) => `Your project ${chalk_1.default.bold(projectName)} could not be found in ${chalk_1.default.bold(accountIdentifier)}.`,
2212
2302
  },
2213
2303
  pollFetchProject: {
2214
- checkingProject: accountIdentifier => `Checking if project exists in ${accountIdentifier}`,
2304
+ checkingProject: (accountIdentifier) => `Checking if project exists in ${accountIdentifier}`,
2215
2305
  },
2216
2306
  logFeedbackMessage: {
2217
2307
  feedbackHeader: "We'd love to hear your feedback!",
@@ -2222,15 +2312,15 @@ exports.lib = {
2222
2312
  makePollTaskStatusFunc: {
2223
2313
  errorSummary: 'See below for a summary of errors.',
2224
2314
  componentCountSingular: 'Found 1 component in this project\n',
2225
- componentCount: numComponents => `Found ${numComponents} components in this project\n`,
2315
+ componentCount: (numComponents) => `Found ${numComponents} components in this project\n`,
2226
2316
  successStatusText: 'DONE',
2227
2317
  failedStatusText: 'FAILED',
2228
- errorFetchingTaskStatus: taskType => `Error fetching ${taskType} status`,
2318
+ errorFetchingTaskStatus: (taskType) => `Error fetching ${taskType} status`,
2229
2319
  },
2230
- pollBuildAutodeployStatusError: buildId => `Error fetching autodeploy status for build #${buildId}`,
2320
+ pollBuildAutodeployStatusError: (buildId) => `Error fetching autodeploy status for build #${buildId}`,
2231
2321
  pollProjectBuildAndDeploy: {
2232
2322
  buildSucceededAutomaticallyDeploying: (buildId, accountIdentifier) => `Build #${buildId} succeeded. ${chalk_1.default.bold('Automatically deploying')} to ${accountIdentifier}\n`,
2233
- cleanedUpTempFile: path => `Cleaned up temporary file ${path}`,
2323
+ cleanedUpTempFile: (path) => `Cleaned up temporary file ${path}`,
2234
2324
  viewDeploys: 'View all deploys for this project in HubSpot',
2235
2325
  unableToFindAutodeployStatus: (buildId, viewDeploysLink) => `Unable to find the auto deploy for build #${buildId}. This deploy may have been skipped. ${viewDeploysLink}.`,
2236
2326
  },
@@ -2243,10 +2333,10 @@ exports.lib = {
2243
2333
  buildCreated: (projectName, buildId) => `Project "${projectName}" uploaded and build #${buildId} created`,
2244
2334
  },
2245
2335
  handleProjectUpload: {
2246
- emptySource: srcDir => `Source directory "${srcDir}" is empty. Add files to your project and rerun ${(0, ui_1.uiCommandReference)('hs project upload')} to upload them to HubSpot.`,
2247
- compressed: byteCount => `Project files compressed: ${byteCount} bytes`,
2248
- compressing: path => `Compressing build files to "${path}"`,
2249
- fileFiltered: filename => `Ignore rule triggered for "${filename}"`,
2336
+ emptySource: (srcDir) => `Source directory "${srcDir}" is empty. Add files to your project and rerun ${(0, ui_1.uiCommandReference)('hs project upload')} to upload them to HubSpot.`,
2337
+ compressed: (byteCount) => `Project files compressed: ${byteCount} bytes`,
2338
+ compressing: (path) => `Compressing build files to "${path}"`,
2339
+ fileFiltered: (filename) => `Ignore rule triggered for "${filename}"`,
2250
2340
  },
2251
2341
  },
2252
2342
  boxen: {
@@ -2271,71 +2361,71 @@ exports.lib = {
2271
2361
  featureKeys: {
2272
2362
  accountOption: {
2273
2363
  command: '--account',
2274
- message: command => `Use the ${command} option with any command to override the default account`,
2364
+ message: (command) => `Use the ${command} option with any command to override the default account`,
2275
2365
  },
2276
2366
  accountsListCommand: {
2277
2367
  command: 'hs accounts list',
2278
- message: command => `Run ${command} to see a list of configured HubSpot accounts`,
2368
+ message: (command) => `Run ${command} to see a list of configured HubSpot accounts`,
2279
2369
  },
2280
2370
  accountsUseCommand: {
2281
2371
  command: 'hs accounts use',
2282
- message: command => `Run ${command} to set the Hubspot account that the CLI will target by default`,
2372
+ message: (command) => `Run ${command} to set the Hubspot account that the CLI will target by default`,
2283
2373
  },
2284
2374
  authCommand: {
2285
2375
  command: 'hs auth',
2286
- message: command => `Run ${command} to connect the CLI to additional HubSpot accounts`,
2376
+ message: (command) => `Run ${command} to connect the CLI to additional HubSpot accounts`,
2287
2377
  },
2288
2378
  feedbackCommand: {
2289
2379
  command: 'hs feedback',
2290
- message: command => `Run ${command} to report a bug or leave feedback`,
2380
+ message: (command) => `Run ${command} to report a bug or leave feedback`,
2291
2381
  },
2292
2382
  helpCommand: {
2293
2383
  command: 'hs help',
2294
- message: command => `Run ${command} to see a list of available commands`,
2384
+ message: (command) => `Run ${command} to see a list of available commands`,
2295
2385
  },
2296
2386
  projectCreateCommand: {
2297
2387
  command: 'hs project create',
2298
- message: command => `Run ${command} to create a new project`,
2388
+ message: (command) => `Run ${command} to create a new project`,
2299
2389
  },
2300
2390
  projectDeployCommand: {
2301
2391
  command: 'hs project deploy',
2302
- message: command => `Ready to take your project live? Run ${command}`,
2392
+ message: (command) => `Ready to take your project live? Run ${command}`,
2303
2393
  },
2304
2394
  projectHelpCommand: {
2305
2395
  command: 'hs project --help',
2306
- message: command => `Run ${command} to learn more about available project commands`,
2396
+ message: (command) => `Run ${command} to learn more about available project commands`,
2307
2397
  },
2308
2398
  projectUploadCommand: {
2309
2399
  command: 'hs project upload',
2310
- message: command => `Run ${command} to upload your project to HubSpot and trigger builds`,
2400
+ message: (command) => `Run ${command} to upload your project to HubSpot and trigger builds`,
2311
2401
  },
2312
2402
  projectDevCommand: {
2313
2403
  command: 'hs project dev',
2314
- message: command => `Run ${command} to set up your test environment and start local development`,
2404
+ message: (command) => `Run ${command} to set up your test environment and start local development`,
2315
2405
  },
2316
2406
  projectInstallDepsCommand: {
2317
2407
  command: 'hs project install-deps',
2318
- message: command => `Run ${command} to install dependencies for your project components`,
2408
+ message: (command) => `Run ${command} to install dependencies for your project components`,
2319
2409
  },
2320
2410
  sampleProjects: {
2321
2411
  linkText: "HubSpot's sample projects",
2322
2412
  url: 'https://developers.hubspot.com/docs/platform/sample-projects?utm_source=cli&utm_content=project_create_whats_next',
2323
- message: link => `See ${link}`,
2413
+ message: (link) => `See ${link}`,
2324
2414
  },
2325
2415
  },
2326
2416
  },
2327
2417
  git: {
2328
2418
  securityIssue: 'Security Issue Detected',
2329
2419
  configFileTracked: 'The HubSpot config file can be tracked by git.',
2330
- fileName: configPath => `File: "${configPath}"`,
2420
+ fileName: (configPath) => `File: "${configPath}"`,
2331
2421
  remediate: 'To remediate:',
2332
- moveConfig: homeDir => `- Move the config file to your home directory: '${homeDir}'`,
2333
- addGitignore: configPath => `- Add gitignore pattern '${configPath}' to a .gitignore file in root of your repository.`,
2422
+ moveConfig: (homeDir) => `- Move the config file to your home directory: '${homeDir}'`,
2423
+ addGitignore: (configPath) => `- Add gitignore pattern '${configPath}' to a .gitignore file in root of your repository.`,
2334
2424
  noRemote: '- Ensure that the config file has not already been pushed to a remote repository.',
2335
2425
  checkFailed: 'Unable to determine if config file is properly ignored by git.',
2336
2426
  },
2337
2427
  serverlessFunctionLogs: {
2338
- unableToProcessLog: log => `Unable to process log ${log}`,
2428
+ unableToProcessLog: (log) => `Unable to process log ${log}`,
2339
2429
  noLogsFound: 'No logs found.',
2340
2430
  },
2341
2431
  },
@@ -2352,9 +2442,9 @@ exports.lib = {
2352
2442
  },
2353
2443
  modes: {
2354
2444
  describe: {
2355
- default: modes => `${modes}`,
2356
- read: modes => `Read from ${modes}`,
2357
- write: modes => `Write to ${modes}`,
2445
+ default: (modes) => `${modes}`,
2446
+ read: (modes) => `Read from ${modes}`,
2447
+ write: (modes) => `Write to ${modes}`,
2358
2448
  },
2359
2449
  },
2360
2450
  qa: {
@@ -2374,33 +2464,33 @@ exports.lib = {
2374
2464
  createNewDeveloperTestAccountOption: '<Test on a new developer test account>',
2375
2465
  chooseDefaultAccountOption: () => `<${chalk_1.default.bold('❗')} Test on this production account ${chalk_1.default.bold('❗')}>`,
2376
2466
  promptMessage: (accountType, accountIdentifier) => `[--account] Choose a ${accountType} under ${accountIdentifier} to test with:`,
2377
- sandboxLimit: limit => `Your account reached the limit of ${limit} development sandboxes`,
2467
+ sandboxLimit: (limit) => `Your account reached the limit of ${limit} development sandboxes`,
2378
2468
  sandboxLimitWithSuggestion: (limit, authCommand) => `Your account reached the limit of ${limit} development sandboxes. Run ${authCommand} to add an existing one to the config.`,
2379
- developerTestAccountLimit: limit => `Your account reached the limit of ${limit} developer test accounts.`,
2469
+ developerTestAccountLimit: (limit) => `Your account reached the limit of ${limit} developer test accounts.`,
2380
2470
  confirmDefaultAccount: (accountName, accountType) => `Continue testing on ${chalk_1.default.bold(`${accountName} (${accountType})`)}? (Y/n)`,
2381
- confirmUseExistingDeveloperTestAccount: accountName => `Continue with ${accountName}? This account isn't currently connected to the HubSpot CLI. By continuing, you'll be prompted to generate a personal access key and connect it.`,
2471
+ confirmUseExistingDeveloperTestAccount: (accountName) => `Continue with ${accountName}? This account isn't currently connected to the HubSpot CLI. By continuing, you'll be prompted to generate a personal access key and connect it.`,
2382
2472
  noAccountId: 'No account ID found for the selected account. Please try again.',
2383
2473
  },
2384
2474
  projectLogsPrompt: {
2385
- functionName: projectName => `[--function] Select function in ${chalk_1.default.bold(projectName)} project`,
2475
+ functionName: (projectName) => `[--function] Select function in ${chalk_1.default.bold(projectName)} project`,
2386
2476
  },
2387
2477
  setAsDefaultAccountPrompt: {
2388
2478
  setAsDefaultAccountMessage: 'Set this account as the default?',
2389
- setAsDefaultAccount: accountName => `Account "${accountName}" set as the default account`,
2390
- keepingCurrentDefault: accountName => `Account "${accountName}" will continue to be the default account`,
2479
+ setAsDefaultAccount: (accountName) => `Account "${accountName}" set as the default account`,
2480
+ keepingCurrentDefault: (accountName) => `Account "${accountName}" will continue to be the default account`,
2391
2481
  },
2392
2482
  accountNamePrompt: {
2393
2483
  enterAccountName: 'Enter a unique name to reference this account in the CLI:',
2394
2484
  enterDeveloperTestAccountName: 'Name your developer test account:',
2395
2485
  enterStandardSandboxName: 'Name your standard sandbox:',
2396
2486
  enterDevelopmentSandboxName: 'Name your development sandbox:',
2397
- sandboxDefaultName: sandboxType => `New ${sandboxType} sandbox`,
2398
- developerTestAccountDefaultName: count => `Developer test account ${count}`,
2487
+ sandboxDefaultName: (sandboxType) => `New ${sandboxType} sandbox`,
2488
+ developerTestAccountDefaultName: (count) => `Developer test account ${count}`,
2399
2489
  errors: {
2400
2490
  invalidName: 'You entered an invalid name. Please try again.',
2401
2491
  nameRequired: 'The name may not be blank. Please try again.',
2402
2492
  spacesInName: 'The name may not contain spaces. Please try again.',
2403
- accountNameExists: name => `Account with name "${name}" already exists in the CLI config, please enter a different name.`,
2493
+ accountNameExists: (name) => `Account with name "${name}" already exists in the CLI config, please enter a different name.`,
2404
2494
  },
2405
2495
  },
2406
2496
  personalAccessKeyPrompt: {
@@ -2413,7 +2503,7 @@ exports.lib = {
2413
2503
  personalAccessKeyBrowserOpenPrep: "A personal access key is required to authenticate the CLI to interact with your HubSpot account. We'll open a secure page in your default browser where you can view and copy your personal access key.",
2414
2504
  personalAccessKeyBrowserOpenPrompt: 'Open HubSpot to copy your personal access key?',
2415
2505
  logs: {
2416
- openingWebBrowser: url => `Opening ${url} in your web browser`,
2506
+ openingWebBrowser: (url) => `Opening ${url} in your web browser`,
2417
2507
  },
2418
2508
  errors: {
2419
2509
  invalidAccountId: 'You did not enter a valid account ID. Please try again.',
@@ -2469,19 +2559,19 @@ exports.lib = {
2469
2559
  destRequired: 'A project dest is required',
2470
2560
  invalidDest: 'There is an existing project at this destination. Please provide a new path for this project.',
2471
2561
  invalidCharacters: 'The selected destination contains invalid characters. Please provide a new path and try again.',
2472
- invalidTemplate: template => `[--template] Could not find template "${template}". Please choose an available template:`,
2562
+ invalidTemplate: (template) => `[--template] Could not find template "${template}". Please choose an available template:`,
2473
2563
  projectTemplateRequired: 'Project template is required when projectTemplates is provided',
2474
2564
  },
2475
2565
  },
2476
2566
  selectPublicAppPrompt: {
2477
- selectAppIdMigrate: accountName => `[--appId] Choose an app under ${accountName} to migrate:`,
2478
- selectAppIdClone: accountName => `[--appId] Choose an app under ${accountName} to clone:`,
2567
+ selectAppIdMigrate: (accountName) => `[--appId] Choose an app under ${accountName} to migrate:`,
2568
+ selectAppIdClone: (accountName) => `[--appId] Choose an app under ${accountName} to clone:`,
2479
2569
  errors: {
2480
2570
  noAccountId: 'An account ID is required to select an app.',
2481
2571
  noAppsMigration: () => `${chalk_1.default.bold('No apps to migrate')}`,
2482
2572
  noAppsClone: () => `${chalk_1.default.bold('No apps to clone')}`,
2483
- noAppsMigrationMessage: accountName => `The selected developer account ${chalk_1.default.bold(accountName)} doesn't have any apps that can be migrated to the projects framework.`,
2484
- noAppsCloneMessage: accountName => `The selected developer account ${chalk_1.default.bold(accountName)} doesn't have any apps that can be cloned to the projects framework.`,
2573
+ noAppsMigrationMessage: (accountName) => `The selected developer account ${chalk_1.default.bold(accountName)} doesn't have any apps that can be migrated to the projects framework.`,
2574
+ noAppsCloneMessage: (accountName) => `The selected developer account ${chalk_1.default.bold(accountName)} doesn't have any apps that can be cloned to the projects framework.`,
2485
2575
  errorFetchingApps: 'There was an error fetching public apps.',
2486
2576
  cannotBeMigrated: 'Cannot be migrated',
2487
2577
  },
@@ -2498,7 +2588,7 @@ exports.lib = {
2498
2588
  enterName: '[--name] Give your component a name: ',
2499
2589
  errors: {
2500
2590
  nameRequired: 'A component name is required',
2501
- invalidType: type => `[--type] Could not find type "${type}". Please choose an available type:`,
2591
+ invalidType: (type) => `[--type] Could not find type "${type}". Please choose an available type:`,
2502
2592
  },
2503
2593
  },
2504
2594
  secretPrompt: {
@@ -2526,7 +2616,7 @@ exports.lib = {
2526
2616
  srcRequired: 'You must specify a source directory.',
2527
2617
  destRequired: 'You must specify a destination directory.',
2528
2618
  },
2529
- fieldsPrompt: dir => `Multiple fields files located in "${dir}". Please choose which to upload: `,
2619
+ fieldsPrompt: (dir) => `Multiple fields files located in "${dir}". Please choose which to upload: `,
2530
2620
  },
2531
2621
  projectNamePrompt: {
2532
2622
  enterName: '[--project] Enter project name:',
@@ -2555,8 +2645,8 @@ exports.lib = {
2555
2645
  selectTable: 'Select a HubDB table:',
2556
2646
  enterDest: 'Enter the destination path:',
2557
2647
  errors: {
2558
- noTables: accountId => `No HubDB tables found in account ${accountId}`,
2559
- errorFetchingTables: accountId => `Unable to fetch HubDB tables in account ${accountId}`,
2648
+ noTables: (accountId) => `No HubDB tables found in account ${accountId}`,
2649
+ errorFetchingTables: (accountId) => `Unable to fetch HubDB tables in account ${accountId}`,
2560
2650
  destRequired: 'A destination is required',
2561
2651
  invalidDest: 'The selected destination already exists. Please provide a new path.',
2562
2652
  invalidCharacters: 'The selected destination contains invalid characters. Please provide a new path and try again.',
@@ -2578,8 +2668,8 @@ exports.lib = {
2578
2668
  developerTestAccount: {
2579
2669
  create: {
2580
2670
  loading: {
2581
- add: accountName => `Creating developer test account ${chalk_1.default.bold(accountName)}`,
2582
- fail: accountName => `Failed to create a developer test account ${chalk_1.default.bold(accountName)}.`,
2671
+ add: (accountName) => `Creating developer test account ${chalk_1.default.bold(accountName)}`,
2672
+ fail: (accountName) => `Failed to create a developer test account ${chalk_1.default.bold(accountName)}.`,
2583
2673
  succeed: (accountName, accountId) => `Successfully created a developer test account ${chalk_1.default.bold(accountName)} with portalId ${chalk_1.default.bold(accountId)}.`,
2584
2674
  },
2585
2675
  success: {
@@ -2600,8 +2690,8 @@ exports.lib = {
2600
2690
  create: {
2601
2691
  developer: {
2602
2692
  loading: {
2603
- add: accountName => `Creating developer sandbox ${chalk_1.default.bold(accountName)}`,
2604
- fail: accountName => `Failed to create a developer sandbox ${chalk_1.default.bold(accountName)}.`,
2693
+ add: (accountName) => `Creating developer sandbox ${chalk_1.default.bold(accountName)}`,
2694
+ fail: (accountName) => `Failed to create a developer sandbox ${chalk_1.default.bold(accountName)}.`,
2605
2695
  succeed: (accountName, accountId) => `Successfully created a developer sandbox ${chalk_1.default.bold(accountName)} with portalId ${chalk_1.default.bold(accountId)}.`,
2606
2696
  },
2607
2697
  success: {
@@ -2620,8 +2710,8 @@ exports.lib = {
2620
2710
  },
2621
2711
  standard: {
2622
2712
  loading: {
2623
- add: accountName => `Creating standard sandbox ${chalk_1.default.bold(accountName)}`,
2624
- fail: accountName => `Failed to create a standard sandbox ${chalk_1.default.bold(accountName)}.`,
2713
+ add: (accountName) => `Creating standard sandbox ${chalk_1.default.bold(accountName)}`,
2714
+ fail: (accountName) => `Failed to create a standard sandbox ${chalk_1.default.bold(accountName)}.`,
2625
2715
  succeed: (accountName, accountId) => `Successfully created a standard sandbox ${chalk_1.default.bold(accountName)} with portalId ${chalk_1.default.bold(accountId)}.`,
2626
2716
  },
2627
2717
  success: {
@@ -2640,9 +2730,9 @@ exports.lib = {
2640
2730
  },
2641
2731
  sync: {
2642
2732
  loading: {
2643
- add: accountName => `Syncing sandbox ${chalk_1.default.bold(accountName)}`,
2644
- fail: accountName => `Failed to sync sandbox ${chalk_1.default.bold(accountName)}.`,
2645
- succeed: accountName => `Successfully synced sandbox ${chalk_1.default.bold(accountName)}.`,
2733
+ add: (accountName) => `Syncing sandbox ${chalk_1.default.bold(accountName)}`,
2734
+ fail: (accountName) => `Failed to sync sandbox ${chalk_1.default.bold(accountName)}.`,
2735
+ succeed: (accountName) => `Successfully synced sandbox ${chalk_1.default.bold(accountName)}.`,
2646
2736
  },
2647
2737
  success: {
2648
2738
  configFileUpdated: (accountName, authType) => `Account "${accountName}" updated using "${authType}"`,
@@ -2658,27 +2748,27 @@ exports.lib = {
2658
2748
  },
2659
2749
  errorHandlers: {
2660
2750
  index: {
2661
- errorOccurred: error => `Error: ${error}`,
2662
- errorContext: context => `Context: ${context}`,
2663
- errorCause: cause => `Cause: ${cause}`,
2751
+ errorOccurred: (error) => `Error: ${error}`,
2752
+ errorContext: (context) => `Context: ${context}`,
2753
+ errorCause: (cause) => `Cause: ${cause}`,
2664
2754
  unknownErrorOccurred: 'An unknown error has occurred.',
2665
2755
  },
2666
2756
  suppressErrors: {
2667
2757
  platformVersionErrors: {
2668
2758
  header: 'Platform version update required',
2669
- unspecifiedPlatformVersion: platformVersion => `Projects with an ${chalk_1.default.bold(platformVersion)} are no longer supported.`,
2670
- platformVersionRetired: platformVersion => `Projects with ${chalk_1.default.bold(`platformVersion ${platformVersion}`)} are no longer supported.`,
2671
- nonExistentPlatformVersion: platformVersion => `Projects with ${chalk_1.default.bold(`platformVersion ${platformVersion}`)} are not supported.`,
2759
+ unspecifiedPlatformVersion: (platformVersion) => `Projects with an ${chalk_1.default.bold(platformVersion)} are no longer supported.`,
2760
+ platformVersionRetired: (platformVersion) => `Projects with ${chalk_1.default.bold(`platformVersion ${platformVersion}`)} are no longer supported.`,
2761
+ nonExistentPlatformVersion: (platformVersion) => `Projects with ${chalk_1.default.bold(`platformVersion ${platformVersion}`)} are not supported.`,
2672
2762
  updateProject: 'Please update your project to the latest version and try again.',
2673
2763
  docsLink: 'Projects platform versioning (BETA)',
2674
- betaLink: docsLink => `For more info, see ${docsLink}.`,
2764
+ betaLink: (docsLink) => `For more info, see ${docsLink}.`,
2675
2765
  },
2676
2766
  missingScopeError: (request, accountName, authCommand) => `Couldn't execute the ${request} because the access key for ${accountName} is missing required scopes. To update scopes, run ${authCommand}. Then deactivate the existing key and generate a new one that includes the missing scopes.`,
2677
2767
  },
2678
2768
  },
2679
2769
  serverless: {
2680
2770
  verifyAccessKeyAndUserAccess: {
2681
- fetchScopeDataError: scopeGroup => `Error verifying access of scopeGroup ${scopeGroup}:`,
2771
+ fetchScopeDataError: (scopeGroup) => `Error verifying access of scopeGroup ${scopeGroup}:`,
2682
2772
  portalMissingScope: 'Your account does not have access to this action. Talk to an account admin to request it.',
2683
2773
  userMissingScope: "You don't have access to this action. Ask an account admin to change your permissions in Users & Teams settings.",
2684
2774
  genericMissingScope: 'Your access key does not allow this action. Please generate a new access key by running `hs auth personalaccesskey`.',
@@ -2690,49 +2780,49 @@ exports.lib = {
2690
2780
  accountChecks: {
2691
2781
  active: 'Default account active',
2692
2782
  inactive: "Default account isn't active",
2693
- inactiveSecondary: command => `Run ${command} to remove inactive accounts from your CLI config`,
2783
+ inactiveSecondary: (command) => `Run ${command} to remove inactive accounts from your CLI config`,
2694
2784
  unableToDetermine: 'Unable to determine if the portal is active',
2695
2785
  pak: {
2696
2786
  incomplete: 'Personal access key is valid, but there are more scopes available to your user that are not included in your key.',
2697
2787
  incompleteSecondary: (command, link) => `To add the available scopes, run ${command} and re-authenticate your account with a new key that has those scopes. Visit HubSpot to view selected and available scopes for your personal access key. ${link}`,
2698
2788
  invalid: 'Personal access key is invalid',
2699
- invalidSecondary: command => `To get a new key, run ${command}, deactivate your access key, and generate a new one. Then use that new key to authenticate your account.`,
2700
- valid: link => `Personal Access Key is valid. ${link}`,
2789
+ invalidSecondary: (command) => `To get a new key, run ${command}, deactivate your access key, and generate a new one. Then use that new key to authenticate your account.`,
2790
+ valid: (link) => `Personal Access Key is valid. ${link}`,
2701
2791
  viewScopes: 'View selected scopes',
2702
2792
  },
2703
2793
  },
2704
2794
  nodeChecks: {
2705
2795
  unableToDetermine: 'Unable to determine what version of node is installed',
2706
- minimumNotMet: nodeVersion => `Minimum Node version is not met. Upgrade to ${nodeVersion} or higher`,
2707
- success: nodeVersion => `node v${nodeVersion} is installed`,
2796
+ minimumNotMet: (nodeVersion) => `Minimum Node version is not met. Upgrade to ${nodeVersion} or higher`,
2797
+ success: (nodeVersion) => `node v${nodeVersion} is installed`,
2708
2798
  },
2709
2799
  npmChecks: {
2710
2800
  notInstalled: 'npm is not installed',
2711
- installed: npmVersion => `npm v${npmVersion} is installed`,
2801
+ installed: (npmVersion) => `npm v${npmVersion} is installed`,
2712
2802
  unableToDetermine: 'Unable to determine if npm is installed',
2713
2803
  },
2714
2804
  hsChecks: {
2715
- notLatest: hsVersion => `Version ${hsVersion} outdated`,
2805
+ notLatest: (hsVersion) => `Version ${hsVersion} outdated`,
2716
2806
  notLatestSecondary: (command, hsVersion) => `Run ${command} to upgrade to the latest version ${hsVersion}`,
2717
- latest: hsVersion => `HubSpot CLI v${hsVersion} up to date`,
2807
+ latest: (hsVersion) => `HubSpot CLI v${hsVersion} up to date`,
2718
2808
  unableToDetermine: 'Unable to determine if HubSpot CLI is up to date.',
2719
2809
  unableToDetermineSecondary: (command, link) => `Run ${command} to check your installed version; then visit the ${link} to validate whether you have the latest version`,
2720
2810
  unableToDetermineSecondaryLink: 'npm HubSpot CLI version history',
2721
2811
  },
2722
2812
  projectDependenciesChecks: {
2723
- missingDependencies: dir => `missing dependencies in ${chalk_1.default.bold(dir)}`,
2724
- missingDependenciesSecondary: command => `Run ${command} to install all project dependencies locally`,
2725
- unableToDetermine: dir => `Unable to determine if dependencies are installed ${dir}`,
2813
+ missingDependencies: (dir) => `missing dependencies in ${chalk_1.default.bold(dir)}`,
2814
+ missingDependenciesSecondary: (command) => `Run ${command} to install all project dependencies locally`,
2815
+ unableToDetermine: (dir) => `Unable to determine if dependencies are installed ${dir}`,
2726
2816
  success: 'App dependencies are installed and up to date',
2727
2817
  },
2728
2818
  files: {
2729
- invalidJson: filename => `invalid JSON in ${chalk_1.default.bold(filename)}`,
2819
+ invalidJson: (filename) => `invalid JSON in ${chalk_1.default.bold(filename)}`,
2730
2820
  validJson: 'JSON files valid',
2731
2821
  },
2732
2822
  port: {
2733
- inUse: port => `Port ${port} is in use`,
2734
- inUseSecondary: command => `Make sure it is available before running ${command}`,
2735
- available: port => `Port ${port} available for local development`,
2823
+ inUse: (port) => `Port ${port} is in use`,
2824
+ inUseSecondary: (command) => `Make sure it is available before running ${command}`,
2825
+ available: (port) => `Port ${port} available for local development`,
2736
2826
  },
2737
2827
  diagnosis: {
2738
2828
  cli: {
@@ -2740,19 +2830,19 @@ exports.lib = {
2740
2830
  },
2741
2831
  cliConfig: {
2742
2832
  header: 'CLI configuration',
2743
- configFileSubHeader: filename => `Config File: ${chalk_1.default.bold(filename)}`,
2744
- defaultAccountSubHeader: accountDetails => `Default Account: ${accountDetails}`,
2833
+ configFileSubHeader: (filename) => `Config File: ${chalk_1.default.bold(filename)}`,
2834
+ defaultAccountSubHeader: (accountDetails) => `Default Account: ${accountDetails}`,
2745
2835
  noConfigFile: 'CLI configuration not found',
2746
- noConfigFileSecondary: command => `Run ${command} and follow the prompts to create your CLI configuration file and connect it to your HubSpot account`,
2836
+ noConfigFileSecondary: (command) => `Run ${command} and follow the prompts to create your CLI configuration file and connect it to your HubSpot account`,
2747
2837
  },
2748
2838
  projectConfig: {
2749
2839
  header: 'Project configuration',
2750
- projectDirSubHeader: projectDir => `Project dir: ${chalk_1.default.bold(projectDir)}`,
2751
- projectNameSubHeader: projectName => `Project name: ${chalk_1.default.bold(projectName)}`,
2840
+ projectDirSubHeader: (projectDir) => `Project dir: ${chalk_1.default.bold(projectDir)}`,
2841
+ projectNameSubHeader: (projectName) => `Project name: ${chalk_1.default.bold(projectName)}`,
2752
2842
  },
2753
2843
  counts: {
2754
- errors: count => `${chalk_1.default.bold('Errors:')} ${count}`,
2755
- warnings: count => `${chalk_1.default.bold('Warning:')} ${count}`,
2844
+ errors: (count) => `${chalk_1.default.bold('Errors:')} ${count}`,
2845
+ warnings: (count) => `${chalk_1.default.bold('Warning:')} ${count}`,
2756
2846
  },
2757
2847
  },
2758
2848
  },
@@ -2760,8 +2850,8 @@ exports.lib = {
2760
2850
  missingClientId: 'Error building oauth URL: missing client ID.',
2761
2851
  },
2762
2852
  migrate: {
2763
- componentsToBeMigrated: components => `The following features will be migrated: ${components}`,
2764
- componentsThatWillNotBeMigrated: components => `[NOTE] These features are not yet supported for migration but will be available later: ${components}`,
2853
+ componentsToBeMigrated: (components) => `The following features will be migrated: ${components}`,
2854
+ componentsThatWillNotBeMigrated: (components) => `[NOTE] These features are not yet supported for migration but will be available later: ${components}`,
2765
2855
  sourceContentsMoved: (newLocation) => `The contents of your old source directory have been moved to ${newLocation}, move any required files to the new source directory.`,
2766
2856
  projectMigrationWarningTitle: '⚠️ Important: Migrating to platformVersion 2025.2 is irreversible ⚠️',
2767
2857
  projectMigrationWarning: (0, ui_1.uiBetaTag)(`Running the ${(0, ui_1.uiCommandReference)('hs project migrate')} command will permanently upgrade your project to platformVersion 2025.2. This action cannot be undone. To ensure you have access to your original files, they will be copied to a new directory (archive) for safekeeping.\n\nThis command will guide you through the process, prompting you to enter the required fields and will download the new project source code into your project source directory.`, false),
@@ -2770,7 +2860,7 @@ exports.lib = {
2770
2860
  invalidConfig: 'The project configuration file is invalid. Please check the config file and try again.',
2771
2861
  doesNotExist: (account) => `Project does not exist in ${(0, ui_1.uiAccountDescription)(account)}. Migrations are only supported for existing projects.`,
2772
2862
  multipleApps: 'Multiple apps found in project, this is not allowed in 2025.2',
2773
- alreadyExists: projectName => `A project with name ${projectName} already exists. Please choose another name.`,
2863
+ alreadyExists: (projectName) => `A project with name ${projectName} already exists. Please choose another name.`,
2774
2864
  },
2775
2865
  unmigratableReasons: {
2776
2866
  upToDate: 'App is already up to date',
@@ -2778,21 +2868,21 @@ exports.lib = {
2778
2868
  listedInMarketplace: 'Listed apps are not currently migratable',
2779
2869
  projectConnectedToGitHub: (projectName, accountId) => `The project is linked to a GitHub repository. ${(0, ui_1.uiLink)('Visit the project settings page to unlink it', (0, urls_1.getProjectSettingsUrl)(projectName, accountId))}`,
2780
2870
  partOfProjectAlready: `This app is part of a project, run ${(0, ui_1.uiCommandReference)('hs project migrate')} from the project directory to migrate it`,
2781
- generic: reasonCode => `Unable to migrate app: ${reasonCode}`,
2871
+ generic: (reasonCode) => `Unable to migrate app: ${reasonCode}`,
2782
2872
  },
2783
2873
  noAppsEligible: (accountId, reasons) => `No apps in account ${accountId} are currently migratable${reasons.length ? `\n - ${reasons.join('\n - ')}` : ''}`,
2784
2874
  invalidAccountTypeTitle: `${chalk_1.default.bold('Developer account not targeted')}`,
2785
2875
  invalidAccountTypeDescription: (useCommand, authCommand) => `Only public apps created in a developer account can be converted to a project component. Select a connected developer account with ${useCommand} or ${authCommand} and try again.`,
2786
- appWithAppIdNotFound: appId => `Could not find an app with the id ${appId} `,
2876
+ appWithAppIdNotFound: (appId) => `Could not find an app with the id ${appId} `,
2787
2877
  noAppsForProject: (projectName) => `No apps associated with project ${projectName}`,
2788
2878
  migrationFailed: 'Migration Failed',
2789
- notUngatedForUnifiedApps: account => `Your account ${account} isn't enrolled in the required product beta to access this command.`,
2879
+ notUngatedForUnifiedApps: (account) => `Your account ${account} isn't enrolled in the required product beta to access this command.`,
2790
2880
  },
2791
2881
  prompt: {
2792
2882
  chooseApp: 'Which app would you like to migrate?',
2793
2883
  inputName: '[--name] What would you like to name the project?',
2794
2884
  inputDest: '[--dest] Where would you like to save the project?',
2795
- uidForComponent: componentName => `What UID would you like to use for ${componentName}?`,
2885
+ uidForComponent: (componentName) => `What UID would you like to use for ${componentName}?`,
2796
2886
  proceed: 'Would you like to proceed?',
2797
2887
  },
2798
2888
  spinners: {