Skip to content

Commit 5dacae0

Browse files
committedJul 15, 2024
fix: cargo-make on nix develop shell
1 parent 829b845 commit 5dacae0

File tree

1 file changed

+7
-4
lines changed

1 file changed

+7
-4
lines changed
 

‎Makefile.toml

+7-4
Original file line numberDiff line numberDiff line change
@@ -46,9 +46,15 @@ args = [
4646
]
4747

4848
[tasks.prebuild]
49+
condition = { env_not_set = ["IN_NIX_SHELL"] }
4950
command = "npx"
5051
args = ["tailwindcss", "-i", "./input.css", "-o", "./style/output.css"]
5152

53+
[tasks.prebuild-nixdev]
54+
condition = { env_set = ["IN_NIX_SHELL"] }
55+
command = "tailwindcss"
56+
args = ["-i", "./input.css", "-o", "./style/output.css"]
57+
5258
[tasks.build]
5359
dependencies = ["get-sitemap", "prebuild"]
5460
install_crate = { crate_name = "cargo-leptos", binary = "cargo", test_arg = [
@@ -58,11 +64,8 @@ install_crate = { crate_name = "cargo-leptos", binary = "cargo", test_arg = [
5864
command = "cargo"
5965
args = ["leptos", "serve", "-r"]
6066

61-
[tasks.build-style]
62-
script.pre = "npx tailwind -i input.css -o style/output.css"
63-
6467
[tasks.serve]
65-
dependencies = ["prebuild"]
68+
dependencies = ["prebuild", "prebuild-nixdev"]
6669
install_crate = { crate_name = "cargo-leptos", binary = "cargo", test_arg = [
6770
"leptos",
6871
"--version",

0 commit comments

Comments
 (0)
Please sign in to comment.