From a85b34f21d75788fb7f578ea8867982957ad8aa7 Mon Sep 17 00:00:00 2001 From: Daniel Scherzer Date: Thu, 16 Jul 2026 13:52:32 -0700 Subject: [PATCH] `RepoBuilder`: clean up documentation indentation Don't randomly indent everything other than `use` statements with a space; indent parameters with 4 spaces per level rather than 2. --- src/build.rs | 42 +++++++++++++++++++++--------------------- 1 file changed, 21 insertions(+), 21 deletions(-) diff --git a/src/build.rs b/src/build.rs index c1ef2567a4..51d6713b48 100644 --- a/src/build.rs +++ b/src/build.rs @@ -22,30 +22,30 @@ use crate::{CheckoutNotificationType, DiffFile, FileMode, Remote}; /// use std::env; /// use std::path::Path; /// -/// // Prepare callbacks. -/// let mut callbacks = RemoteCallbacks::new(); -/// callbacks.credentials(|_url, username_from_url, _allowed_types| { -/// Cred::ssh_key( -/// username_from_url.unwrap(), -/// None, -/// Path::new(&format!("{}/.ssh/id_rsa", env::var("HOME").unwrap())), -/// None, -/// ) -/// }); +/// // Prepare callbacks. +/// let mut callbacks = RemoteCallbacks::new(); +/// callbacks.credentials(|_url, username_from_url, _allowed_types| { +/// Cred::ssh_key( +/// username_from_url.unwrap(), +/// None, +/// Path::new(&format!("{}/.ssh/id_rsa", env::var("HOME").unwrap())), +/// None, +/// ) +/// }); /// -/// // Prepare fetch options. -/// let mut fo = git2::FetchOptions::new(); -/// fo.remote_callbacks(callbacks); +/// // Prepare fetch options. +/// let mut fo = git2::FetchOptions::new(); +/// fo.remote_callbacks(callbacks); /// -/// // Prepare builder. -/// let mut builder = git2::build::RepoBuilder::new(); -/// builder.fetch_options(fo); +/// // Prepare builder. +/// let mut builder = git2::build::RepoBuilder::new(); +/// builder.fetch_options(fo); /// -/// // Clone the project. -/// builder.clone( -/// "git@github.com:rust-lang/git2-rs.git", -/// Path::new("/tmp/git2-rs"), -/// ); +/// // Clone the project. +/// builder.clone( +/// "git@github.com:rust-lang/git2-rs.git", +/// Path::new("/tmp/git2-rs"), +/// ); /// ``` pub struct RepoBuilder<'cb> { bare: bool,