Skip to content

Commit df6c340

Browse files
feat: use edgee-component toml to build (#3)
* feat: use edgee-component toml to build * feat: update wit version * feat(): harmonize component output path * feat(): update toml for new format
1 parent 8790efc commit df6c340

File tree

3 files changed

+30
-1
lines changed

3 files changed

+30
-1
lines changed

Makefile

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
.PHONY: all
2+
MAKEFLAGS += --silent
3+
4+
all: help
5+
6+
help:
7+
@grep -E '^[a-zA-Z1-9\._-]+:.*?## .*$$' $(MAKEFILE_LIST) \
8+
| sort \
9+
| sed -e "s/^Makefile://" -e "s///" \
10+
| awk 'BEGIN { FS = ":.*?## " }; { printf "\033[36m%-30s\033[0m %s\n", $$1, $$2 }'
11+
12+
build:
13+
edgee components build

README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ This is an example of a C# Edgee Component.
1515

1616
## Setup
1717
Requirements:
18+
- [edgee-cli] (https://github.com/edgee-cloud/edgee)
1819
- dotnet SDK 9.0
1920
- Modify the csproj file to match your OS:
2021
- On Linux
@@ -25,5 +26,5 @@ Requirements:
2526
## Building
2627

2728
```shell
28-
$ dotnet build
29+
$ make build
2930
```

edgee-component.toml

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
manifest_version = 1
2+
3+
[package]
4+
name = "example-cs-component"
5+
version = "1.0.0"
6+
category = "data-collection"
7+
subcategory = "analytics"
8+
description = "Example CSharp component for data collection"
9+
documentation = "https://github.com/edgee-cloud/example-cs-component"
10+
repository = "https://github.com/edgee-cloud/example-cs-component"
11+
wit-world-version = "0.4.0"
12+
13+
[package.build]
14+
command = "dotnet build && mv ./bin/Debug/net9.0/wasi-wasm/publish/example-cs-component.wasm ./dc-component.wasm"
15+
output_path = "./dc-component.wasm"

0 commit comments

Comments
 (0)