<commit_before>import paths from "../helpers/paths";
import fs from "fs";
import mkdirp from "mkdirp";

require("dotenv").config({ debug: true, path: `${__dirname}/.env` });

console.log(process.env);
console.log(fs.readdirSync(__dirname));
console.log(fs.readFileSync(`${__dirname}/.env`, "utf8"));

// There is an error message freaking users out, and I
// can't figure out how to turn it off. So monkey patching
// so it doesn't show up anymore.
const warn = console.warn;
console.warn = message => {
  if (
    message.indexOf(
      'Pass false into "resolverValidationOptions.requireResolversForResolveType'
    ) > -1
  )
    return;
  warn(message);
};

// Check to see if we are in development mode or not.
if (
  process.argv0.split("/").indexOf("node") === -1 &&
  process.argv0.split("/").indexOf("node.exe") === -1 &&
  process.argv0.split("\\").indexOf("node.exe") === -1
) {
  process.env.NODE_ENV = "production";
} else {
  // Load the Sentry error tracking
  require("../helpers/sentry");
}

let logDir = "./logs";
if (process.env.NODE_ENV === "production") {<commit_msg>fix(Build): Build test. Do not use.<commit_after>import paths from "../helpers/paths";
import fs from "fs";
import mkdirp from "mkdirp";

require("dotenv").config({ debug: true, path: `${__dirname}/../.env` });

console.log(process.env);
console.log(fs.readdirSync(`${__dirname}/..`));
try {
  console.log(fs.readFileSync(`${__dirname}/../.env`, "utf8"));
} catch {
  console.log(`Could not find or load ${__dirname}/../.env`);
}
// There is an error message freaking users out, and I
// can't figure out how to turn it off. So monkey patching
// so it doesn't show up anymore.
const warn = console.warn;
console.warn = message => {
  if (
    message.indexOf(
      'Pass false into "resolverValidationOptions.requireResolversForResolveType'
    ) > -1
  )
    return;
  warn(message);
};

// Check to see if we are in development mode or not.
if (
  process.argv0.split("/").indexOf("node") === -1 &&
  process.argv0.split("/").indexOf("node.exe") === -1 &&
  process.argv0.split("\\").indexOf("node.exe") === -1
) {
  process.env.NODE_ENV = "production";
} else {
  // Load the Sentry error tracking
  require("../helpers/sentry");
}

let logDir = "./logs";
if (process.env.NODE_ENV === "production") {
{'fraction_non_alphanumeric': 0.1888355865678151, 'fraction_numerical': 0.006977758395115569, 'mean_word_length': 3.6816326530612247, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4200360', 'n_tokens_mistral': 757, 'n_tokens_neox': 753, 'n_words': 203}