diff --git a/examples/KV/spin.toml b/examples/KV/spin.toml index 148d43c..b67ce58 100644 --- a/examples/KV/spin.toml +++ b/examples/KV/spin.toml @@ -13,3 +13,4 @@ key_value_stores = ["default"] route = "/..." [component.build] command = "spin py2wasm app -o app.wasm" +watch = ["app.py"] diff --git a/examples/external_lib/spin.toml b/examples/external_lib/spin.toml index bec2f1e..08223ab 100644 --- a/examples/external_lib/spin.toml +++ b/examples/external_lib/spin.toml @@ -12,3 +12,4 @@ source = "app.wasm" route = "/..." [component.build] command = "spin py2wasm app -o app.wasm" +watch = ["app.py", "Pipfile*"] diff --git a/examples/hello_world/spin.toml b/examples/hello_world/spin.toml index 0e54a3b..dd3d874 100644 --- a/examples/hello_world/spin.toml +++ b/examples/hello_world/spin.toml @@ -12,3 +12,4 @@ source = "app.wasm" route = "/..." [component.build] command = "spin py2wasm app -o app.wasm" +watch = ["app.py"] diff --git a/examples/outbound_http/spin.toml b/examples/outbound_http/spin.toml index 154a71c..06c79b6 100644 --- a/examples/outbound_http/spin.toml +++ b/examples/outbound_http/spin.toml @@ -14,3 +14,4 @@ allowed_http_hosts = ["https://some-random-api.ml"] route = "/..." [component.build] command = "spin py2wasm app -o app.wasm" +watch = ["app.py"] diff --git a/examples/outbound_redis/spin.toml b/examples/outbound_redis/spin.toml index fce6622..a56f82b 100644 --- a/examples/outbound_redis/spin.toml +++ b/examples/outbound_redis/spin.toml @@ -13,3 +13,4 @@ source = "app.wasm" route = "/..." [component.build] command = "spin py2wasm app -o app.wasm" +watch = ["app.py"] diff --git a/templates/http-py/content/spin.toml b/templates/http-py/content/spin.toml index cae2f81..260e3ee 100644 --- a/templates/http-py/content/spin.toml +++ b/templates/http-py/content/spin.toml @@ -12,3 +12,4 @@ source = "app.wasm" route = "{{http-path}}" [component.build] command = "spin py2wasm app -o app.wasm" +watch = ["app.py", "Pipfile"] diff --git a/templates/http-py/metadata/snippets/component.txt b/templates/http-py/metadata/snippets/component.txt index e9b4be7..51845d9 100644 --- a/templates/http-py/metadata/snippets/component.txt +++ b/templates/http-py/metadata/snippets/component.txt @@ -6,4 +6,4 @@ route = "{{http-path}}" [component.build] command = "spin py2wasm app -o app.wasm" workdir = "{{ output-path }}" - +watch = ["app.py", "Pipfile"]