diff --git a/lib/ci.js b/lib/ci.js
index a0728f8a46467..a72e1c0cffba6 100644
--- a/lib/ci.js
+++ b/lib/ci.js
@@ -31,7 +31,7 @@ const ci = async () => {
         'later to generate a package-lock.json file, then try again.'
       throw new Error(msg)
     }),
-    rimraf(`${where}/node_modules/`),
+    rimraf(`${where}/node_modules/*`, { glob: { dot: true, nosort: true, silent: true } }),
   ])
   // npm ci should never modify the lockfile or package.json
   await arb.reify({ save: false })