diff --git a/.github/workflows/test-all.yml b/.github/workflows/test-all.yml
index 2264ab233fd..3b431328658 100644
--- a/.github/workflows/test-all.yml
+++ b/.github/workflows/test-all.yml
@@ -50,6 +50,8 @@ jobs:
         yarn
     - name: yarn build
       run: yarn build
+    - name: Remove git directory
+      run: rm -rf .git
     - name: Archive build
       if: ${{ !cancelled() }}
       run: |