ddk-node 1.0.0

DDK node to facilitate DLC contracts.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
fn main() -> Result<(), Box<dyn std::error::Error>> {
    let dir = std::path::PathBuf::from("./src/proto");

    let protos = ["ddkrpc.proto"];

    let proto_paths: Vec<_> = protos.iter().map(|proto| dir.join(proto)).collect();

    tonic_build::configure()
        .build_client(true)
        .build_server(true)
        .out_dir("./src")
        .type_attribute(".", "#[derive(serde::Serialize, serde::Deserialize)]")
        .compile(&proto_paths, &[dir])?;

    Ok(())
}