greeting and readme: lib.rs -> main.rs

This commit is contained in:
DieMyst 2020-07-18 15:44:02 +03:00
parent f8a160901b
commit eb45acd95b
3 changed files with 8 additions and 6 deletions

View File

@ -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

View File

@ -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" }

View File

@ -16,6 +16,10 @@
use fluence::fce;
pub fn main() {
}
#[fce]
pub fn greeting(name: String) -> String {
format!("Hi, {}", name)