mirror of
https://github.com/gitbutlerapp/gitbutler.git
synced 2024-12-26 02:51:57 +03:00
rename mod.rs files to named modules
This commit is contained in:
parent
a4e3623530
commit
e9869013d3
@ -67,6 +67,8 @@ unneeded_field_pattern = "deny"
|
||||
unseparated_literal_suffix = "deny"
|
||||
if_then_some_else_none = "deny"
|
||||
use_debug = "deny"
|
||||
mod_module_files = "deny"
|
||||
self_named_module_files = "allow"
|
||||
# TODO
|
||||
# partial_pub_fields = "deny"
|
||||
# print_stdout = "deny"
|
||||
|
@ -1,6 +1,6 @@
|
||||
use std::path;
|
||||
|
||||
#![allow(unused)]
|
||||
use gblib::git;
|
||||
use std::path;
|
||||
|
||||
pub fn temp_dir() -> std::path::PathBuf {
|
||||
tempfile::tempdir()
|
||||
@ -250,3 +250,12 @@ impl TestProject {
|
||||
submodule.add_finalize().unwrap();
|
||||
}
|
||||
}
|
||||
|
||||
pub mod paths {
|
||||
use super::temp_dir;
|
||||
use gblib::paths::DataDir;
|
||||
|
||||
pub fn data_dir() -> DataDir {
|
||||
DataDir::from(temp_dir())
|
||||
}
|
||||
}
|
||||
|
@ -1,8 +1,8 @@
|
||||
use std::path;
|
||||
mod common;
|
||||
|
||||
use self::common::{paths, TestProject};
|
||||
use gblib::{gb_repository, git, project_repository, projects};
|
||||
|
||||
use crate::{common::TestProject, paths};
|
||||
use std::path;
|
||||
|
||||
mod init {
|
||||
use super::*;
|
@ -1,7 +0,0 @@
|
||||
#![allow(clippy::dbg_macro)]
|
||||
|
||||
mod common;
|
||||
mod gb_repository;
|
||||
mod paths;
|
||||
mod projects;
|
||||
mod virtual_branches;
|
@ -1,7 +0,0 @@
|
||||
use gblib::paths::DataDir;
|
||||
|
||||
use crate::common::temp_dir;
|
||||
|
||||
pub fn data_dir() -> DataDir {
|
||||
DataDir::from(temp_dir())
|
||||
}
|
@ -1,6 +1,7 @@
|
||||
use gblib::projects::Controller;
|
||||
mod common;
|
||||
|
||||
use crate::{common, paths};
|
||||
use self::common::paths;
|
||||
use gblib::projects::Controller;
|
||||
|
||||
pub fn new() -> Controller {
|
||||
let data_dir = paths::data_dir();
|
@ -1,9 +1,13 @@
|
||||
//TODO:
|
||||
#![allow(
|
||||
clippy::redundant_closure_for_method_calls,
|
||||
clippy::rest_pat_in_fully_bound_structs
|
||||
clippy::rest_pat_in_fully_bound_structs,
|
||||
clippy::dbg_macro
|
||||
)]
|
||||
|
||||
mod common;
|
||||
|
||||
use self::common::{paths, TestProject};
|
||||
use std::{fs, path, str::FromStr};
|
||||
|
||||
use gblib::{
|
||||
@ -14,8 +18,6 @@ use gblib::{
|
||||
virtual_branches::{branch, controller::ControllerError, errors, Controller},
|
||||
};
|
||||
|
||||
use crate::{common::TestProject, paths};
|
||||
|
||||
struct Test {
|
||||
repository: TestProject,
|
||||
project_id: ProjectId,
|
Loading…
Reference in New Issue
Block a user