blob: bf5618b86787905364206a340d346df38b90057c [file] [log] [blame]
#! /bin/bash
pushd /home/default
# Install repo tool if needed.
if [[ ! -e bin/repo ]]; then
sudo -u default mkdir bin
sudo -u default wget -O bin/repo
sudo -u default chmod a+x bin/repo
# Install gcompute-tools if needed.
if [[ ! -d gcompute-tools ]]; then
sudo -u default git clone
# Add repo and gcompute-tools to PATH if needed.
if [ -z "$(which repo)" ]; then
sudo -u default echo '# Add Android tools to PATH"' >> .bashrc
sudo -u default echo 'export PATH="/home/default/bin:$PATH"' >> .bashrc
sudo -u default echo 'export PATH="/home/default/gcompute-tools:$PATH"' >> .bashrc
# Set git configs required for the repo tool to not prompt.
sudo -u default git config --global color.ui true
sudo -u default git config --global ''
sudo -u default git config --global 'Skia_Android Canary Bot'