From e926df21acd31d88908411e8b9dc47b88e995dcc Mon Sep 17 00:00:00 2001 From: Thomas Forgione Date: Tue, 19 Mar 2019 18:05:22 +0100 Subject: [PATCH] If sccache installed, use it --- zsh/path.zsh | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/zsh/path.zsh b/zsh/path.zsh index da52844..3590ccd 100644 --- a/zsh/path.zsh +++ b/zsh/path.zsh @@ -10,6 +10,12 @@ fi # Rust path if [ -d $HOME/.cargo ]; then export PATH=$HOME/.cargo/bin:$PATH + # Use sccache if available + command -v sccache > /dev/null 2>&1 + + if [ $? -eq 0 ]; then + export RUSTC_WRAPPER=sccache + fi fi # Node path