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:
10
2022/common/src/cli.rs
Normal file
10
2022/common/src/cli.rs
Normal file
@@ -0,0 +1,10 @@
|
||||
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,
|
||||
}
|
||||
@@ -2,6 +2,8 @@ use std::fs::File;
|
||||
use std::io::{Read, Write};
|
||||
use std::path::Path;
|
||||
use tracing::{debug, info};
|
||||
|
||||
pub mod cli;
|
||||
|
||||
pub fn create_file(path: &Path, content: String) {
|
||||
info!("Creating file");
|
||||
|
||||
Reference in New Issue
Block a user