nomy-data-models 0.35.9

Data model definitions for Nomy wallet analysis data processing
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
use std::env;
use std::process::Command;

fn main() {
    println!("cargo:rerun-if-changed=Cargo.toml");

    // Print the current version from Cargo.toml
    let version = env::var("CARGO_PKG_VERSION").unwrap();
    println!("cargo:rustc-env=CARGO_PKG_VERSION={}", version);

    // Optional: Print git commit hash
    if let Ok(output) = Command::new("git").args(&["rev-parse", "HEAD"]).output() {
        if output.status.success() {
            let git_hash = String::from_utf8_lossy(&output.stdout);
            println!("cargo:rustc-env=GIT_HASH={}", git_hash.trim());
        }
    }
}