UNPKG

438 BJavaScriptView Raw
1'use strict'
2
3let cli = require('heroku-cli-util')
4let co = require('co')
5
6function * run (context, heroku) {
7 let org = yield heroku.get(`/organizations/${context.org}`)
8 yield cli.open(`https://dashboard.heroku.com/orgs/${org.name}`)
9}
10
11module.exports = {
12 topic: 'orgs',
13 command: 'open',
14 description: 'open the organization interface in a browser window',
15 needsAuth: true,
16 needsOrg: true,
17 run: cli.command(co.wrap(run))
18}