From 0ed56d382dbece482a3531eac60bc5447254e07b Mon Sep 17 00:00:00 2001 From: Greg Johnston Date: Mon, 2 Jan 2023 13:29:37 -0500 Subject: [PATCH] Add `build-examples` task to `cargo make` CI --- Makefile.toml | 20 +++++++++++++++++++- examples/counter/Makefile.toml | 4 ++++ examples/counter_isomorphic/Makefile.toml | 4 ++++ examples/counters/Makefile.toml | 4 ++++ examples/counters_stable/Makefile.toml | 4 ++++ examples/fetch/Makefile.toml | 4 ++++ examples/hackernews/Makefile.toml | 4 ++++ examples/hackernews_axum/Makefile.toml | 4 ++++ examples/parent_child/Makefile.toml | 4 ++++ examples/todo_app_sqlite/Makefile.toml | 4 ++++ examples/todo_app_sqlite_axum/Makefile.toml | 4 ++++ examples/todomvc/Makefile.toml | 4 ++++ 12 files changed, 63 insertions(+), 1 deletion(-) create mode 100644 examples/counter/Makefile.toml create mode 100644 examples/counter_isomorphic/Makefile.toml create mode 100644 examples/counters/Makefile.toml create mode 100644 examples/counters_stable/Makefile.toml create mode 100644 examples/fetch/Makefile.toml create mode 100644 examples/hackernews/Makefile.toml create mode 100644 examples/hackernews_axum/Makefile.toml create mode 100644 examples/parent_child/Makefile.toml create mode 100644 examples/todo_app_sqlite/Makefile.toml create mode 100644 examples/todo_app_sqlite_axum/Makefile.toml create mode 100644 examples/todomvc/Makefile.toml diff --git a/Makefile.toml b/Makefile.toml index a7969c1ab..4eca1d2c0 100644 --- a/Makefile.toml +++ b/Makefile.toml @@ -8,7 +8,7 @@ default_to_workspace = false [tasks.ci] -dependencies = ["build", "test"] +dependencies = ["build", "build-examples", "test"] [tasks.build] clear = true @@ -19,6 +19,24 @@ command = "cargo" args = ["+nightly", "build-all-features"] install_crate = "cargo-all-features" +[tasks.build-examples] +clear = true +dependencies = [ + { name = "build", path = "examples/counter" }, + { name = "build", path = "examples/counter_isomorphic" }, + { name = "build", path = "examples/counters" }, + { name = "build", path = "examples/counters_stable" }, + { name = "build", path = "examples/fetch" }, + { name = "build", path = "examples/hackernews" }, + { name = "build", path = "examples/hackernews_axum" }, + { name = "build", path = "examples/parent_child" }, + { name = "build", path = "examples/router" }, + { name = "build", path = "examples/tailwind" }, + { name = "build", path = "examples/todo_app_sqlite" }, + { name = "build", path = "examples/todo_app_sqlite_axum" }, + { name = "build", path = "examples/todomvc" }, +] + [tasks.test] clear = true dependencies = ["test-all"] diff --git a/examples/counter/Makefile.toml b/examples/counter/Makefile.toml new file mode 100644 index 000000000..358cd02c5 --- /dev/null +++ b/examples/counter/Makefile.toml @@ -0,0 +1,4 @@ +[tasks.build] +command = "cargo" +args = ["+nightly", "build-all-features"] +install_crate = "cargo-all-features" diff --git a/examples/counter_isomorphic/Makefile.toml b/examples/counter_isomorphic/Makefile.toml new file mode 100644 index 000000000..358cd02c5 --- /dev/null +++ b/examples/counter_isomorphic/Makefile.toml @@ -0,0 +1,4 @@ +[tasks.build] +command = "cargo" +args = ["+nightly", "build-all-features"] +install_crate = "cargo-all-features" diff --git a/examples/counters/Makefile.toml b/examples/counters/Makefile.toml new file mode 100644 index 000000000..358cd02c5 --- /dev/null +++ b/examples/counters/Makefile.toml @@ -0,0 +1,4 @@ +[tasks.build] +command = "cargo" +args = ["+nightly", "build-all-features"] +install_crate = "cargo-all-features" diff --git a/examples/counters_stable/Makefile.toml b/examples/counters_stable/Makefile.toml new file mode 100644 index 000000000..7a09247d1 --- /dev/null +++ b/examples/counters_stable/Makefile.toml @@ -0,0 +1,4 @@ +[tasks.build] +command = "cargo" +args = ["+stable", "build-all-features"] +install_crate = "cargo-all-features" diff --git a/examples/fetch/Makefile.toml b/examples/fetch/Makefile.toml new file mode 100644 index 000000000..358cd02c5 --- /dev/null +++ b/examples/fetch/Makefile.toml @@ -0,0 +1,4 @@ +[tasks.build] +command = "cargo" +args = ["+nightly", "build-all-features"] +install_crate = "cargo-all-features" diff --git a/examples/hackernews/Makefile.toml b/examples/hackernews/Makefile.toml new file mode 100644 index 000000000..358cd02c5 --- /dev/null +++ b/examples/hackernews/Makefile.toml @@ -0,0 +1,4 @@ +[tasks.build] +command = "cargo" +args = ["+nightly", "build-all-features"] +install_crate = "cargo-all-features" diff --git a/examples/hackernews_axum/Makefile.toml b/examples/hackernews_axum/Makefile.toml new file mode 100644 index 000000000..358cd02c5 --- /dev/null +++ b/examples/hackernews_axum/Makefile.toml @@ -0,0 +1,4 @@ +[tasks.build] +command = "cargo" +args = ["+nightly", "build-all-features"] +install_crate = "cargo-all-features" diff --git a/examples/parent_child/Makefile.toml b/examples/parent_child/Makefile.toml new file mode 100644 index 000000000..358cd02c5 --- /dev/null +++ b/examples/parent_child/Makefile.toml @@ -0,0 +1,4 @@ +[tasks.build] +command = "cargo" +args = ["+nightly", "build-all-features"] +install_crate = "cargo-all-features" diff --git a/examples/todo_app_sqlite/Makefile.toml b/examples/todo_app_sqlite/Makefile.toml new file mode 100644 index 000000000..358cd02c5 --- /dev/null +++ b/examples/todo_app_sqlite/Makefile.toml @@ -0,0 +1,4 @@ +[tasks.build] +command = "cargo" +args = ["+nightly", "build-all-features"] +install_crate = "cargo-all-features" diff --git a/examples/todo_app_sqlite_axum/Makefile.toml b/examples/todo_app_sqlite_axum/Makefile.toml new file mode 100644 index 000000000..358cd02c5 --- /dev/null +++ b/examples/todo_app_sqlite_axum/Makefile.toml @@ -0,0 +1,4 @@ +[tasks.build] +command = "cargo" +args = ["+nightly", "build-all-features"] +install_crate = "cargo-all-features" diff --git a/examples/todomvc/Makefile.toml b/examples/todomvc/Makefile.toml new file mode 100644 index 000000000..358cd02c5 --- /dev/null +++ b/examples/todomvc/Makefile.toml @@ -0,0 +1,4 @@ +[tasks.build] +command = "cargo" +args = ["+nightly", "build-all-features"] +install_crate = "cargo-all-features"