This commit is contained in:
Dandaedre 2024-06-21 16:47:08 +02:00
parent 2cc32f41ce
commit 9ee72e03b3
2 changed files with 26 additions and 27 deletions

View File

@ -7,8 +7,8 @@ edition = "2021"
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
[dependencies]
anyhow = "1.0.82"
clap = { version = "4.5.4", features = ["derive"] }
anyhow = "1.0.86"
clap = { version = "4.5.7", features = ["derive"] }
csv = "1.3.0"
debug_print = "1.0.0"
dynfmt = { version = "0.1.5", features = ["curly"] }
@ -16,11 +16,11 @@ enum_dispatch = "0.3.13"
futures = "0.3.30"
glob = "0.3.1"
phf = { version = "0.11.2", features = ["macros"] }
regex = "1.10.4"
regex = "1.10.5"
regex_static = "0.1.1"
serde = { version = "1.0.198", features = ["derive"] }
serde = { version = "1.0.203", features = ["derive"] }
tokio = { version = "1.38.0", features = ["full"] }
toml = "0.8.12"
toml = "0.8.14"
[profile.dev]
debug = 0

View File

@ -124,25 +124,24 @@ async fn launch_subprocess(args: &MakeConfig) -> Result<Status> {
Ok(status)
}
// /// The line encountered
// enum LineType {
// /// The tex building mode
// Mode,
// Info,
// BoxFullness,
// /// Unknown type
// Unknown(String),
// }
// /// Check each line and changes the status and/or display according warnings
// fn checkline(s: &str, status: &mut Status, context: &mut Vec<String>) -> Result<()> {
// // Match the line to guess what is happening
// // match s {
// // s if s.starts_with("entering_extended_mode") => LineType::Mode,
// // _ => LineType::Unknown(s.to_string()),
// // }
// // status.warnings += 1;
// // if status.warnings % 3 == 0 {
// // println!("{}", s);
// // }
// Ok(())
// }
/// The line encountered
#[derive(Debug)]
enum LineType {
/// The tex building mode
Mode,
Info,
BoxFullness,
/// Unknown type
Unknown(String),
}
/// Check each line and changes the status and/or display according warnings
fn checkline(s: &str, status: &mut Status, context: &mut Vec<String>) -> Result<()> {
// Match the line to guess what is happening
let line = match s {
s if s.starts_with("entering_extended_mode") => LineType::Mode,
_ => LineType::Unknown(s.to_string()),
};
// status.warnings += 1;
println!("{:?}", line);
Ok(())
}