24 lines
462 B
Rust
24 lines
462 B
Rust
use serde::Deserialize;
|
|
use std::path::PathBuf;
|
|
|
|
#[derive(Deserialize)]
|
|
#[serde(rename_all = "PascalCase")]
|
|
pub struct Config {
|
|
pub locations: Locations,
|
|
pub downloads: Downloads,
|
|
}
|
|
|
|
#[derive(Deserialize)]
|
|
#[serde(rename_all = "camelCase")]
|
|
pub struct Locations {
|
|
pub src: PathBuf,
|
|
pub temp_dir: PathBuf,
|
|
}
|
|
|
|
#[derive(Deserialize)]
|
|
#[serde(rename_all = "camelCase")]
|
|
pub struct Downloads {
|
|
pub max_threads: usize,
|
|
pub http_timeout: u32,
|
|
}
|