Skip to content

Commit ad2bf12

Browse files
committed
refactor: apply clippy
1 parent 8d57249 commit ad2bf12

1 file changed

Lines changed: 8 additions & 8 deletions

File tree

src/main.rs

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ use octocrab::Octocrab;
66
use serde::{Deserialize, Serialize};
77
use std::fs::{self, File};
88
use std::io::{self, Cursor, IsTerminal};
9-
use std::path::PathBuf;
9+
use std::path::{Path, PathBuf};
1010
use std::process::Command;
1111
use zip::ZipArchive;
1212

@@ -56,9 +56,9 @@ fn icon_failure() -> &'static str {
5656
if supports_emoji() { "❌" } else { "✗" }
5757
}
5858

59-
fn icon_pending() -> &'static str {
60-
if supports_emoji() { "⏳" } else { "~" }
61-
}
59+
// fn icon_pending() -> &'static str {
60+
// if supports_emoji() { "⏳" } else { "~" }
61+
// }
6262

6363
#[tokio::main]
6464
async fn main() -> Result<()> {
@@ -227,7 +227,7 @@ async fn main() -> Result<()> {
227227

228228
fn get_current_branch() -> Result<String> {
229229
let output = Command::new("git")
230-
.args(&["rev-parse", "--abbrev-ref", "HEAD"])
230+
.args(["rev-parse", "--abbrev-ref", "HEAD"])
231231
.output()
232232
.context("Failed to execute git command")?;
233233

@@ -243,7 +243,7 @@ fn get_current_branch() -> Result<String> {
243243

244244
fn get_latest_commit() -> Result<String> {
245245
let output = Command::new("git")
246-
.args(&["rev-parse", "HEAD"])
246+
.args(["rev-parse", "HEAD"])
247247
.output()
248248
.context("Failed to execute git command")?;
249249

@@ -263,7 +263,7 @@ fn get_repo_info() -> Result<(String, String)> {
263263

264264
for remote in remotes {
265265
let output = Command::new("git")
266-
.args(&["remote", "get-url", remote])
266+
.args(["remote", "get-url", remote])
267267
.output()
268268
.context("Failed to execute git command")?;
269269

@@ -313,7 +313,7 @@ async fn download_workflow_logs(
313313
owner: &str,
314314
repo: &str,
315315
run_id: u64,
316-
output_dir: &PathBuf,
316+
output_dir: &Path,
317317
) -> Result<()> {
318318
let bytes = octocrab
319319
.actions()

0 commit comments

Comments
 (0)