macroquest-macros 0.1.7

Internal macros for the MacroQuest ecosystem
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
use std::env;
use std::fs;
use std::path::Path;

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

    let config = macroquest_build_config::BuildConfig::load();

    // Write out the EQVersion string
    let out_dir = env::var_os("OUT_DIR").unwrap();
    let dest_path = Path::new(&out_dir).join("eq_version.txt");
    fs::write(dest_path, config.eq_version()).unwrap();
}