Skip to content

Commit

Permalink
fix(dev-env): vip dev-env info --all should not ask for a slug (#1815)
Browse files Browse the repository at this point in the history
  • Loading branch information
sjinks committed May 9, 2024
1 parent 3845404 commit 205145a
Showing 1 changed file with 11 additions and 4 deletions.
15 changes: 11 additions & 4 deletions src/bin/vip-dev-env-info.js
Original file line number Diff line number Diff line change
Expand Up @@ -37,12 +37,19 @@ command()
.option( 'extended', 'Show extended information about the dev environment' )
.examples( examples )
.argv( process.argv, async ( arg, opt ) => {
const slug = await getEnvironmentName( opt );

let trackingInfo;
let slug;
const lando = await bootstrapLando();
await validateDependencies( lando, slug );

const trackingInfo = opt.all ? { all: true } : getEnvTrackingInfo( slug );
if ( opt.all ) {
trackingInfo = { all: true };
slug = '';
} else {
slug = await getEnvironmentName( opt );
trackingInfo = getEnvTrackingInfo( slug );
}

await validateDependencies( lando, slug );
await trackEvent( 'dev_env_info_command_execute', trackingInfo );

debug( 'Args: ', arg, 'Options: ', opt );
Expand Down

0 comments on commit 205145a

Please sign in to comment.