Crates.io | init |
lib.rs | init |
version | 0.2.0 |
source | src |
created_at | 2017-02-14 08:59:09.014179 |
updated_at | 2017-02-15 08:47:45.576539 |
description | Mark a function to run before main. |
homepage | https://github.com/mehcode/init-rs |
repository | https://github.com/mehcode/init-rs/tree/master/init |
max_upload_size | |
id | 8516 |
size | 1,887 |
Mark a function to run before main.
[dependencies]
init = "0.2"
[build-dependencies]
init = "0.2"
src/main.rs
#![feature(proc_macro)]
extern crate init;
use init::init;
#[init]
fn init() {
// [...]
}
build.rs
extern crate init;
fn main() {
init::build();
}
Init is primarily distributed under the terms of both the MIT license and the Apache License (Version 2.0).
See LICENSE-APACHE and LICENSE-MIT for details.