thanix 1.0.0

A yaml-to-rust code generator for generating Rust code from yaml config files e.g. as found in openAPI.
1
2
3
4
5
6
7
8
9
10
11
12
13
use regex::Regex;

pub struct ThanixClient {
    pub client: reqwest::blocking::Client,
    pub base_url: String,
    pub authentication_token: String,
}

pub fn remove_square_braces(s: &str) -> String {
    let re = Regex::new(r"\[\d+\]").unwrap();

    re.replace_all(s, "").to_string()
}