refactor(build): reformat code and add tonic health dependency
- Reformatted build script with proper indentation and line breaks - Added tonic-health dependency to Cargo.toml and updated lock file - Improved error handling in disk cache with concurrent deletion checks - Refactored conditional chains using && and let expressions - Reformatted struct initialization and function parameter lists - Added proper spacing and alignment in language stats processing - Improved assertion formatting in test cases - Reorganized import statements and code layout in multiple files - Updated metrics functions with better parameter handling and formatting
This commit is contained in:
+1
-1
@@ -69,7 +69,7 @@ impl GitBare {
|
||||
// Sort direction
|
||||
let sort_prefix = match SortDirection::try_from(request.sort_direction) {
|
||||
Ok(SortDirection::Asc) => "",
|
||||
Ok(SortDirection::Desc) | _ => "-",
|
||||
_ => "-",
|
||||
};
|
||||
args.push(format!("--sort={sort_prefix}refname"));
|
||||
|
||||
|
||||
+7
-6
@@ -53,12 +53,13 @@ impl GitBare {
|
||||
})?;
|
||||
}
|
||||
drop(child.stdin.take());
|
||||
let output = child.wait_with_output().map_err(|e| {
|
||||
crate::error::GitError::CommandFailed {
|
||||
status_code: None,
|
||||
stderr: e.to_string(),
|
||||
}
|
||||
})?;
|
||||
let output =
|
||||
child
|
||||
.wait_with_output()
|
||||
.map_err(|e| crate::error::GitError::CommandFailed {
|
||||
status_code: None,
|
||||
stderr: e.to_string(),
|
||||
})?;
|
||||
|
||||
let stderr = String::from_utf8_lossy(&output.stderr).into_owned();
|
||||
if !output.status.success() {
|
||||
|
||||
Reference in New Issue
Block a user