@keystrokehq/cli 0.0.122 → 0.0.123

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.mjs CHANGED
@@ -9462,9 +9462,14 @@ const IGNORED_DIRS = new Set([
9462
9462
  ".cache",
9463
9463
  "tmp"
9464
9464
  ]);
9465
+ const IGNORED_ENV_FILE = /\.env/;
9466
+ const IGNORED_LOG_FILE = /\.log$/;
9465
9467
  const MAX_FILE_BYTES = 256 * 1024;
9466
9468
  const MAX_TOTAL_BYTES = 8 * 1024 * 1024;
9467
9469
  const MAX_FILES = 2e3;
9470
+ function isIgnoredFile(name) {
9471
+ return IGNORED_ENV_FILE.test(name) || IGNORED_LOG_FILE.test(name);
9472
+ }
9468
9473
  function toPosix(path) {
9469
9474
  return path.split(sep).join("/");
9470
9475
  }
@@ -9483,7 +9488,7 @@ function walkFiles(root, dir, out, totals) {
9483
9488
  walkFiles(root, absolute, out, totals);
9484
9489
  continue;
9485
9490
  }
9486
- if (!stats.isFile() || stats.size > MAX_FILE_BYTES) continue;
9491
+ if (!stats.isFile() || stats.size > MAX_FILE_BYTES || isIgnoredFile(name)) continue;
9487
9492
  const buffer = readFileSync(absolute);
9488
9493
  if (isProbablyBinary(buffer)) continue;
9489
9494
  totals.bytes += buffer.byteLength;