Crate re_build_tools

source ·
Expand description

This crate is to be used from build.rs build scripts.

Enums§

  • Where is this build.rs build script running?

Functions§

  • Returns info parsed from an invocation of the cargo metadata command
  • Given a crate name, computes the sha256 hash of its source code (ordered by filename) and returns an hexadecimal string for it.
  • Given a directory path, computes the sha256 hash of the accumulated contents of all of its files (ordered by filename) except those failing a custom filter, and returns an hexadecimal string for it.
  • Given a directory path, computes the sha256 hash of the accumulated contents of all of its files (ordered by filename), and returns an hexadecimal string for it.
  • Given a file path, computes the sha256 hash of its contents and returns an hexadecimal string for it.
  • Given a bunch of strings, computes the sha256 hash of their contents (in the order they were passed in) and returns an hexadecimal string for it.
  • Call from the build.rs file of any crate you want to generate build info for.
  • Read the environment variable and trigger a rebuild whenever the environment variable changes.
  • Get the current git branch name
  • Get the full commit hash
  • Get the first 7 characters of the commit hash
  • Read the environment variable and trigger a rebuild whenever the environment variable changes.
  • Recursively walks the directory at path in filename order.
  • Reads back a versioning hash that was written with write_versioning_hash.
  • Call from build.rs to trigger a rebuild whenever any source file of the given package or any of its dependencies changes, recursively.
  • Call from build.rs to trigger a rebuild whenever the file at path changes.
  • Call from build.rs to trigger a rebuild whenever any of the files identified by the given globbed path change.
  • Call from build.rs to trigger a rebuild whenever the file at path changes, or it doesn’t exist.
  • Change whether or not this library should output cargo build instructions
  • Writes content to a file iff it differs from what’s already there.
  • Writes the given hash at the specified path.