code: function setConfig(config) {
    let oldConfig = getConfig();  // to check if the file exists.
    if (!oldConfig) return false;
    if (typeof config !== 'object' || !config) return false;
    let configData = '';
    try {
      configData = JSON.stringify(config, null, 1);
    } catch (e) {
      console.warn(`thorin-env: failed to serialize configuration`, e);
      return false;
    }
    try {
      fs.writeFileSync(PERSIST_FILE, configData, {encoding: 'utf8'});
    } catch (e) {
      console.warn(`thorin-env: failed to persist new config in .thorin file`);
      console.debug(e);
      return false;
    }
    return true;
  }
docs: /* Manually set the config data in the file. NOTE THIS DOES NOT MERGE, JUST REPLACE.