restore.sh 895 字节
Newer Older
A
Andy Gocke 已提交
1 2
#!/usr/bin/env bash

A
Andy Gocke 已提交
3 4
THIS_DIR=$(cd -P "$(dirname "${BASH_SOURCE[0]}")" && pwd)

5
# Workaround, see https://github.com/dotnet/roslyn/issues/10210
A
Andy Gocke 已提交
6 7 8 9 10 11 12 13
# $HOME is unset when running the mac unit tests.
if [[ -z ${HOME+x} ]]
then
    # Note that while ~ usually refers to $HOME, in the case where $HOME is unset,
    # it looks up the current user's home dir, which is what we want.
    # https://www.gnu.org/software/bash/manual/html_node/Tilde-Expansion.html
    export HOME=$(cd ~ && pwd)
fi
14

A
Andy Gocke 已提交
15 16
echo "Restoring toolset packages"

A
Andy Gocke 已提交
17 18 19 20 21 22 23
RESTORE_ARGS="-v Minimal --disable-parallel"
echo "Restoring BaseToolset.csproj"
dotnet restore ${RESTORE_ARGS} ${THIS_DIR}/../ToolsetPackages/BaseToolset.csproj
echo "Restoring CoreToolset.csproj"
dotnet restore ${RESTORE_ARGS} ${THIS_DIR}/../ToolsetPackages/CoreToolset.csproj
echo "Restoring Compilers.sln"
dotnet restore ${RESTORE_ARGS} ${THIS_DIR}/../../Compilers.sln