<commit_before>#!/bin/bash
#
# Utility functions for the Skia GCE setup scripts.
#
# Copyright 2014 Google Inc. All Rights Reserved.
# Author: <EMAIL> (<NAME>)


function install_packages {
  # Add new packages that are not yet part of the image below.
  echo
  echo "Install Required packages"
  $GCOMPUTE_CMD ssh --ssh_user=$PROJECT_USER $INSTANCE_NAME \
    "sudo debconf-set-selections <<< 'mysql-server mysql-server/root_password password tmp_pass' && " \
    "sudo debconf-set-selections <<< 'mysql-server mysql-server/root_password_again password tmp_pass' && " \
    "sudo apt-get -y install mercurial mysql-client mysql-server valgrind && " \
    "mysql -uroot -ptmp_pass -e \"SET PASSWORD = PASSWORD('');\"" \
    || FAILED="$FAILED InstallPackages"
  echo
}

function setup_symlinks {
  # Add new symlinks that are not yet part of the image below.
  echo
  echo "Setup Symlinks"
  # $GCOMPUTE_CMD ssh --ssh_user=$PROJECT_USER $INSTANCE_NAME \
  #   "sudo ln -s -f /usr/bin/ccache /usr/local/bin/cc" \
  #   || FAILED="$FAILED InstallPackages"
  echo
}

function install_go {
  GO_VERSION="go1.4.2.linux-386"
  echo
  echo "Install Go"
  $GCOMPUTE_CMD ssh --ssh_user=$PROJECT_USER $INSTANCE_NAME \
      "wget https://storage.googleapis.com/golang/$GO_VERSION.tar.gz && " \
      "tar -zxvf $GO_VERSION.tar.gz && " \
      "sudo mv go /usr/local && " \
      "sudo ln -s /usr/local/go/bin/go /usr/bin/go && " \
      "rm $GO_VERSION.tar.gz" \<commit_msg>Install libosmesa-dev on GCE compile bots<commit_after>#!/bin/bash
#
# Utility functions for the Skia GCE setup scripts.
#
# Copyright 2014 Google Inc. All Rights Reserved.
# Author: <EMAIL> (<NAME>)


function install_packages {
  # Add new packages that are not yet part of the image below.
  echo
  echo "Install Required packages"
  $GCOMPUTE_CMD ssh --ssh_user=$PROJECT_USER $INSTANCE_NAME \
    "sudo debconf-set-selections <<< 'mysql-server mysql-server/root_password password tmp_pass' && " \
    "sudo debconf-set-selections <<< 'mysql-server mysql-server/root_password_again password tmp_pass' && " \
    "sudo apt-get -y install mercurial mysql-client mysql-server valgrind libosmesa-dev && " \
    "mysql -uroot -ptmp_pass -e \"SET PASSWORD = PASSWORD('');\"" \
    || FAILED="$FAILED InstallPackages"
  echo
}

function setup_symlinks {
  # Add new symlinks that are not yet part of the image below.
  echo
  echo "Setup Symlinks"
  # $GCOMPUTE_CMD ssh --ssh_user=$PROJECT_USER $INSTANCE_NAME \
  #   "sudo ln -s -f /usr/bin/ccache /usr/local/bin/cc" \
  #   || FAILED="$FAILED InstallPackages"
  echo
}

function install_go {
  GO_VERSION="go1.4.2.linux-386"
  echo
  echo "Install Go"
  $GCOMPUTE_CMD ssh --ssh_user=$PROJECT_USER $INSTANCE_NAME \
      "wget https://storage.googleapis.com/golang/$GO_VERSION.tar.gz && " \
      "tar -zxvf $GO_VERSION.tar.gz && " \
      "sudo mv go /usr/local && " \
      "sudo ln -s /usr/local/go/bin/go /usr/bin/go && " \
      "rm $GO_VERSION.tar.gz" \
{'fraction_non_alphanumeric': 0.13400673400673402, 'fraction_numerical': 0.006734006734006734, 'mean_word_length': 3.2141843971631205, 'pattern_counts': {'":': 0, '<': 19, '<?xml version=': 0, '>': 7, 'https://': 2, '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': '7481076', 'n_tokens_mistral': 1085, 'n_tokens_neox': 1045, 'n_words': 266}