2 unstable releases

Uses old Rust 2015

0.2.0 Feb 15, 2017
0.1.0 Feb 14, 2017

#42 in #mark

Download history 10/week @ 2024-02-20 19/week @ 2024-02-27 4/week @ 2024-03-12 8/week @ 2024-03-26 39/week @ 2024-04-02

51 downloads per month
Used in init

MIT/Apache

4KB
57 lines

init

Rust Crates.io Docs.rs

Mark a function to run before main.

Install

[dependencies]
init = "0.2"

[build-dependencies]
init = "0.2"

Usage

src/main.rs

#![feature(proc_macro)]

extern crate init;
use init::init;

#[init]
fn init() {
    // [...]
}

build.rs

extern crate init;

fn main() {
  init::build();
}

License

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.

Dependencies

~1.5MB
~40K SLoC