New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

cli-engine-heroku

Package Overview
Dependencies
Maintainers
3
Versions
61
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

cli-engine-heroku - npm Package Compare versions

Comparing version

to
5.0.0-ts.3

5

lib/api_client.d.ts
import { HTTP, HTTPError, HTTPRequestOptions } from 'http-call';
import { Mutex } from './mutex';
import { Config } from 'cli-engine-config';
import { CLI } from 'cli-ux';
import { deps } from './deps';

@@ -32,6 +31,4 @@ export declare type Options = {

config: Config;
cli: CLI;
constructor({config, cli}: {
constructor({config}: {
config: Config;
cli?: CLI;
}, options?: Options);

@@ -38,0 +35,0 @@ _twoFactorMutex: Mutex<string>;

7

lib/api_client.js

@@ -29,5 +29,4 @@ "use strict";

class APIClient {
constructor({ config, cli }, options = {}) {
constructor({ config }, options = {}) {
this.config = config;
this.cli = cli || new deps_1.deps.CLI(config);
if (options.required === undefined)

@@ -89,2 +88,4 @@ options.required = true;

get auth() {
if (process.env.HEROKU_API_TOKEN)
deps_1.deps.cli.warn('HEROKU_API_TOKEN is set but you probably meant HEROKU_API_KEY');
let auth = process.env.HEROKU_API_KEY;

@@ -102,3 +103,3 @@ if (!auth) {

try {
let factor = await this.cli.prompt('Two-factor code', { type: 'mask' });
let factor = await deps_1.deps.cli.prompt('Two-factor code', { type: 'mask' });
deps_1.deps.yubikey.disable();

@@ -105,0 +106,0 @@ return factor;

@@ -13,3 +13,3 @@ "use strict";

return this._heroku;
this._heroku = new api_client_1.APIClient({ config: this.config, cli: this.cli });
this._heroku = new api_client_1.APIClient({ config: this.config });
return this._heroku;

@@ -16,0 +16,0 @@ }

@@ -14,4 +14,4 @@ /// <reference types="node" />

readonly Mutex: typeof mutex.Mutex;
readonly CLI: typeof cli.CLI;
readonly cli: cli.CLI;
readonly HTTP: typeof http.HTTP;
};

@@ -13,4 +13,4 @@ "use strict";

},
get CLI() {
return fetch('cli-ux').CLI;
get cli() {
return fetch('cli-ux').default;
},

@@ -17,0 +17,0 @@ get HTTP() {

{
"name": "cli-engine-heroku",
"description": "heroku specific functionality for the cli-engine",
"version": "5.0.0-ts.2",
"version": "5.0.0-ts.3",
"author": "Jeff Dickey @dickeyxxx",

@@ -10,3 +10,4 @@ "bugs": "https://github.com/heroku/cli-engine-heroku/issues",

"chalk": "^2.1.0",
"cli-ux": "^1.1.9",
"cli-flags": "1.0.16",
"cli-ux": "^2.0.1",
"fs-extra": "^4.0.2",

@@ -23,19 +24,19 @@ "heroku-client": "^3.0.3",

"@types/fs-extra": "^4.0.2",
"@types/jest": "^20.0.8",
"@types/jest": "^21.1.2",
"@types/nock": "^8.2.1",
"@types/node": "^8.0.28",
"@types/node": "^8.0.32",
"@types/supports-color": "^3.1.0",
"babel-core": "^6.26.0",
"cli-engine-command": "^9.0.0-ts.11",
"cli-engine-config": "^4.0.1-ts.15",
"cli-engine-command": "9.0.0-ts.12",
"cli-engine-config": "4.0.1-ts.16",
"del-cli": "^1.1.0",
"husky": "^0.14.3",
"jest": "^21.1.0",
"lint-staged": "^4.2.1",
"jest": "^21.2.1",
"lint-staged": "^4.2.3",
"nock": "^9.0.14",
"prettier": "^1.7.0",
"prettier": "^1.7.4",
"remap-istanbul": "^0.9.5",
"source-map-support": "^0.4.18",
"source-map-support": "^0.5.0",
"ts-jest": "^21.0.1",
"typescript": "^2.5.2"
"typescript": "^2.5.3"
},

@@ -42,0 +43,0 @@ "files": [