Added structs for config data
ci/woodpecker/push/workflow Pipeline was successful Details

pull/3/head
Ayrton Chilibeck 2024-01-12 13:21:04 -07:00
parent 76b9f72d41
commit 9f509a929f
Signed by: ayrton
GPG Key ID: BAE24A03DCBF160D
1 changed files with 31 additions and 0 deletions

View File

@ -1 +1,32 @@
use std::{path::PathBuf, collections::HashMap};
use serde_yaml;
#[derive(Default)]
struct Config {
executable_paths: HashMap<String, PathBuf>,
input_path: PathBuf,
output_path: PathBuf,
toolchains: Vec<Toolchain>,
}
#[derive(Default)]
struct Toolchain {
name: String,
steps: Vec<Step>,
}
#[derive(Default)]
struct Step {
name: String,
executable_path: Option<PathBuf>, // if None then we use the current executable path
arguments: Vec<String>, // special string $INPUT corresponds to previous step output
output: String, // the output file name
}
pub fn parse_config(path: PathBuf) {
}