built
provides a crate with information from the time it was built.
Documentation for latest release here, for master here.
built
is used as a build-time dependency to collect various information
about the build environment, serialize it into Rust-code and compile
it into the final crate. The information collected by built
include:
- Various metadata like version, authors, homepage etc. as set by
Cargo.toml
- The tag or commit id if the crate was being compiled from within a git repo.
- The values of various
cfg!
, liketarget_os
andtarget_arch
. - The features the crate was compiled with.
- The various dependencies, dependencies of dependencies and their versions cargo ultimately chose to compile.
- The presence of a CI-platform like
Travis CI
andAppVeyor
. - The used compiler and it's version; the used documentation generator and it's version.
info!;
trace!;
This is version 0.1.0 (git 62eb1e2), built for x86_64-apple-darwin
by rustc 1.16.0-nightly (bf6d7b665 2017-01-15).
I was built with profile "debug", features "DEFAULT, ERR_PRINTLN"
on Thu, 16 Feb 2017 19:00:08 GMT using android_glue 0.2.1,
ansi_term 0.9.0, bitflags 0.3.3, bitflags 0.4.0, bitflags 0.6.0,
bitflags 0.7.0, block 0.1.6, built 0.1.0, byteorder 0.5.3,
bytes 0.3.0, cfg-if 0.1.0, cgl 0.1.5, cgmath 0.7.0, ...
extern crate built;
extern crate time;
extern crate semver;
if
&& .num_days > 180
if CI_PLATFORM.is_some
let deps = DEPENDENCIES;
if parse_versions
.any