diff options
| author | DanConwayDev <DanConwayDev@protonmail.com> | 2026-02-16 12:53:13 +0000 |
|---|---|---|
| committer | DanConwayDev <DanConwayDev@protonmail.com> | 2026-02-16 12:53:13 +0000 |
| commit | a2d4df6e759070fe88a311d9a03836cb3a405012 (patch) | |
| tree | 8c39b6e6824ace4035123c47d4c1b88a4d814305 | |
| parent | 1d08d2e77dec6dc2c5a8df8776b74f4ba5405e8d (diff) | |
fix: report wording consistancy in publishing
always report publishing and finish with published
| -rw-r--r-- | src/bin/git_remote_nostr/push.rs | 1 | ||||
| -rw-r--r-- | src/lib/client.rs | 10 |
2 files changed, 6 insertions, 5 deletions
diff --git a/src/bin/git_remote_nostr/push.rs b/src/bin/git_remote_nostr/push.rs index 5cbec7f..c2f4ddd 100644 --- a/src/bin/git_remote_nostr/push.rs +++ b/src/bin/git_remote_nostr/push.rs | |||
| @@ -285,7 +285,6 @@ async fn create_and_publish_events_and_proposals( | |||
| 285 | // TODO check whether tip of each branch pushed is on at least one git server | 285 | // TODO check whether tip of each branch pushed is on at least one git server |
| 286 | // before broadcasting the nostr state | 286 | // before broadcasting the nostr state |
| 287 | if !events.is_empty() { | 287 | if !events.is_empty() { |
| 288 | term.write_line("broadcast to nostr relays:")?; | ||
| 289 | send_events( | 288 | send_events( |
| 290 | client, | 289 | client, |
| 291 | Some(git_repo.get_path()?), | 290 | Some(git_repo.get_path()?), |
diff --git a/src/lib/client.rs b/src/lib/client.rs index 6f817d5..12df19e 100644 --- a/src/lib/client.rs +++ b/src/lib/client.rs | |||
| @@ -2485,12 +2485,13 @@ pub async fn send_events( | |||
| 2485 | 2485 | ||
| 2486 | // Pre-add a heading bar at position 0 so it has a reserved slot | 2486 | // Pre-add a heading bar at position 0 so it has a reserved slot |
| 2487 | // before any relay bars are added. | 2487 | // before any relay bars are added. |
| 2488 | let heading_bar = if use_concise { | 2488 | let heading_bar = { |
| 2489 | let bar = | 2489 | let bar = |
| 2490 | m.add(ProgressBar::new(0).with_style(ProgressStyle::with_template("{msg}").unwrap())); | 2490 | m.add(ProgressBar::new(0).with_style(ProgressStyle::with_template("{msg}").unwrap())); |
| 2491 | // if !use_concise { | ||
| 2492 | bar.set_message("Publishing to nostr relays..."); | ||
| 2493 | // } | ||
| 2491 | Some(bar) | 2494 | Some(bar) |
| 2492 | } else { | ||
| 2493 | None | ||
| 2494 | }; | 2495 | }; |
| 2495 | 2496 | ||
| 2496 | let reveal_state: Option<Arc<BarRevealState>> = if use_concise { | 2497 | let reveal_state: Option<Arc<BarRevealState>> = if use_concise { |
| @@ -2645,7 +2646,8 @@ pub async fn send_events( | |||
| 2645 | handle.abort(); | 2646 | handle.abort(); |
| 2646 | } | 2647 | } |
| 2647 | if let Some((_, spinner)) = &spinner_multi { | 2648 | if let Some((_, spinner)) = &spinner_multi { |
| 2648 | spinner.finish_and_clear(); | 2649 | spinner.set_style(ProgressStyle::with_template("{msg}").unwrap()); |
| 2650 | spinner.finish_with_message("Published to nostr relays"); | ||
| 2649 | } | 2651 | } |
| 2650 | 2652 | ||
| 2651 | Ok(()) | 2653 | Ok(()) |