<commit_before># these are only useful on machines running X

if [[ -n "$DISPLAY" ]]; then

  #if which notify-send &> /dev/null; then
    # copied from ubu 12.04 default .bashrc:
    # Add an "alert" alias for long running commands.  Use like so:
    #   sleep 10; alert
    alias alert='notify-send --urgency=low -i "$([ $? = 0 ] && echo terminal || echo error)" "$(history|tail -n1|sed -e '\''s/^\s*[0-9]\+\s*//;s/[;&|]\s*alert$//'\'')"'
  #fi

  # TODO: url-encoding
  browse_local_file () {
    ${BROWSER:-firefox} "file://`full-path $1`"
  }

  SYMBOLA_FONT="`ls ~/.fonts/Symbola*.ttf | tail -n 1`"
  show_text () {
    local text=''
    if [[ $# -gt 0 ]]; then
      text="$*";
    else
      while read; do
        text="$text${text:+$'\n'}$REPLY";
      done;<commit_msg>Update symbola font pattern<commit_after># these are only useful on machines running X

if [[ -n "$DISPLAY" ]]; then

  #if which notify-send &> /dev/null; then
    # copied from ubu 12.04 default .bashrc:
    # Add an "alert" alias for long running commands.  Use like so:
    #   sleep 10; alert
    alias alert='notify-send --urgency=low -i "$([ $? = 0 ] && echo terminal || echo error)" "$(history|tail -n1|sed -e '\''s/^\s*[0-9]\+\s*//;s/[;&|]\s*alert$//'\'')"'
  #fi

  # TODO: url-encoding
  browse_local_file () {
    ${BROWSER:-firefox} "file://`full-path $1`"
  }

  SYMBOLA_FONT="`ls ~/.fonts/Symbola*.?tf | tail -n 1`"
  show_text () {
    local text=''
    if [[ $# -gt 0 ]]; then
      text="$*";
    else
      while read; do
        text="$text${text:+$'\n'}$REPLY";
      done;
{'fraction_non_alphanumeric': 0.2128335451080051, 'fraction_numerical': 0.016518424396442185, 'mean_word_length': 2.629032258064516, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 5, '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': '4283299', 'n_tokens_mistral': 625, 'n_tokens_neox': 585, 'n_words': 156}