From b8383abb47538dbe33f3e0a14f9ece1a5f3d062e Mon Sep 17 00:00:00 2001 From: Robbert van der Helm Date: Wed, 16 Feb 2022 16:51:36 +0100 Subject: [PATCH] Compile the xtask target in release mode This avoids having to compile serde(-derive) twice when doing a one off-compile. That was the main issue with parsing toml files from the xtask bundler, but with this change that's no longer an issue. --- .cargo/config | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/.cargo/config b/.cargo/config index 35049cbc..b2f50a3e 100644 --- a/.cargo/config +++ b/.cargo/config @@ -1,2 +1,8 @@ [alias] -xtask = "run --package xtask --" +# Building the xtask package in release mode is normally not necessary, but if +# you're going to compile other plugins in release mode then you'd need to +# recompile serde(-derive) because the xtask packages needs serde to parse the +# `bundler.toml` config file. To avoid needing to compile these expensive crates +# twice, we'll default to also running the xtask target in release mode. +xtask = "run --package xtask --release --" +xtask-debug = "run --package xtask --"