Rocket/examples/hello_world/src/main.rs

16 lines
243 B
Rust
Raw Normal View History

#![feature(plugin, decl_macro)]
2016-09-09 03:38:58 +00:00
#![plugin(rocket_codegen)]
extern crate rocket;
#[cfg(test)] mod tests;
#[get("/")]
2016-09-23 04:29:03 +00:00
fn hello() -> &'static str {
"Hello, world!"
}
fn main() {
rocket::ignite().mount("/", routes![hello]).launch();
}