Hotaru in 1,2,3

1. Installation:

Make sure Rust toolchains (i.e. rustup) are installed.

Next, run cargo install hotaru. The console should show this when it completes:

Finished release profile [optimized] target(s) in xx.xxs
Installing /home/<user>/.cargo/bin/hotaru
Installed package hotaru v0.8.3 (executable hotaru)

Next, add hotaru to PATH for easier access.

For Windows:

setx PATH "%PATH%;C:\User\<username>\.cargo\bin\hotaru

For Linux:

export PATH="/home/<username>/.cargo/bin/:$PATH"

2. Setup:

Create an app:

hotaru new example

Then run it:
cd example
cargo run

3. Development:

Open an IDE of your choice, and start developing!
Start file:

use hotaru::prelude::*;
use hotaru::http::*;

#[tokio::main]
async fn main() {
APP.clone().run().await;
}

LServer!(
APP = Server::new()
.binding("127.0.0.1:3003")
.single_protocol(ProtocolBuilder::new(HTTP::server(HttpSafety::default())))
.build()
);

endpoint!{
APP.url("/"),

/// Hello world function
pub hello_world <HTTP> {
text_response("Hello, world!")
}
}

mod resource;