This commit is contained in:
Daniel Edrisian
2025-10-14 14:49:24 -07:00
parent 6aa4d416b1
commit 1f7eebf998
2 changed files with 4 additions and 0 deletions
+2
View File
@@ -234,6 +234,7 @@ fn format_exit_messages(exit_info: AppExitInfo, color_enabled: bool) -> Vec<Stri
lines
}
/// Handle the app exit and print the results. Optionally run the update action.
fn handle_app_exit(exit_info: AppExitInfo) -> anyhow::Result<()> {
let update_action = exit_info.update_action;
let color_enabled = supports_color::on(Stream::Stdout).is_some();
@@ -246,6 +247,7 @@ fn handle_app_exit(exit_info: AppExitInfo) -> anyhow::Result<()> {
Ok(())
}
/// Run the update action and print the result.
fn run_update_action(action: UpdateAction) -> anyhow::Result<()> {
println!();
let (cmd, args) = action.command_args();
+2
View File
@@ -489,6 +489,8 @@ async fn run_ratatui_app(
app_result
}
/// Get the update action from the environment.
/// Returns `None` if not managed by npm, bun, or brew.
#[cfg(not(debug_assertions))]
pub(crate) fn get_update_action() -> Option<UpdateAction> {
let exe = std::env::current_exe().unwrap_or_default();