refactor: clippy

- remove unused imports
This commit is contained in:
Wataru Otsubo 2024-07-24 12:38:56 +09:00
parent bca7c3430d
commit 73a169c68f
2 changed files with 9 additions and 12 deletions

View file

@ -1,19 +1,17 @@
use core::{panic, str};
use core::str;
use std::{
collections::BTreeMap,
fmt::Display,
fs::File,
io::{BufRead, BufReader},
io::BufReader,
path::{self, PathBuf},
str::FromStr,
};
use anyhow::{anyhow, Context, Result};
use chrono::{DateTime, Local, Utc};
use chrono::{DateTime, Utc};
use clap::{Parser, Subcommand};
use log::{debug, error, info, trace, warn};
use log::{debug, trace, warn};
use masterlog::MasterLogResult;
use regex::Regex;
use semver::Version;
use serde::{Deserialize, Serialize};
use serde_with::{serde_as, DisplayFromStr};
@ -87,7 +85,7 @@ impl FromStr for PositionLayer {
/// Where PS Board is placed while QAQC.
/// TODO: name
#[derive(Debug, PartialEq, Eq, Hash, Clone, PartialOrd, Ord)]
struct Position {
pub struct Position {
major: PositionLayer,
minor: u8,
patch: u8,
@ -130,7 +128,7 @@ impl FromStr for Position {
/// PSB ID printed on the tape on the board.
#[derive(Debug, PartialEq, Clone)]
struct PsbId {
pub struct PsbId {
id: u32,
}
@ -302,10 +300,9 @@ fn main() -> Result<()> {
mod test {
use std::str::FromStr;
use chrono::{DateTime, Utc};
use semver::Version;
use chrono::DateTime;
use crate::{Position, PositionLayer, PsbId};
use crate::{Position, PositionLayer};
#[test]
fn positionlayer_ordering() {

View file

@ -2,7 +2,7 @@ use std::{collections::BTreeMap, io::BufRead, str::FromStr};
use anyhow::{anyhow, Context, Result};
use chrono::{DateTime, Utc};
use log::{debug, error, info, trace};
use log::{debug, info, trace};
use regex::Regex;
use semver::Version;