@hubspot/cms-cli
Advanced tools
Comparing version 2.1.1-beta.4 to 2.1.1-beta.5
@@ -66,3 +66,3 @@ const { | ||
exports.command = 'auth <type>'; | ||
exports.command = 'auth [type]'; | ||
exports.describe = `Configure authentication for a HubSpot account. Supported authentication protocols are ${SUPPORTED_AUTHENTICATION_PROTOCOLS_TEXT}.`; | ||
@@ -82,2 +82,3 @@ | ||
if (!validateConfig()) { | ||
logger.info('To create a new config file, use the "hs init" command.'); | ||
process.exit(1); | ||
@@ -84,0 +85,0 @@ } |
@@ -24,8 +24,9 @@ const { | ||
const { logDebugInfo } = require('../../lib/debugInfo'); | ||
const { secretValuePrompt } = require('../../lib/secretPrompt'); | ||
exports.command = 'add <name> <value>'; | ||
exports.command = 'add <name>'; | ||
exports.describe = 'Add a HubSpot secret'; | ||
exports.handler = async options => { | ||
const { config: configPath, name: secretName, value: secretValue } = options; | ||
const { config: configPath, name: secretName } = options; | ||
@@ -44,2 +45,4 @@ setLogLevel(options); | ||
try { | ||
const { secretValue } = await secretValuePrompt(); | ||
await addSecret(portalId, secretName, secretValue); | ||
@@ -70,7 +73,3 @@ logger.log( | ||
}); | ||
yargs.positional('value', { | ||
describe: 'The secret to be stored such as an API key', | ||
type: 'string', | ||
}); | ||
return yargs; | ||
}; |
@@ -24,8 +24,9 @@ const { | ||
const { logDebugInfo } = require('../../lib/debugInfo'); | ||
const { secretValuePrompt } = require('../../lib/secretPrompt'); | ||
exports.command = 'update <name> <value>'; | ||
exports.command = 'update <name>'; | ||
exports.describe = 'Update an existing HubSpot secret'; | ||
exports.handler = async options => { | ||
const { name: secretName, value: secretValue, config: configPath } = options; | ||
const { name: secretName, config: configPath } = options; | ||
@@ -44,2 +45,4 @@ setLogLevel(options); | ||
try { | ||
const { secretValue } = await secretValuePrompt(); | ||
await updateSecret(portalId, secretName, secretValue); | ||
@@ -70,7 +73,3 @@ logger.log( | ||
}); | ||
yargs.positional('value', { | ||
describe: 'The secret to be stored', | ||
type: 'string', | ||
}); | ||
return yargs; | ||
}; |
{ | ||
"name": "@hubspot/cms-cli", | ||
"version": "2.1.1-beta.4", | ||
"version": "2.1.1-beta.5", | ||
"description": "CLI for interacting with the HubSpot CMS", | ||
@@ -11,3 +11,3 @@ "license": "Apache-2.0", | ||
"dependencies": { | ||
"@hubspot/cms-lib": "^2.1.1-beta.4", | ||
"@hubspot/cms-lib": "^2.1.1-beta.5", | ||
"chalk": "^4.1.0", | ||
@@ -35,3 +35,3 @@ "commander": "^2.16.0", | ||
}, | ||
"gitHead": "4d71b65749294b3e3825b0d96e31d943adcd62ee" | ||
"gitHead": "1d963cb5619eb6d7c6f971686fce81c048fd5e0e" | ||
} |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
123139
68
3537