@airtable/blocks-cli
Advanced tools
Comparing version 2.0.3 to 2.0.4
@@ -30,3 +30,3 @@ "use strict"; | ||
} | ||
apiKey = await cli_ux_1.default.prompt('What is your Airtable API Key?', { | ||
apiKey = await cli_ux_1.default.prompt('What is your Airtable personal access token (with block:manage scope)?', { | ||
type: 'mask', | ||
@@ -37,13 +37,13 @@ required: true, | ||
const locationPath = await system_api_key_1.findApiKeyConfigPathAsync(this.system, flags.location); | ||
this.log(`Saving API Key to: ${locationPath}`); | ||
this.log(`Saving personal access token to: ${locationPath}`); | ||
await system_api_key_1.writeApiKeyAsync(this.system, flags.location, apiKey, apiKeyName); | ||
this.log(`API Key${apiKeyName ? ` '${apiKeyName}'` : ''} saved.`); | ||
this.log(`Personal access token${apiKeyName ? ` '${apiKeyName}'` : ''} saved.`); | ||
} | ||
} | ||
exports.default = SetApiKey; | ||
SetApiKey.description = 'Set an api key for an airtable account to upload to'; | ||
SetApiKey.description = 'Set a personal access token (with block:manage scope) for an Airtable account to upload to'; | ||
SetApiKey.examples = [ | ||
`$ block set-api-key | ||
$ block set-api-key APIKEY | ||
$ block set-api-key --location app APIKEY | ||
$ block set-api-key TOKEN | ||
$ block set-api-key --location app TOKEN | ||
`, | ||
@@ -58,3 +58,3 @@ ]; | ||
'api-key-name': command_1.flags.string({ | ||
description: 'The name of the API key to set', | ||
description: 'The name of the personal access token to set', | ||
hidden: true, | ||
@@ -61,0 +61,0 @@ }), |
@@ -1,1 +0,1 @@ | ||
{"version":"2.0.3","commands":{"add-remote":{"id":"add-remote","description":"[Beta] Add a new remote configuration","pluginName":"@airtable/blocks-cli","pluginType":"core","aliases":[],"examples":["$ block add-remote app12345678/blk12345678 new-remote\n"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false},"server":{"name":"server","type":"option","description":"API server endpoint for the remote","hidden":true},"api-key-name":{"name":"api-key-name","type":"option","description":"The name of the API key this remote should use","hidden":true}},"args":[{"name":"blockIdentifier","required":true},{"name":"remoteName","required":true}]},"init":{"id":"init","description":"Initialize an Airtable extension project","pluginName":"@airtable/blocks-cli","pluginType":"core","aliases":[],"examples":["$ block init app12345678/blk12345678 hello-world-extension --template https://github.com/Airtable/apps-hello-world\n"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false},"template":{"name":"template","type":"option","default":"https://github.com/Airtable/apps-hello-world"}},"args":[{"name":"blockIdentifier","required":true},{"name":"blockDirPath","required":true}]},"list-remotes":{"id":"list-remotes","description":"[Beta] List remote configurations","pluginName":"@airtable/blocks-cli","pluginType":"core","aliases":[],"examples":["$ block list-remotes\n"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[]},"release":{"id":"release","description":"Release a build to an Airtable base","pluginName":"@airtable/blocks-cli","pluginType":"core","aliases":[],"examples":["$ block release"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false},"remote":{"name":"remote","type":"option","description":"[Beta] Configure which remote to use"},"comment":{"name":"comment","type":"option","description":"A string describing the changes in this release. Can be at most 1000 characters","hidden":true},"upload-source-maps-to-sentry":{"name":"upload-source-maps-to-sentry","type":"boolean","description":"Uploads the source map for the block's frontend bundle to the specified sentry project. Need to also set BLOCKS_CLI_SENTRY_{AUTH_TOKEN|ORG|PROJECT} environment variables.","hidden":true,"allowNo":false}},"args":[]},"remove-remote":{"id":"remove-remote","description":"[Beta] Remove a remote configuration","pluginName":"@airtable/blocks-cli","pluginType":"core","aliases":[],"examples":["$ block remove-remote old-remote\n"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"remoteName","required":true}]},"run":{"id":"run","description":"Run the extension locally","pluginName":"@airtable/blocks-cli","pluginType":"core","aliases":[],"examples":["$ block run\n"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false},"port":{"name":"port","type":"option","description":"HTTPS port the server listens on. The server will listen for HTTP on PORT + 1.","default":9000},"remote":{"name":"remote","type":"option","description":"[Beta] Configure which remote to use"},"sdk-repo":{"name":"sdk-repo","type":"option","hidden":true}},"args":[]},"set-api-key":{"id":"set-api-key","description":"Set an api key for an airtable account to upload to","pluginName":"@airtable/blocks-cli","pluginType":"core","aliases":[],"examples":["$ block set-api-key\n$ block set-api-key APIKEY\n$ block set-api-key --location app APIKEY\n"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false},"location":{"name":"location","type":"option","helpValue":"(user|app)","options":["user","app"],"default":"user"},"api-key-name":{"name":"api-key-name","type":"option","description":"The name of the API key to set","hidden":true}},"args":[{"name":"apiKey","required":false}]},"submit":{"id":"submit","description":"Submit extension for review for listing in the the Airtable Marketplace","pluginName":"@airtable/blocks-cli","pluginType":"core","aliases":[],"examples":["$ block submit\n"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false},"remote":{"name":"remote","type":"option","description":"Configure which remote to use"}},"args":[]}}} | ||
{"version":"2.0.4","commands":{"add-remote":{"id":"add-remote","description":"[Beta] Add a new remote configuration","pluginName":"@airtable/blocks-cli","pluginType":"core","aliases":[],"examples":["$ block add-remote app12345678/blk12345678 new-remote\n"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false},"server":{"name":"server","type":"option","description":"API server endpoint for the remote","hidden":true},"api-key-name":{"name":"api-key-name","type":"option","description":"The name of the API key this remote should use","hidden":true}},"args":[{"name":"blockIdentifier","required":true},{"name":"remoteName","required":true}]},"init":{"id":"init","description":"Initialize an Airtable extension project","pluginName":"@airtable/blocks-cli","pluginType":"core","aliases":[],"examples":["$ block init app12345678/blk12345678 hello-world-extension --template https://github.com/Airtable/apps-hello-world\n"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false},"template":{"name":"template","type":"option","default":"https://github.com/Airtable/apps-hello-world"}},"args":[{"name":"blockIdentifier","required":true},{"name":"blockDirPath","required":true}]},"list-remotes":{"id":"list-remotes","description":"[Beta] List remote configurations","pluginName":"@airtable/blocks-cli","pluginType":"core","aliases":[],"examples":["$ block list-remotes\n"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[]},"release":{"id":"release","description":"Release a build to an Airtable base","pluginName":"@airtable/blocks-cli","pluginType":"core","aliases":[],"examples":["$ block release"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false},"remote":{"name":"remote","type":"option","description":"[Beta] Configure which remote to use"},"comment":{"name":"comment","type":"option","description":"A string describing the changes in this release. Can be at most 1000 characters","hidden":true},"upload-source-maps-to-sentry":{"name":"upload-source-maps-to-sentry","type":"boolean","description":"Uploads the source map for the block's frontend bundle to the specified sentry project. Need to also set BLOCKS_CLI_SENTRY_{AUTH_TOKEN|ORG|PROJECT} environment variables.","hidden":true,"allowNo":false}},"args":[]},"remove-remote":{"id":"remove-remote","description":"[Beta] Remove a remote configuration","pluginName":"@airtable/blocks-cli","pluginType":"core","aliases":[],"examples":["$ block remove-remote old-remote\n"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"remoteName","required":true}]},"run":{"id":"run","description":"Run the extension locally","pluginName":"@airtable/blocks-cli","pluginType":"core","aliases":[],"examples":["$ block run\n"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false},"port":{"name":"port","type":"option","description":"HTTPS port the server listens on. The server will listen for HTTP on PORT + 1.","default":9000},"remote":{"name":"remote","type":"option","description":"[Beta] Configure which remote to use"},"sdk-repo":{"name":"sdk-repo","type":"option","hidden":true}},"args":[]},"set-api-key":{"id":"set-api-key","description":"Set a personal access token (with block:manage scope) for an Airtable account to upload to","pluginName":"@airtable/blocks-cli","pluginType":"core","aliases":[],"examples":["$ block set-api-key\n$ block set-api-key TOKEN\n$ block set-api-key --location app TOKEN\n"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false},"location":{"name":"location","type":"option","helpValue":"(user|app)","options":["user","app"],"default":"user"},"api-key-name":{"name":"api-key-name","type":"option","description":"The name of the personal access token to set","hidden":true}},"args":[{"name":"apiKey","required":false}]},"submit":{"id":"submit","description":"Submit extension for review for listing in the the Airtable Marketplace","pluginName":"@airtable/blocks-cli","pluginType":"core","aliases":[],"examples":["$ block submit\n"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false},"remote":{"name":"remote","type":"option","description":"Configure which remote to use"}},"args":[]}}} |
{ | ||
"name": "@airtable/blocks-cli", | ||
"description": "Official command line tool for Airtable blocks development", | ||
"version": "2.0.3", | ||
"version": "2.0.4", | ||
"homepage": "https://airtable.com/developers/blocks", | ||
@@ -99,3 +99,3 @@ "author": "Airtable", | ||
"build": "rm -rf lib && rm -f tsconfig.tsbuildinfo && tsc --build", | ||
"ci": "yarn test", | ||
"ci": "echo '--- cli-next' && yarn test", | ||
"lint": "eslint . --ext .ts --config .eslintrc.js", | ||
@@ -102,0 +102,0 @@ "pack:typescript": "yarn build", |
@@ -27,3 +27,3 @@ # @airtable/blocks-cli | ||
$ block (-v|--version|version) | ||
@airtable/blocks-cli/2.0.3 darwin-arm64 node-v16.17.0 | ||
@airtable/blocks-cli/2.0.4 darwin-arm64 node-v16.17.0 | ||
$ block --help [COMMAND] | ||
@@ -162,3 +162,3 @@ USAGE | ||
Set an api key for an airtable account to upload to | ||
Set a personal access token (with block:manage scope) for an Airtable account to upload to | ||
@@ -175,4 +175,4 @@ ``` | ||
$ block set-api-key | ||
$ block set-api-key APIKEY | ||
$ block set-api-key --location app APIKEY | ||
$ block set-api-key TOKEN | ||
$ block set-api-key --location app TOKEN | ||
``` | ||
@@ -179,0 +179,0 @@ |
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
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
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
292571
7