alpaca-sdk 0.1.0

Unofficial Rust SDK for the Alpaca trading, market data, and broker APIs
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
//! Captures the compiling `rustc` version so the runtime `User-Agent` can report
//! it, mirroring alpaca-py's `APCA-PY/<sdk> Python/<runtime>` format.

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

    let version = rustc_version::version()
        .map(|v| v.to_string())
        .unwrap_or_else(|_| "unknown".to_owned());
    println!("cargo::rustc-env=ALPACA_RUSTC_VERSION={version}");
}