Skip to content

Commit

Permalink
fix(cli): Fix output of "app info" command
Browse files Browse the repository at this point in the history
  • Loading branch information
theduke committed Feb 21, 2024
1 parent 76fbab3 commit 8070738
Showing 1 changed file with 4 additions and 7 deletions.
11 changes: 4 additions & 7 deletions lib/cli/src/commands/app/info.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
use super::util::AppIdentOpts;
use crate::{
commands::{app::get::CmdAppGet, AsyncCliCommand},
commands::AsyncCliCommand,
opts::{ApiOpts, ItemFormatOpts},
};

Expand All @@ -25,19 +25,16 @@ impl AsyncCliCommand for CmdAppInfo {
type Output = ();

async fn run_async(self) -> Result<(), anyhow::Error> {
let cmd_app_get = CmdAppGet {
api: self.api,
fmt: self.fmt,
ident: self.ident,
};
let app = cmd_app_get.run_async().await?;
let client = self.api.client()?;
let (_ident, app) = self.ident.load_app(&client).await?;

let app_url = app.url;
let versioned_url = app.active_version.url;
let dashboard_url = app.admin_url;

eprintln!(" App Info ");
eprintln!("> App Name: {}", app.name);
eprintln!("> Namespace: {}", app.owner.global_name);
eprintln!("> App URL: {}", app_url);
eprintln!("> Versioned URL: {}", versioned_url);
eprintln!("> Admin dashboard: {}", dashboard_url);
Expand Down

0 comments on commit 8070738

Please sign in to comment.