Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

heroku-cli-util

Package Overview
Dependencies
Maintainers
2
Versions
155
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

heroku-cli-util - npm Package Compare versions

Comparing version 5.9.0 to 5.9.1

2

lib/table.js

@@ -93,3 +93,3 @@ 'use strict';

col.width = Math.max(
col.label.length,
_.result(col, 'label').length,
col.width,

@@ -96,0 +96,0 @@ calcWidth(cell)

{
"name": "heroku-cli-util",
"version": "5.9.0",
"version": "5.9.1",
"description": "Set of helpful CLI utilities",

@@ -5,0 +5,0 @@ "main": "index.js",

@@ -18,36 +18,14 @@ # heroku-cli-util

```js
let cli = require('heroku-cli-util');
let promise = heroku.apps(appname).info();
let app = yield cli.action('getting apps', promise);
console.log(`app name: ${app.name}`);
let cli = require('heroku-cli-util');
yield cli.action('restarting dynos', co(function* () {
let app = yield heroku.get(`/apps/${context.app}`);
yield heroku.request({method: 'DELETE', path: `/apps/${app.name}/dynos`});
}));
// getting apps... done
// app name: appname
// restarting dynos... done
```
Note: to use `yield` you need to wrap this in a [co](https://github.com/tj/co) block.
## Prompt
Callback style
```js
let cli = require('heroku-cli-util');
cli.prompt('email', {}, function (_, email) {
console.log(`your email is: ${email}`);
});
```
Promise style
```js
let cli = require('heroku-cli-util');
cli.prompt('email', {}).then(function (email) {
console.log(`your email is: ${email}`);
});
```
Generator style (must be wrapped in a [co](https://github.com/tj/co) block)
```js
let cli = require('heroku-cli-util');

@@ -54,0 +32,0 @@ let email = yield cli.prompt('email', {});

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc