From eb45acd95b1cb81479b0fd965dfd5be237696e72 Mon Sep 17 00:00:00 2001 From: DieMyst Date: Sat, 18 Jul 2020 15:44:02 +0300 Subject: [PATCH] greeting and readme: lib.rs -> main.rs --- README.md | 5 ++--- examples/greeting/wasm/Cargo.toml | 5 ++--- examples/greeting/wasm/src/{lib.rs => main.rs} | 4 ++++ 3 files changed, 8 insertions(+), 6 deletions(-) rename examples/greeting/wasm/src/{lib.rs => main.rs} (97%) diff --git a/README.md b/README.md index 4b3c6658..ee651430 100644 --- a/README.md +++ b/README.md @@ -23,10 +23,9 @@ FCE is intended to run various Wasm binaries. At now, it is in the heavily devel - `Config.toml`: ``` -[lib] +[[bin]] name = "wasm_application" -path = "src/lib.rs" -crate-type = ["cdylib"] +path = "src/main.rs" [dependencies] // logger - if you'll use logging diff --git a/examples/greeting/wasm/Cargo.toml b/examples/greeting/wasm/Cargo.toml index bf3c27ce..01d4efc1 100644 --- a/examples/greeting/wasm/Cargo.toml +++ b/examples/greeting/wasm/Cargo.toml @@ -4,10 +4,9 @@ version = "0.1.0" authors = ["Fluence Labs"] edition = "2018" -[lib] +[[bin]] name = "greeting" -path = "src/lib.rs" -crate-type = ["cdylib"] +path = "src/main.rs" [dependencies] fluence = { git = "https://github.com/fluencelabs/rust-sdk" } diff --git a/examples/greeting/wasm/src/lib.rs b/examples/greeting/wasm/src/main.rs similarity index 97% rename from examples/greeting/wasm/src/lib.rs rename to examples/greeting/wasm/src/main.rs index 736b8065..dcb0c1fa 100644 --- a/examples/greeting/wasm/src/lib.rs +++ b/examples/greeting/wasm/src/main.rs @@ -16,6 +16,10 @@ use fluence::fce; +pub fn main() { + +} + #[fce] pub fn greeting(name: String) -> String { format!("Hi, {}", name)