upleb.uk

Public git repos — served from a NIP-34 GRASP relay at git.upleb.uk

summaryrefslogtreecommitdiff
path: root/src/sub_commands
diff options
context:
space:
mode:
authorDanConwayDev <DanConwayDev@protonmail.com>2024-02-14 16:44:56 +0000
committerDanConwayDev <DanConwayDev@protonmail.com>2024-02-14 16:44:56 +0000
commit115eca3d69310a58e8357fe091183d0a8e723967 (patch)
tree51860d62bdcde1d466d99134a41b767ac24eff52 /src/sub_commands
parenta1d67c50c8ebc5395b069e30b60d66e0c7de5a5a (diff)
feat: find repo event by nevent or naddr
if repo event cannot be found using unique commit the user can find it via a nevent or naddr also handle no PRs found
Diffstat (limited to 'src/sub_commands')
-rw-r--r--src/sub_commands/list.rs5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/sub_commands/list.rs b/src/sub_commands/list.rs
index 49cbf6d..47a8fdc 100644
--- a/src/sub_commands/list.rs
+++ b/src/sub_commands/list.rs
@@ -51,6 +51,11 @@ pub async fn launch(_cli_args: &Cli, _args: &SubCommandArgs) -> Result<()> {
51 let pr_events: Vec<nostr::Event> = 51 let pr_events: Vec<nostr::Event> =
52 find_pr_events(&client, &repo_ref, &root_commit.to_string()).await?; 52 find_pr_events(&client, &repo_ref, &root_commit.to_string()).await?;
53 53
54 if pr_events.is_empty() {
55 println!("no PRs found... create one? try `ngit send`");
56 return Ok(());
57 }
58
54 let selected_index = Interactor::default().choice( 59 let selected_index = Interactor::default().choice(
55 PromptChoiceParms::default() 60 PromptChoiceParms::default()
56 .with_prompt("All PRs") 61 .with_prompt("All PRs")