<commit_before>'use babel';

/*
 * Beta configurations looked like
 *
 * {
 *   "themes": {
 *     "example1": {
 *       "syntax": "syntax-theme-name",
 *       "ui": "ui-theme-name",
 *       "config": {
 *          // the config for the UI theme
 *       }
 *     },
 *     ...
 *   }
 * }
 */
function updateFromBetaToV1(schema) {
  let updated = {
    schemaVersion: 1,
    themes: {}
  };

  for (let themeName in schema.themes) {
    let theme = schema.themes[themeName];

    updated.themes[themeName] = {
      syntax: {
        name: theme.syntax
      },
      ui: {
        name: theme.ui,
        config: theme.config
      }
    };
  }

  return updated;
}

function createInitialSchema
export default {

  updateSchema(schema) {
    let version = schema.schemaVersion;

    switch (version) {
      case 0:
        return updateFromBetaToV1(schema);
      default: // The first time this package is run there will be no version so just return the initial schema
        return schema;
    }
  }

};<commit_msg>FUUUUUUUUUU<commit_after>'use babel';

/*
 * Beta configurations looked like
 *
 * {
 *   "themes": {
 *     "example1": {
 *       "syntax": "syntax-theme-name",
 *       "ui": "ui-theme-name",
 *       "config": {
 *          // the config for the UI theme
 *       }
 *     },
 *     ...
 *   }
 * }
 */
function updateFromBetaToV1(schema) {
  let updated = {
    schemaVersion: 1,
    themes: {}
  };

  for (let themeName in schema.themes) {
    let theme = schema.themes[themeName];

    updated.themes[themeName] = {
      syntax: {
        name: theme.syntax
      },
      ui: {
        name: theme.ui,
        config: theme.config
      }
    };
  }

  return updated;
}

export default {

  updateSchema(schema) {
    let version = schema.schemaVersion;

    switch (version) {
      case 0:
        return updateFromBetaToV1(schema);
      default: // The first time this package is run there will be no version so just return the initial schema
        return schema;
    }
  }

};
{'fraction_non_alphanumeric': 0.12877662209014362, 'fraction_numerical': 0.004952947003467063, 'mean_word_length': 1.948905109489051, 'pattern_counts': {'":': 10, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 1, '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': '6573523', 'n_tokens_mistral': 668, 'n_tokens_neox': 632, 'n_words': 158}