<commit_before>function omf.bundle.add -a type name_or_url
  function __omf.write_bundle
    set -l bundle $OMF_CONFIG/bundle
    set -l record $argv

    if test -f $bundle
      if not grep $record $bundle > /dev/null 2>&1
        echo $record >> $bundle
      end
    else
      echo $record > $bundle
    end

    sort -u $bundle -o $bundle
  end

  function __omf.write_theme
    echo $argv > $OMF_CONFIG/theme
  end

  __omf.write_bundle "$type" "$name_or_url"
  if test "$type" = theme
    __omf.write_theme "$name_or_url"
  end<commit_msg>bundle.add: fix theme being persisted twice<commit_after>function omf.bundle.add -a type name_or_url
  set -l bundle $OMF_CONFIG/bundle
  set -l record "$type $name_or_url"

  if test -f $bundle
    if not grep $record $bundle > /dev/null 2>&1
      echo $record >> $bundle
    end
  else
    echo $record > $bundle
  end

  sort -u $bundle -o $bundle
{'fraction_non_alphanumeric': 0.09799554565701558, 'fraction_numerical': 0.004454342984409799, 'mean_word_length': 2.6844262295081966, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 14, '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': '4988224', 'n_tokens_mistral': 323, 'n_tokens_neox': 311, 'n_words': 100}