Added solution for AoC 2022/3, in python and in rust
Signed-off-by: TuDatTr <tuan-dat.tran@tudattr.dev>
This commit is contained in:
1
2022/day-1_calorie_counting/Cargo.lock
generated
1
2022/day-1_calorie_counting/Cargo.lock
generated
@@ -61,6 +61,7 @@ dependencies = [
|
||||
name = "common"
|
||||
version = "0.1.0"
|
||||
dependencies = [
|
||||
"clap",
|
||||
"tracing",
|
||||
]
|
||||
|
||||
|
||||
@@ -17,7 +17,7 @@ name = "calorie_counting"
|
||||
path = "src/bin.rs"
|
||||
|
||||
[dependencies]
|
||||
clap = {version = "4.0.22", features = ["derive"]}
|
||||
tracing = "0.1"
|
||||
tracing-subscriber = {version = "0.3.16", features = ["env-filter"]}
|
||||
common = {path = "../common/"}
|
||||
common = {path = "../common/"}
|
||||
clap = {version = "4.0.22", features = ["derive"]}
|
||||
@@ -1,10 +1,9 @@
|
||||
use common::cli::Cli;
|
||||
|
||||
use calorie_counting_lib::{task_1a, task_1b};
|
||||
use clap::Parser;
|
||||
use tracing::{info, debug};
|
||||
|
||||
mod cli;
|
||||
use crate::cli::Cli;
|
||||
|
||||
pub fn main() {
|
||||
tracing_subscriber::fmt::init();
|
||||
debug!("Running with DEBUG logging");
|
||||
|
||||
@@ -1,10 +0,0 @@
|
||||
use clap::Parser;
|
||||
use std::path::PathBuf;
|
||||
|
||||
#[derive(Parser, Debug)]
|
||||
#[command(author, version, about=None, long_about = None)]
|
||||
pub struct Cli {
|
||||
/// Path to the input file.
|
||||
#[arg(short, long)]
|
||||
pub input: PathBuf,
|
||||
}
|
||||
Reference in New Issue
Block a user