diff --git a/src/index.ts b/src/index.ts index 47ebc7c..aa7e692 100644 --- a/src/index.ts +++ b/src/index.ts @@ -590,15 +590,6 @@ async function dockerBuild( 'echo "::endgroup::"' ) } - if (sccache) { - commands.push( - 'echo "::group::Install sccache"', - 'python3 -m pip install "sccache>=0.4.0"', - 'sccache --version', - 'echo "::endgroup::"' - ) - setupSccacheEnv() - } const beforeScript = getBeforeScript() if (beforeScript.length > 0) { @@ -609,6 +600,16 @@ async function dockerBuild( ) } + if (sccache) { + commands.push( + 'echo "::group::Install sccache"', + 'python3 -m pip install "sccache>=0.4.0"', + 'sccache --version', + 'echo "::endgroup::"' + ) + setupSccacheEnv() + } + commands.push(`maturin ${args.join(' ')}`) if (sccache) { commands.push(