From d64748b810bf64638a5eb71eac054d91dae0c0f1 Mon Sep 17 00:00:00 2001 From: DanConwayDev Date: Wed, 21 May 2025 12:32:41 +0100 Subject: feat: add support for default relay overrides via git config so they can be overwritten locally and globally --- src/bin/ngit/sub_commands/init.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/bin/ngit/sub_commands/init.rs') diff --git a/src/bin/ngit/sub_commands/init.rs b/src/bin/ngit/sub_commands/init.rs index 3c58a52..ee5f1ab 100644 --- a/src/bin/ngit/sub_commands/init.rs +++ b/src/bin/ngit/sub_commands/init.rs @@ -4,6 +4,7 @@ use anyhow::{Context, Result}; use console::{Style, Term}; use ngit::{ cli_interactor::PromptConfirmParms, + client::Params, git::nostr_url::{NostrUrlDecoded, save_nip05_to_git_config_cache}, }; use nostr::{ @@ -68,7 +69,7 @@ pub async fn launch(cli_args: &Cli, args: &SubCommandArgs) -> Result<()> { // TODO: check for empty repo // TODO: check for existing maintaiers file - let mut client = Client::default(); + let mut client = Client::new(Params::with_git_config_relay_defaults(&Some(&git_repo))); let repo_coordinate = (try_and_get_repo_coordinates_when_remote_unknown(&git_repo).await).ok(); -- cgit v1.2.3