File tree 2 files changed +4
-7
lines changed
2 files changed +4
-7
lines changed Original file line number Diff line number Diff line change @@ -3,7 +3,6 @@ import 'source-map-support/register';
3
3
4
4
import colors = require ( 'colors/safe' ) ;
5
5
import fs = require ( 'fs-extra' ) ;
6
- import util = require ( 'util' ) ;
7
6
import yargs = require ( 'yargs' ) ;
8
7
9
8
import { bootstrapEnvironment , destroyStack , SDK } from '../lib' ;
@@ -25,7 +24,6 @@ import { VERSION } from '../lib/version';
25
24
26
25
// tslint:disable-next-line:no-var-requires
27
26
const promptly = require ( 'promptly' ) ;
28
- const confirm = util . promisify ( promptly . confirm ) ;
29
27
30
28
// tslint:disable:no-shadowed-variable max-line-length
31
29
async function parseCommandLineArguments ( ) {
@@ -359,7 +357,7 @@ async function initCommandLine() {
359
357
360
358
if (!force) {
361
359
// tslint:disable-next-line:max-line-length
362
- const confirmed = await confirm(` Are you sure you want to delete : ${colors . blue ( stacks . map ( s => s . name ) . join ( ', ' ) ) } ( y / n ) ?`);
360
+ const confirmed = await promptly. confirm(` Are you sure you want to delete : ${colors . blue ( stacks . map ( s => s . name ) . join ( ', ' ) ) } ( y / n ) ?`);
363
361
if (!confirmed) {
364
362
return;
365
363
}
Original file line number Diff line number Diff line change 1
1
import colors = require( 'colors/safe' ) ;
2
2
import fs = require( 'fs-extra' ) ;
3
- import { format , promisify } from 'util' ;
3
+ import { format } from 'util' ;
4
4
import { AppStacks , ExtendedStackSelection } from "./api/cxapp/stacks" ;
5
5
import { IDeploymentTarget } from './api/deployment-target' ;
6
6
import { printSecurityDiff , printStackDiff , RequireApproval } from './diff' ;
@@ -9,7 +9,6 @@ import { deserializeStructure } from './serialize';
9
9
10
10
// tslint:disable-next-line:no-var-requires
11
11
const promptly = require ( 'promptly' ) ;
12
- const confirm = promisify ( promptly . confirm ) ;
13
12
14
13
export interface CdkToolkitProps {
15
14
/**
@@ -98,7 +97,7 @@ export class CdkToolkit {
98
97
'but terminal (TTY) is not attached so we are unable to get a confirmation from the user' ) ;
99
98
}
100
99
101
- const confirmed = await confirm ( `Do you wish to deploy these changes (y/n)?` ) ;
100
+ const confirmed = await promptly . confirm ( `Do you wish to deploy these changes (y/n)?` ) ;
102
101
if ( ! confirmed ) { throw new Error ( 'Aborted by user' ) ; }
103
102
}
104
103
}
@@ -230,4 +229,4 @@ export interface DeployOptions {
230
229
* Reuse the assets with the given asset IDs
231
230
*/
232
231
reuseAssets ?: string [ ] ;
233
- }
232
+ }
You can’t perform that action at this time.
0 commit comments