ctc

Crates.ioctc
lib.rsctc
version0.2.2
sourcesrc
created_at2021-12-09 19:58:37.655153
updated_at2022-01-21 12:26:12.982811
descriptionload config files on compile time.
homepagehttps://github.com/sahandevs/ctc
repository
max_upload_size
id495336
size5,575
Sahand Akbarzadeh (sahandevs)

documentation

README

CTC - Compile-Time-Config

Crates.io

load config files on compile time.

Usage

  • 1: add dependencies
[dependencies]
ctc = "0.2"
  • 2: import config files like this:
ctc::import_conf!("Cargo.toml", cargo);

fn main() {
    println!("package.name: {}", cargo::package::name);
    println!("package.version: {}", cargo::package::version);
    println!("package.edition: {}", cargo::package::edition);
}

See the example project.

Commit count: 0

cargo fmt