Skip to content

Commit

Permalink
Reorder imports
Browse files Browse the repository at this point in the history
  • Loading branch information
j178 committed Oct 29, 2024
1 parent d69b07a commit 07ca424
Show file tree
Hide file tree
Showing 5 changed files with 19 additions and 15 deletions.
15 changes: 8 additions & 7 deletions src/cli/run.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,6 @@ use std::fmt::Write as _;
use std::io::Write as _;
use std::path::{Path, PathBuf};

use crate::cli::ExitStatus;
use crate::config::Stage;
use crate::git::{get_all_files, get_changed_files, get_diff, get_staged_files};
use crate::hook::{Hook, Project};
use crate::identify::tags_from_path;
use crate::printer::Printer;
use crate::store::Store;
use anyhow::Result;
use futures::stream::FuturesUnordered;
use futures::StreamExt;
Expand All @@ -21,6 +14,14 @@ use tokio::process::Command;
use tracing::{debug, trace};
use unicode_width::UnicodeWidthStr;

use crate::cli::ExitStatus;
use crate::config::Stage;
use crate::git::{get_all_files, get_changed_files, get_diff, get_staged_files};
use crate::hook::{Hook, Project};
use crate::identify::tags_from_path;
use crate::printer::Printer;
use crate::store::Store;

#[allow(clippy::too_many_arguments)]
pub(crate) async fn run(
config: Option<PathBuf>,
Expand Down
8 changes: 4 additions & 4 deletions src/languages/mod.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,3 @@
mod node;
mod python;
mod system;

use std::fmt::{Debug, Display};
use std::process::Output;

Expand All @@ -10,6 +6,10 @@ use anyhow::Result;
use crate::config;
use crate::hook::Hook;

mod node;
mod python;
mod system;

pub const DEFAULT_VERSION: &str = "default";

trait LanguageImpl {
Expand Down
3 changes: 2 additions & 1 deletion src/languages/node.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
use std::process::{ExitStatus, Output};

use crate::config;
use crate::hook::Hook;
use crate::languages::{LanguageImpl, DEFAULT_VERSION};
use std::process::{ExitStatus, Output};

#[derive(Debug, Copy, Clone)]
pub struct Node;
Expand Down
5 changes: 3 additions & 2 deletions src/languages/python.rs
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
use std::path::{Path, PathBuf};
use std::process::Output;

use assert_cmd::output::{OutputError, OutputOkExt};
use tokio::process::Command;

use crate::config;
use crate::hook::Hook;
use crate::languages::LanguageImpl;
use assert_cmd::output::{OutputError, OutputOkExt};
use tokio::process::Command;

#[derive(Debug, Copy, Clone)]
pub struct Python;
Expand Down
3 changes: 2 additions & 1 deletion src/languages/system.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
use std::process::Output;

use crate::config;
use crate::hook::Hook;
use crate::languages::{LanguageImpl, DEFAULT_VERSION};
use std::process::Output;

#[derive(Debug, Copy, Clone)]
pub struct System;
Expand Down

0 comments on commit 07ca424

Please sign in to comment.