<commit_before>#!/bin/bash
set -e
#Initialize gerrit if gerrit site dir is empty.
#This is necessary when gerrit site is in a volume.
if [ "$1" = '/var/gerrit/gerrit-start.sh' ]; then
  if [ -z "$(ls -A "$GERRIT_SITE")" ]; then
    echo "First time initialize gerrit..."
    java -jar $GERRIT_WAR init --batch --no-auto-start -d $GERRIT_SITE
  fi

  #Customize gerrit.config
  #mkdir $GERRIT_SITE/etc

  #Section gerrit
  [ -z $WEBURL ] || git config -f $GERRIT_SITE/etc/gerrit.config gerrit.canonicalWebUrl $WEBURL<commit_msg>Fix first time login fail problem.<commit_after>#!/bin/bash
set -e
#Initialize gerrit if gerrit site dir is empty.
#This is necessary when gerrit site is in a volume.
if [ "$1" = '/var/gerrit/gerrit-start.sh' ]; then
  if [ -z "$(ls -A "$GERRIT_SITE")" ]; then
    echo "First time initialize gerrit..."
    java -jar $GERRIT_WAR init --batch --no-auto-start -d $GERRIT_SITE
    #All-Projects.git must be removed here in order to be recreated at the secondary init below.
    rm -rf $GERRIT_SITE/git/All-Projects.git 
  fi

  #Customize gerrit.config
  #mkdir $GERRIT_SITE/etc

  #Section gerrit
  [ -z $WEBURL ] || git config -f $GERRIT_SITE/etc/gerrit.config gerrit.canonicalWebUrl $WEBURL
{'fraction_non_alphanumeric': 0.12889983579638753, 'fraction_numerical': 0.0016420361247947454, 'mean_word_length': 3.3535714285714286, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, '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': '6677464', 'n_tokens_mistral': 479, 'n_tokens_neox': 447, 'n_words': 140}